ci: Enable sudo in the image

This is needed so we can install what we built.
This commit is contained in:
Matthias Clasen 2020-08-01 22:11:07 -04:00
parent aea253bc60
commit 501b2b43ef

View File

@ -1,8 +1,11 @@
FROM registry.gitlab.gnome.org/gnome/gtk/fedora-base:v21
# Enable sudo for wheel users
RUN sed -i -e 's/# %wheel/%wheel/' -e '0,/%wheel/{s/%wheel/# %wheel/}' /etc/sudoers
ARG HOST_USER_ID=5555
ENV HOST_USER_ID ${HOST_USER_ID}
RUN useradd -u $HOST_USER_ID -ms /bin/bash user
RUN useradd -u $HOST_USER_ID -G wheel -ms /bin/bash user
USER user
WORKDIR /home/user