David Newhall II
3a88ef27a5
close channel in function that sends to it
2023-03-13 20:09:01 -07:00
shirou
c7c548d6bd
Merge pull request #1428 from dhurley/add-support-for-process-exe-for-freebsd
...
FreeBSD process exe support
2023-03-11 00:26:13 +09:00
shirou
50d889cc59
Merge pull request #1421 from jak3kaj/cumulus-linux-support
...
Recognize Cumulus Linux distro
2023-03-10 23:59:18 +09:00
Jacob Young
02660eaf7c
Update host/host_linux.go
...
Use a raw string instead of escaped quotes.
Co-authored-by: shirou <shirou.faw@gmail.com>
2023-03-10 09:41:18 -05:00
Donal Hurley
cf25de7460
Add support for getting process exe in FreeBSD
2023-03-09 11:46:40 +00:00
shirou
dda567eee6
Merge pull request #1427 from shirou/dependabot/go_modules/golang.org/x/sys-0.6.0
...
chore(deps): bump golang.org/x/sys from 0.5.0 to 0.6.0
2023-03-06 12:28:08 +09:00
dependabot[bot]
78d3bf5ace
chore(deps): bump golang.org/x/sys from 0.5.0 to 0.6.0
...
Bumps [golang.org/x/sys](https://github.com/golang/sys ) from 0.5.0 to 0.6.0.
- [Release notes](https://github.com/golang/sys/releases )
- [Commits](https://github.com/golang/sys/compare/v0.5.0...v0.6.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/sys
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-03-06 02:15:15 +00:00
shirou
ad7274d0cc
Merge pull request #1426 from 3139487747/patch-1
...
English case error
2023-03-04 23:07:15 +09:00
syyyj
39770901ac
English case error
...
m to M
2023-03-04 02:58:54 +08:00
shirou
7ab2f0eba3
Merge pull request #1423 from shirou/dependabot/go_modules/github.com/stretchr/testify-1.8.2
...
chore(deps): bump github.com/stretchr/testify from 1.8.1 to 1.8.2
v3.23.2
2023-02-27 12:56:00 +09:00
dependabot[bot]
1e85027fe4
chore(deps): bump github.com/stretchr/testify from 1.8.1 to 1.8.2
...
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify ) from 1.8.1 to 1.8.2.
- [Release notes](https://github.com/stretchr/testify/releases )
- [Commits](https://github.com/stretchr/testify/compare/v1.8.1...v1.8.2 )
---
updated-dependencies:
- dependency-name: github.com/stretchr/testify
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-02-27 02:44:21 +00:00
Jacob Young
43566581f0
Recognize Cumulus Linux distro
...
Add Cumulus Linux and Kylin to debian family
2023-02-24 13:59:01 -05:00
shirou
b51f72ebfb
Merge pull request #1412 from powersj/fix/dm-resolution
...
fix(disk): correctly replace /dev in /dev/mapper
2023-02-18 10:41:08 +09:00
shirou
1c27744fc9
Merge pull request #1413 from shirou/dependabot/go_modules/golang.org/x/sys-0.5.0
...
chore(deps): bump golang.org/x/sys from 0.4.0 to 0.5.0
2023-02-12 19:00:20 +09:00
shirou
f78f9a6bb8
Merge pull request #1414 from jeffweiss/bugfix/get_tests_working_on_s390x
...
get tests passing on s390x
2023-02-12 18:58:26 +09:00
shirou
57bee8213a
Merge pull request #1417 from shirou/feature/fix_lint
...
fix lint
2023-02-12 18:54:26 +09:00
shirou
852f455217
fix lint
2023-02-12 09:24:52 +00:00
shirou
6a5e40a517
Merge pull request #1228 from abner-chenc/master
...
host: add support for linux/loong64
2023-02-12 16:48:27 +09:00
shirou
e563e6394e
Merge pull request #1356 from N1neSun/patch-1
...
fix some kylin linux bug
2023-02-12 16:46:43 +09:00
Jeff Weiss
f850a69ba1
get tests passing on s390x
2023-02-07 14:12:31 -08:00
dependabot[bot]
f71fb1e37f
chore(deps): bump golang.org/x/sys from 0.4.0 to 0.5.0
...
Bumps [golang.org/x/sys](https://github.com/golang/sys ) from 0.4.0 to 0.5.0.
- [Release notes](https://github.com/golang/sys/releases )
- [Commits](https://github.com/golang/sys/compare/v0.4.0...v0.5.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/sys
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-02-07 01:06:04 +00:00
Josh Powers
d22f238125
lint: resolve lint issues in master
2023-02-02 13:00:15 -07:00
Josh Powers
7645051510
fix(disk): correctly replace /dev in /dev/mapper
...
Only replace the first instance of /dev in a /dev/mapper string.
Otherwise, if an LVM group is named dev it will replace that as well.
fixes : #1411
2023-02-01 08:26:10 -07:00
shirou
0494d7f0b9
Merge pull request #1403 from Agilicus/add-ppc64be
...
[host] linux/ppc: ppc64 definition from ppc64le
v3.23.1
2023-02-01 07:55:42 +09:00
shirou
2aa7394ecc
Merge pull request #1407 from shirou/feature/change_contextable_disk_partitions_windows
...
[disk][windows]: add context handling on PartionsWithContext
2023-02-01 07:45:25 +09:00
shirou
301930f9bd
Merge pull request #1404 from shirou/dependabot/go_modules/golang.org/x/sys-0.4.0
...
chore(deps): bump golang.org/x/sys from 0.3.0 to 0.4.0
2023-01-18 08:10:35 +09:00
shirou
8105a6d577
[disk][windows]: add context handling on PartionsWithContext
2023-01-14 17:59:36 +09:00
Guoqi Chen
b793d83f72
host: add support for linux/loong64
...
Updates #1338 .
Signed-off-by: Guoqi Chen <chenguoqi@loongson.cn>
Co-authored-by: Jiantao Shan <shanjiantao@loongson.cn>
2023-01-14 07:09:59 +08:00
Guoqi Chen
b055174e9e
cpu: Add the matching rule "Model Name" when parsing cpuinfo
...
This is to fix the error of running TestCpuInfo on Linux/long64. In loong64
/proc/cpuinfo, the model name is capitalize the first letter
Reference:
https://github.com/torvalds/linux/blob/master/arch/loongarch/kernel/proc.c
Signed-off-by: Guoqi Chen <chenguoqi@loongson.cn>
2023-01-14 07:05:49 +08:00
dependabot[bot]
87931ed66f
chore(deps): bump golang.org/x/sys from 0.3.0 to 0.4.0
...
Bumps [golang.org/x/sys](https://github.com/golang/sys ) from 0.3.0 to 0.4.0.
- [Release notes](https://github.com/golang/sys/releases )
- [Commits](https://github.com/golang/sys/compare/v0.3.0...v0.4.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/sys
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-05 01:08:25 +00:00
shirou
581c27c0e6
Merge pull request #1397 from jefferbrecht/jefferbrecht-windows-host
...
[host] windows: use millisecond precision for BootTime()
2023-01-05 09:48:13 +09:00
Jeff Erbrecht
a5ecb9bca5
[host] windows: use millisecond precision for BootTime()
...
Previously, system uptime is truncated to seconds, and then the
subtraction from `time.Now()` is performed. Because uptime does not roll
over to the next second at the same instant as `time.Now()`, then
`BootTime()` ends up not being precise, and often varies by 1 second.
This commit does the subtraction before truncating to seconds, which
results in a significantly lower chance of variance in `BootTime()`.
2023-01-04 10:42:00 -05:00
Don Bowman
d7f1f76519
[host] linux/ppc: ppc64 definition from ppc64le
...
Same as commit fc04d2d, but for ppc64 from ppc64le definition.
2023-01-03 20:56:48 -05:00
shirou
2fb67aaf4a
Merge pull request #1401 from shirou/feature/add_HOST_ROOT_to_readme
...
chore(README): add `HOST_ROOT`
v3.22.12
2022-12-30 17:22:20 +09:00
shirou
46c4ce3ffc
chore(README): add HOST_ROOT
introduced by #1400
2022-12-30 08:12:01 +00:00
shirou
ca886f9316
Merge pull request #1400 from scop/dockerenv
...
Detect Docker also using /.dockerenv
2022-12-30 17:10:51 +09:00
Ville Skyttä
70a8f589c6
Detect Docker also using /.dockerenv
2022-12-28 23:12:58 +02:00
shirou
f848ee3fa2
Merge pull request #1398 from Juneezee/test/t.Setenv
...
test: use `T.Setenv` to set env vars in tests
2022-12-24 11:37:36 +09:00
Eng Zer Jun
37894e9b28
test: use T.Setenv
to set env vars in tests
...
This commit replaces `os.Setenv` with `t.Setenv` in tests. The
environment variable is automatically restored to its original value
when the test and all its subtests complete.
Reference: https://pkg.go.dev/testing#T.Setenv
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-12-20 13:13:01 +08:00
shirou
835767a611
Merge pull request #1389 from sgthammer/feature/fix-arm-modelname
...
fill modelName for all cores in arm64 devices
2022-12-19 22:14:07 +09:00
shirou
39f3b34192
Merge pull request #1392 from brianryner8/getfsstat-count
...
Truncate the Getfsstat result to the count of items that were returned
2022-12-18 13:19:54 +09:00
shirou
8d22915181
[disk][darwin]: add issue URL
2022-12-18 13:11:56 +09:00
Brian Ryner
c2fa2cbf8e
Update comment
2022-12-18 14:23:01 +11:00
shirou
bd21a78aa9
Merge pull request #1387 from shirou/dependabot/go_modules/golang.org/x/sys-0.3.0
...
chore(deps): bump golang.org/x/sys from 0.2.0 to 0.3.0
2022-12-10 20:19:46 +09:00
shirou
d661503ccc
Merge pull request #1393 from tklauser/byteslicetostring
...
host: use unix.ByteSliceToString
2022-12-10 10:36:24 +09:00
shirou
d2a3bd84bd
Merge pull request #1394 from tklauser/activeprocessorcount
...
cpu: use windows.GetActiveProcessorCount
2022-12-10 10:27:29 +09:00
Tobias Klauser
f2bf9a480a
cpu: use windows.GetActiveProcessorCount
...
Use GetActiveProcessorCount and the ALL_PROCESSOR_GROUPS const provided
in golang.org/x/sys/windows. The function is available on Windows 7 and
later. Go requires Windows 7, see https://go.dev/doc/go1.11#ports
2022-12-07 13:51:29 +01:00
Tobias Klauser
f9a5834e0e
host: use unix.ByteSliceToString
...
Use ByteSliceToString provided in golang.org/x/sys/unix to convert
\0-terminated byte slices to strings.
2022-12-07 13:14:45 +01:00
Brian Ryner
34da06e9b7
fix
2022-12-07 14:31:09 +11:00
Brian Ryner
c5e42b972f
Truncate the result of Getfsstat to the item count that is returned.
...
This count may be less than what was returned by the first call to Getfsstat.
2022-12-07 14:27:20 +11:00