diff --git a/ubuntu-cn-systemd/Dockerfile b/ubuntu-cn-systemd/Dockerfile index 8f3fa63..bc5cdd1 100644 --- a/ubuntu-cn-systemd/Dockerfile +++ b/ubuntu-cn-systemd/Dockerfile @@ -8,6 +8,7 @@ RUN apt update \ && rm -rf /var/lib/apt/lists/* \ && rm -rf /tmp/* /var/tmp/* \ && rm /root/preseed.cfg \ + && sed 's/ProtectHostname=yes/ProtectHostname=no/g' -i /lib/systemd/system/systemd-logind.service \ && cd /lib/systemd/system/sysinit.target.wants/ \ && ls | grep -v systemd-tmpfiles-setup | xargs rm -f $1 \ && rm -f /lib/systemd/system/multi-user.target.wants/* \ diff --git a/ubuntu-cn-systemd/Readme.md b/ubuntu-cn-systemd/Readme.md index 6df622f..675e83d 100644 --- a/ubuntu-cn-systemd/Readme.md +++ b/ubuntu-cn-systemd/Readme.md @@ -1,3 +1,5 @@ # ubuntu-cn-systemd Ubuntu with systemd installed. Time zone is set to `Asia/Shanghai` + +systemd-logind.service: `ProtectHostname` set to `no`.