Fix sudo cat Permission denied error
Last commit [0], using sudo cat, this will gievs the error: /etc/systemd/system/docker.service.d/docker.conf: Permission denied This patch will fix this. [0]: I2154919c394e546edac56934c8860d4177fc9603 Change-Id: I87a8b7397d2dad2d26eac9a020d5ea3b21645aa2
This commit is contained in:
parent
ce2d8fce33
commit
f925296126
@ -142,11 +142,11 @@ function install_docker {
|
||||
sudo sed -i '/^ExecStart=/cExecStart=/usr/bin/dockerd -H unix:///var/run/docker.sock -H tcp://0.0.0.0:'$(echo $DOCKER_REMOTE_API_PORT)'' /lib/systemd/system/docker.service
|
||||
else
|
||||
sudo mkdir -p /etc/systemd/system/docker.service.d
|
||||
sudo cat > /etc/systemd/system/docker.service.d/docker.conf << EOF
|
||||
sudo sh -c "cat > /etc/systemd/system/docker.service.d/docker.conf << EOF
|
||||
[Service]
|
||||
ExecStart=
|
||||
ExecStart=/usr/bin/dockerd -H unix:///var/run/docker.sock -H tcp://0.0.0.0:$DOCKER_REMOTE_API_PORT
|
||||
EOF
|
||||
EOF"
|
||||
fi
|
||||
sudo systemctl daemon-reload
|
||||
sudo systemctl restart docker
|
||||
|
Loading…
Reference in New Issue
Block a user