Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 34ae46f

Browse files
committed
Add gh binary and fix /home/user folder permissions
1 parent e69fce6 commit 34ae46f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

Containerfile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM quay.io/fedora/fedora:41
33

44
ARG USER_HOME_DIR="/home/user"
55
ARG WORK_DIR="/projects"
6-
ARG INSTALL_PACKAGES="procps-ng openssl git tar gzip zip xz unzip which shadow-utils bash zsh vi wget jq podman buildah skopeo podman-docker glibc-devel zlib-devel gcc libffi-devel libstdc++-devel gcc-c++ glibc-langpack-en ca-certificates python3-pip python3-devel fuse-overlayfs util-linux vim-minimal vim-enhanced"
6+
ARG INSTALL_PACKAGES="procps-ng openssl git tar gzip zip xz unzip which shadow-utils bash zsh vi wget jq gh podman buildah skopeo podman-docker glibc-devel zlib-devel gcc libffi-devel libstdc++-devel gcc-c++ glibc-langpack-en ca-certificates python3-pip python3-devel fuse-overlayfs util-linux vim-minimal vim-enhanced"
77

88
ENV HOME=${USER_HOME_DIR} \
99
KUBECONFIG=/home/user/.kube/config \
@@ -98,7 +98,11 @@ RUN dnf -y -q install --setopt=tsflags=nodocs \
9898
echo -n "yq: "; yq --version; \
9999
echo "========"
100100

101-
USER 1001
101+
# USER 1001
102+
USER root
103+
104+
# A last pass to make sure that an arbitrary user can write in $HOME
105+
RUN chgrp -R 0 /home && chmod -R g=u /home
102106

103107
WORKDIR ${WORK_DIR}
104108
ENTRYPOINT [ "/entrypoint.sh" ]

0 commit comments

Comments
 (0)