1
0
mirror of https://github.com/tommytran732/Matrix.to-Docker synced 2024-11-22 01:51:33 -05:00

Build as unprivileged user

Signed-off-by: Tommy <contact@tommytran.io>
This commit is contained in:
Tommy 2023-03-16 20:43:28 -04:00
parent 334aadf1f2
commit 6c717e1db0
No known key found for this signature in database
GPG Key ID: 060B29EB996BD9F2

View File

@ -9,13 +9,17 @@ RUN apk -U upgrade \
&& apk --no-cache add git \
&& adduser -g ${GID} -u ${UID} --disabled-password --gecos "" matrix-to
RUN git clone https://github.com/matrix-org/matrix.to \
&& cd matrix.to \
&& yarn \
&& yarn build
USER matrix-to
WORKDIR /home/matrix-to
RUN git clone https://github.com/matrix-org/matrix.to
WORKDIR /home/matrix-to/matrix.to
RUN yarn \
&& yarn build
EXPOSE 5000
ENTRYPOINT ["yarn", "start"]