docker-wahay/wahay/Dockerfile

18 lines
1009 B
Docker
Raw Normal View History

2020-05-29 15:37:29 +00:00
FROM golang
2020-05-29 17:11:38 +00:00
ENV UNAME mumble
RUN apt update && apt upgrade -y && apt install -y curl lsb-release dirmngr pulseaudio-utils && apt clean
2020-05-29 15:37:29 +00:00
RUN curl -s https://dl.autonomia.digital/debian/keys.asc | apt-key add -
RUN echo deb https://dl.autonomia.digital/debian $(lsb_release -c | cut -f 2) main | tee /etc/apt/sources.list.d/wahay.list
RUN echo deb-src https://dl.autonomia.digital/debian $(lsb_release -c | cut -f 2) main | tee -a /etc/apt/sources.list.d/wahay.list
2020-05-29 17:11:38 +00:00
RUN apt update && apt install -y wahay && apt clean
RUN export UNAME=$UNAME UID=1000 GID=1000 && \
mkdir -p "/home/${UNAME}" && \
echo "${UNAME}:x:${UID}:${GID}:${UNAME} User,,,:/home/${UNAME}:/bin/bash" >> /etc/passwd && \
echo "${UNAME}:x:${UID}:" >> /etc/group && \
mkdir -p /etc/sudoers.d && \
echo "${UNAME} ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/${UNAME} && \
chmod 0440 /etc/sudoers.d/${UNAME} && \
chown ${UID}:${GID} -R /home/${UNAME} && \
gpasswd -a ${UNAME} audio
USER ${UNAME}
ENTRYPOINT [ "wahay" ]