From 41438630b21a998855b7f174403f87e15327b5a6 Mon Sep 17 00:00:00 2001 From: Kiritow <1362050620@qq.com> Date: Thu, 10 Jun 2021 10:16:58 +0800 Subject: [PATCH] Update systemd --- ubuntu-cn-systemd/Dockerfile | 1 + ubuntu-cn-systemd/Readme.md | 2 ++ 2 files changed, 3 insertions(+) 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`.