mirror of
https://github.com/docker/docker-bench-security.git
synced 2025-01-18 16:22:33 +01:00
Add /etc/hostname fix for macOS
This commit is contained in:
parent
1891eaa8b3
commit
8ac4513d24
1 changed files with 3 additions and 1 deletions
|
@ -57,10 +57,12 @@ docker run --rm --net host --pid host --userns host --cap-add audit_control \
|
||||||
docker/docker-bench-security
|
docker/docker-bench-security
|
||||||
```
|
```
|
||||||
|
|
||||||
2. `Docker Desktop` on macOS doesn't have `/usr/lib/systemd` or the above Docker
|
2. The /etc/hostname file is missing on macOS, so it will need to be created first. Also, `Docker Desktop` on macOS doesn't have `/usr/lib/systemd` or the above Docker
|
||||||
binaries.
|
binaries.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
sudo touch /etc/hostname
|
||||||
|
|
||||||
docker run --rm --net host --pid host --userns host --cap-add audit_control \
|
docker run --rm --net host --pid host --userns host --cap-add audit_control \
|
||||||
-e DOCKER_CONTENT_TRUST=$DOCKER_CONTENT_TRUST \
|
-e DOCKER_CONTENT_TRUST=$DOCKER_CONTENT_TRUST \
|
||||||
-v /etc:/etc \
|
-v /etc:/etc \
|
||||||
|
|
Loading…
Reference in a new issue