From 47960ad04115f85e17c66909c242f62cb99d78bb Mon Sep 17 00:00:00 2001 From: petervo Date: Thu, 23 Mar 2017 15:03:03 -0700 Subject: [PATCH 1/6] Update for cockpit 135 --- Dockerfile | 10 +++++----- atomic-install | 11 +++++++---- atomic-run | 1 + atomic-uninstall | 2 +- 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index 22a852b..8f729de 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,16 @@ FROM registry.fedoraproject.org/fedora:26 MAINTAINER "Stef Walter" -ENV VERSION=125 RELEASE=1.6 +ENV VERSION=135 RELEASE=1 LABEL BZComponent="cockpit" \ Name="$FGC/cockpit" \ Version="$VERSION" \ Release="$RELEASE.$DISTTAG" \ Architecture="x86_64" -RUN dnf install -y cockpit-ws -# And the stuff that starts the container +RUN dnf install -y cockpit-ws cockpit-dashboard + RUN mkdir -p /container && ln -s /host/proc/1 /container/target-namespace ADD atomic-install /container/atomic-install ADD atomic-uninstall /container/atomic-uninstall @@ -22,8 +22,8 @@ RUN chmod -v +x /container/atomic-run # Make the container think it's the host OS version RUN rm -f /etc/os-release /usr/lib/os-release && ln -sv /host/etc/os-release /etc/os-release && ln -sv /host/usr/lib/os-release /usr/lib/os-release -LABEL INSTALL /usr/bin/docker run -ti --rm --privileged -v /:/host IMAGE /container/atomic-install -LABEL UNINSTALL /usr/bin/docker run -ti --rm --privileged -v /:/host IMAGE /container/atomic-uninstall +LABEL INSTALL /usr/bin/docker run --rm --privileged -v /:/host IMAGE /container/atomic-install +LABEL UNINSTALL /usr/bin/docker run --rm --privileged -v /:/host IMAGE /container/atomic-uninstall LABEL RUN /usr/bin/docker run -d --privileged --pid=host -v /:/host IMAGE /container/atomic-run --local-ssh # Look ma, no EXPOSE diff --git a/atomic-install b/atomic-install index abc4c61..15d2477 100644 --- a/atomic-install +++ b/atomic-install @@ -17,7 +17,7 @@ if [ ! -f /host/usr/bin/cockpit-bridge ]; then exit 1 fi if [ ! -d /host/usr/share/cockpit ]; then - echo "cockpit-run: cockpit-shell and other resources must be installed in the host" >&2 + echo "cockpit-run: cockpit-system and other resources must be installed in the host" >&2 exit 1 fi if [ -f /host/usr/libexec/cockpit-ws ]; then @@ -34,14 +34,17 @@ set -x sed -e '/pam_selinux/d' -e '/pam_sepermit/d' /etc/pam.d/cockpit > /host/etc/pam.d/cockpit # Make sure that we have required directories in the host -mkdir -p /host/etc/cockpit/ws-certs.d -chmod 755 /host/etc/cockpit/ws-certs.d -chown root:root /host/etc/cockpit/ws-certs.d +mkdir -p /host/etc/cockpit/ws-certs.d /host/etc/cockpit/machines.d +chmod 755 /host/etc/cockpit/ws-certs.d /host/etc/cockpit/machines.d +chown root:root /host/etc/cockpit/ws-certs.d /host/etc/cockpit/machines.d mkdir -p /host/var/lib/cockpit chmod 775 /host/var/lib/cockpit chown root:wheel /host/var/lib/cockpit +# For sharing ssh's known hosts with container +mkdir -p /etc/ssh + # Ensure we have certificates /bin/mount --bind /host/etc/cockpit /etc/cockpit /usr/sbin/remotectl certificate --ensure diff --git a/atomic-run b/atomic-run index 1ddddde..6a096d6 100644 --- a/atomic-run +++ b/atomic-run @@ -15,6 +15,7 @@ set +x /bin/mount --bind /host/usr/share/pixmaps /usr/share/pixmaps /bin/mount --bind /host/var /var +/bin/mount --bind /host/etc/ssh /etc/ssh # And run cockpit-ws exec /usr/bin/nsenter --net=/container/target-namespace/ns/net --uts=/container/target-namespace/ns/uts -- /usr/libexec/cockpit-ws "$@" diff --git a/atomic-uninstall b/atomic-uninstall index 06b49aa..5b4636f 100644 --- a/atomic-uninstall +++ b/atomic-uninstall @@ -16,7 +16,7 @@ if [ ! -f /host/usr/bin/cockpit-bridge ]; then exit 1 fi if [ ! -d /host/usr/share/cockpit ]; then - echo "cockpit-shell and other resources must be installed in the host" >&2 + echo "cockpit-system and other resources must be installed in the host" >&2 exit 1 fi if [ -f /host/usr/libexec/cockpit-ws ]; then From 8f01b0e1935d3cb66203957391c10ab11a8f2f35 Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Wed, 2 May 2018 19:14:15 +0200 Subject: [PATCH 2/6] Update for cockpit 166 and Fedora 29 --- Dockerfile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8f729de..bd78fe4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ -FROM registry.fedoraproject.org/fedora:26 +FROM registry.fedoraproject.org/fedora:29 MAINTAINER "Stef Walter" -ENV VERSION=135 RELEASE=1 +ENV VERSION=166 RELEASE=1 LABEL BZComponent="cockpit" \ Name="$FGC/cockpit" \ Version="$VERSION" \ @@ -9,15 +9,15 @@ LABEL BZComponent="cockpit" \ Architecture="x86_64" -RUN dnf install -y cockpit-ws cockpit-dashboard +RUN dnf install -y cockpit-ws cockpit-dashboard && \ + mkdir -p /container && ln -s /host/proc/1 /container/target-namespace && \ + dnf clean all -RUN mkdir -p /container && ln -s /host/proc/1 /container/target-namespace ADD atomic-install /container/atomic-install ADD atomic-uninstall /container/atomic-uninstall ADD atomic-run /container/atomic-run -RUN chmod -v +x /container/atomic-install -RUN chmod -v +x /container/atomic-uninstall -RUN chmod -v +x /container/atomic-run + +RUN chmod -v +x /container/atomic-install /container/atomic-uninstall /container/atomic-run # Make the container think it's the host OS version RUN rm -f /etc/os-release /usr/lib/os-release && ln -sv /host/etc/os-release /etc/os-release && ln -sv /host/usr/lib/os-release /usr/lib/os-release From b28310fccb011232546ef0860fd843b66741f44d Mon Sep 17 00:00:00 2001 From: Clement Verna Date: Mon, 20 Aug 2018 17:08:30 +0200 Subject: [PATCH 3/6] Drop Release label in favor of OSBS release_bump plugin. OSBS can automatically bump the release number, for that we just need to drop the label from the Dockerfile See https://pagure.io/ContainerSIG/container-sig/issue/1 Signed-off-by: Clement Verna --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index bd78fe4..7c039db 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,10 @@ FROM registry.fedoraproject.org/fedora:29 MAINTAINER "Stef Walter" -ENV VERSION=166 RELEASE=1 +ENV VERSION=166 LABEL BZComponent="cockpit" \ Name="$FGC/cockpit" \ Version="$VERSION" \ - Release="$RELEASE.$DISTTAG" \ Architecture="x86_64" From 62c6ef4f947f247205044953c4a1ec6c5f38b101 Mon Sep 17 00:00:00 2001 From: Clement Verna Date: Mon, 20 Aug 2018 17:17:28 +0200 Subject: [PATCH 4/6] Use the rawhide tag for the master branch Signed-off-by: Clement Verna --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 7c039db..f7b5c09 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM registry.fedoraproject.org/fedora:29 +FROM registry.fedoraproject.org/fedora:rawhide MAINTAINER "Stef Walter" ENV VERSION=166 From 57b1ac75e06359a8ba52d0d98aba00e3bb94439c Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Mon, 3 Sep 2018 11:41:00 +0200 Subject: [PATCH 5/6] Update for Cockpit 176 --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index f7b5c09..3d8d20b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,14 @@ FROM registry.fedoraproject.org/fedora:rawhide MAINTAINER "Stef Walter" -ENV VERSION=166 +ENV VERSION=176 LABEL BZComponent="cockpit" \ Name="$FGC/cockpit" \ Version="$VERSION" \ Architecture="x86_64" -RUN dnf install -y cockpit-ws cockpit-dashboard && \ +RUN dnf install -y cockpit-ws cockpit-dashboard cockpit-bridge && \ mkdir -p /container && ln -s /host/proc/1 /container/target-namespace && \ dnf clean all From f8b02a730c5f121d646254e968f31db1aa61347e Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Thu, 8 Nov 2018 21:46:39 +0100 Subject: [PATCH 6/6] Update for Cockpit 181 --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 3d8d20b..2dedc2f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ FROM registry.fedoraproject.org/fedora:rawhide MAINTAINER "Stef Walter" -ENV VERSION=176 +ENV VERSION=181 LABEL BZComponent="cockpit" \ Name="$FGC/cockpit" \ Version="$VERSION" \