change all dockerfile
This commit is contained in:
parent
6d4ce8c5ac
commit
3705ed06ac
@ -1,21 +1,39 @@
|
|||||||
# Source for dockerfile:
|
FROM fedora
|
||||||
# https://github.com/containers/buildah/blob/master/docs/tutorials/05-openshift-rootless-bud.md
|
|
||||||
FROM quay.io/buildah/stable:v1.14.8
|
|
||||||
|
|
||||||
RUN touch /etc/subgid /etc/subuid \
|
RUN dnf -y install \
|
||||||
&& chmod g=u /etc/subgid /etc/subuid /etc/passwd \
|
make \
|
||||||
&& echo build:10000:65536 > /etc/subuid \
|
golang \
|
||||||
&& echo build:10000:65536 > /etc/subgid
|
bats \
|
||||||
|
btrfs-progs-devel \
|
||||||
|
device-mapper-devel \
|
||||||
|
glib2-devel \
|
||||||
|
gpgme-devel \
|
||||||
|
libassuan-devel \
|
||||||
|
libseccomp-devel \
|
||||||
|
git \
|
||||||
|
bzip2 \
|
||||||
|
go-md2man \
|
||||||
|
runc \
|
||||||
|
containers-common \
|
||||||
|
skopeo-containers
|
||||||
|
|
||||||
# Use chroot since the default runc does not work when running rootless
|
# Workaround - the first install somehow leaves the golang in a bad state
|
||||||
RUN echo "export BUILDAH_ISOLATION=chroot" >> /home/build/.bashrc
|
RUN dnf -y install golang
|
||||||
|
|
||||||
# Use VFS since fuse does not work
|
RUN mkdir /root/buildah && \
|
||||||
RUN mkdir -p /home/build/.config/containers \
|
cd /root/buildah && \
|
||||||
&& echo "driver=\"vfs\"" > /home/build/.config/containers/storage.conf
|
git clone https://github.com/harness/buildah.git ./src/github.com/containers/buildah
|
||||||
|
|
||||||
|
RUN cd /root/buildah/src/github.com/containers/buildah && make && sudo make install
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
FROM quay.io/buildah/stable:v1.23.0
|
||||||
|
|
||||||
USER build
|
USER build
|
||||||
WORKDIR /home/build
|
WORKDIR /home/build
|
||||||
|
RUN export STORAGE_DRIVER=vfs
|
||||||
|
COPY --from=0 /root/buildah/src/github.com/containers/buildah/bin/. /bin/
|
||||||
|
|
||||||
# Add plugin binary
|
# Add plugin binary
|
||||||
ADD release/linux/amd64/drone-docker /bin/
|
ADD release/linux/amd64/drone-docker /bin/
|
||||||
|
|||||||
@ -1,21 +1,39 @@
|
|||||||
# Source for dockerfile:
|
FROM fedora
|
||||||
# https://github.com/containers/buildah/blob/master/docs/tutorials/05-openshift-rootless-bud.md
|
|
||||||
FROM quay.io/buildah/stable:v1.14.8
|
|
||||||
|
|
||||||
RUN touch /etc/subgid /etc/subuid \
|
RUN dnf -y install \
|
||||||
&& chmod g=u /etc/subgid /etc/subuid /etc/passwd \
|
make \
|
||||||
&& echo build:10000:65536 > /etc/subuid \
|
golang \
|
||||||
&& echo build:10000:65536 > /etc/subgid
|
bats \
|
||||||
|
btrfs-progs-devel \
|
||||||
|
device-mapper-devel \
|
||||||
|
glib2-devel \
|
||||||
|
gpgme-devel \
|
||||||
|
libassuan-devel \
|
||||||
|
libseccomp-devel \
|
||||||
|
git \
|
||||||
|
bzip2 \
|
||||||
|
go-md2man \
|
||||||
|
runc \
|
||||||
|
containers-common \
|
||||||
|
skopeo-containers
|
||||||
|
|
||||||
# Use chroot since the default runc does not work when running rootless
|
# Workaround - the first install somehow leaves the golang in a bad state
|
||||||
RUN echo "export BUILDAH_ISOLATION=chroot" >> /home/build/.bashrc
|
RUN dnf -y install golang
|
||||||
|
|
||||||
# Use VFS since fuse does not work
|
RUN mkdir /root/buildah && \
|
||||||
RUN mkdir -p /home/build/.config/containers \
|
cd /root/buildah && \
|
||||||
&& echo "driver=\"vfs\"" > /home/build/.config/containers/storage.conf
|
git clone https://github.com/harness/buildah.git ./src/github.com/containers/buildah
|
||||||
|
|
||||||
|
RUN cd /root/buildah/src/github.com/containers/buildah && make && sudo make install
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
FROM quay.io/buildah/stable:v1.23.0
|
||||||
|
|
||||||
USER build
|
USER build
|
||||||
WORKDIR /home/build
|
WORKDIR /home/build
|
||||||
|
RUN export STORAGE_DRIVER=vfs
|
||||||
|
COPY --from=0 /root/buildah/src/github.com/containers/buildah/bin/. /bin/
|
||||||
|
|
||||||
# Add plugin binary
|
# Add plugin binary
|
||||||
ADD release/linux/amd64/drone-docker /bin/
|
ADD release/linux/amd64/drone-docker /bin/
|
||||||
|
|||||||
@ -1,21 +1,39 @@
|
|||||||
# Source for dockerfile:
|
FROM fedora
|
||||||
# https://github.com/containers/buildah/blob/master/docs/tutorials/05-openshift-rootless-bud.md
|
|
||||||
FROM quay.io/buildah/stable:v1.14.8
|
|
||||||
|
|
||||||
RUN touch /etc/subgid /etc/subuid \
|
RUN dnf -y install \
|
||||||
&& chmod g=u /etc/subgid /etc/subuid /etc/passwd \
|
make \
|
||||||
&& echo build:10000:65536 > /etc/subuid \
|
golang \
|
||||||
&& echo build:10000:65536 > /etc/subgid
|
bats \
|
||||||
|
btrfs-progs-devel \
|
||||||
|
device-mapper-devel \
|
||||||
|
glib2-devel \
|
||||||
|
gpgme-devel \
|
||||||
|
libassuan-devel \
|
||||||
|
libseccomp-devel \
|
||||||
|
git \
|
||||||
|
bzip2 \
|
||||||
|
go-md2man \
|
||||||
|
runc \
|
||||||
|
containers-common \
|
||||||
|
skopeo-containers
|
||||||
|
|
||||||
# Use chroot since the default runc does not work when running rootless
|
# Workaround - the first install somehow leaves the golang in a bad state
|
||||||
RUN echo "export BUILDAH_ISOLATION=chroot" >> /home/build/.bashrc
|
RUN dnf -y install golang
|
||||||
|
|
||||||
# Use VFS since fuse does not work
|
RUN mkdir /root/buildah && \
|
||||||
RUN mkdir -p /home/build/.config/containers \
|
cd /root/buildah && \
|
||||||
&& echo "driver=\"vfs\"" > /home/build/.config/containers/storage.conf
|
git clone https://github.com/harness/buildah.git ./src/github.com/containers/buildah
|
||||||
|
|
||||||
|
RUN cd /root/buildah/src/github.com/containers/buildah && make && sudo make install
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
FROM quay.io/buildah/stable:v1.23.0
|
||||||
|
|
||||||
USER build
|
USER build
|
||||||
WORKDIR /home/build
|
WORKDIR /home/build
|
||||||
|
RUN export STORAGE_DRIVER=vfs
|
||||||
|
COPY --from=0 /root/buildah/src/github.com/containers/buildah/bin/. /bin/
|
||||||
|
|
||||||
# Add plugin binary
|
# Add plugin binary
|
||||||
ADD release/linux/amd64/drone-docker /bin/
|
ADD release/linux/amd64/drone-docker /bin/
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user