Compare commits
8 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8f9a517b6b | ||
|
|
c835099d3f | ||
|
|
e1f49fb44d | ||
|
|
b61c9083df | ||
|
|
150b7d4f25 | ||
|
|
4980aeed29 | ||
|
|
eecdfb94e1 | ||
|
|
47c808132e |
4 changed files with 14 additions and 11 deletions
12
Dockerfile
12
Dockerfile
|
|
@ -1,8 +1,8 @@
|
||||||
FROM registry.fedoraproject.org/fedora:rawhide
|
FROM registry.fedoraproject.org/fedora:25
|
||||||
|
|
||||||
ENV VERSION=0 RELEASE=1 ARCH=x86_64
|
ENV VERSION=0 RELEASE=8 ARCH=x86_64
|
||||||
LABEL com.redhat.component="docker" \
|
LABEL com.redhat.component="docker" \
|
||||||
name="docker" \
|
name="$FGC/docker" \
|
||||||
version="$VERSION" \
|
version="$VERSION" \
|
||||||
release="$RELEASE.$DISTTAG" \
|
release="$RELEASE.$DISTTAG" \
|
||||||
architecture="$ARCH" \
|
architecture="$ARCH" \
|
||||||
|
|
@ -11,8 +11,8 @@ LABEL com.redhat.component="docker" \
|
||||||
maintainer="Giuseppe Scrivano <gscrivan@redhat.com>" \
|
maintainer="Giuseppe Scrivano <gscrivan@redhat.com>" \
|
||||||
atomic.type="system"
|
atomic.type="system"
|
||||||
|
|
||||||
RUN dnf install --setopt=tsflags=nodocs -y docker container-storage-setup container-selinux cloud-utils-growpart python-docker-py docker-novolume-plugin lvm2 iptables procps-ng xz oci-register-machine \
|
RUN dnf install --setopt=tsflags=nodocs -y docker container-selinux cloud-utils-growpart python-docker-py docker-novolume-plugin lvm2 iptables procps-ng xz oci-register-machine \
|
||||||
&& rpm -V docker container-storage-setup container-selinux cloud-utils-growpart python-docker-py docker-novolume-plugin lvm2 iptables procps-ng xz oci-register-machine \
|
&& rpm -V docker container-selinux cloud-utils-growpart python-docker-py docker-novolume-plugin lvm2 iptables procps-ng xz oci-register-machine \
|
||||||
&& mkdir -p /usr/lib/modules && dnf clean all
|
&& mkdir -p /usr/lib/modules && dnf clean all
|
||||||
|
|
||||||
RUN ln -s /usr/libexec/docker/docker-runc-current /usr/bin/docker-runc
|
RUN ln -s /usr/libexec/docker/docker-runc-current /usr/bin/docker-runc
|
||||||
|
|
@ -25,6 +25,6 @@ COPY set_mounts.sh /
|
||||||
COPY config.json.template service.template tmpfiles.template /exports/
|
COPY config.json.template service.template tmpfiles.template /exports/
|
||||||
COPY daemon.json /exports/hostfs/etc/docker/container-daemon.json
|
COPY daemon.json /exports/hostfs/etc/docker/container-daemon.json
|
||||||
# https://github.com/rhatdan/oci-umount/issues/2
|
# https://github.com/rhatdan/oci-umount/issues/2
|
||||||
RUN cp /etc/oci-umount.conf /exports/hostfs/etc
|
RUN (test -e /etc/oci-umount.conf && cp /etc/oci-umount.conf /exports/hostfs/etc) || true
|
||||||
|
|
||||||
CMD ["/usr/bin/init.sh"]
|
CMD ["/usr/bin/init.sh"]
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@
|
||||||
"arch": "amd64"
|
"arch": "amd64"
|
||||||
},
|
},
|
||||||
"process": {
|
"process": {
|
||||||
|
"selinuxLabel": "system_u:system_r:container_runtime_t:s0",
|
||||||
"terminal": false,
|
"terminal": false,
|
||||||
"user": {
|
"user": {
|
||||||
"uid": 0,
|
"uid": 0,
|
||||||
|
|
@ -393,7 +394,6 @@
|
||||||
{
|
{
|
||||||
"type": "mount"
|
"type": "mount"
|
||||||
}
|
}
|
||||||
],
|
]
|
||||||
"selinuxProcessLabel": "system_u:system_r:container_runtime_t:s0"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,4 @@
|
||||||
|
|
||||||
{
|
{
|
||||||
"authorization-plugins": ["rhel-push-plugin"],
|
|
||||||
"default-runtime": "oci",
|
"default-runtime": "oci",
|
||||||
"containerd": "/run/containerd.sock",
|
"containerd": "/run/containerd.sock",
|
||||||
"userland-proxy-path": "/usr/libexec/docker/docker-proxy-current",
|
"userland-proxy-path": "/usr/libexec/docker/docker-proxy-current",
|
||||||
|
|
|
||||||
7
init.sh
7
init.sh
|
|
@ -1,5 +1,10 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Ensure that new process maintain this SELinux label
|
||||||
|
PID=$$
|
||||||
|
LABEL=`tr -d '\000' < /proc/$PID/attr/current`
|
||||||
|
printf %s $LABEL > /proc/self/attr/exec
|
||||||
|
|
||||||
source /run/docker-bash-env
|
source /run/docker-bash-env
|
||||||
|
|
||||||
# set storage first
|
# set storage first
|
||||||
|
|
@ -22,7 +27,7 @@ do
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
done
|
done
|
||||||
|
|
||||||
# Run all the installed containers
|
# Run all the installed plugins
|
||||||
mkdir -p /run/docker/plugins/
|
mkdir -p /run/docker/plugins/
|
||||||
ls -1 /usr/libexec/docker/*plugin | \
|
ls -1 /usr/libexec/docker/*plugin | \
|
||||||
while read i;
|
while read i;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue