updated docker file

pull/24/head
akhilrex 4 years ago
parent 0962aa29ba
commit 566ede9a74

@ -1,8 +1,4 @@
ARG GO_VERSION=1.15.2 ARG GO_VERSION=1.15.2
ENV UID=998
ENV GID=100
ENV CONFIG=/config
ENV DATA=/assets
FROM golang:${GO_VERSION}-alpine AS builder FROM golang:${GO_VERSION}-alpine AS builder
@ -20,6 +16,11 @@ RUN go build -o ./app ./main.go
FROM alpine:latest FROM alpine:latest
ENV UID=998
ENV GID=100
ENV CONFIG=/config
ENV DATA=/assets
RUN apk update && apk add ca-certificates && rm -rf /var/cache/apk/* RUN apk update && apk add ca-certificates && rm -rf /var/cache/apk/*
RUN mkdir -p /api RUN mkdir -p /api
@ -29,9 +30,9 @@ COPY client ./client
RUN mkdir /config; \ RUN mkdir /config; \
mkdir /assets mkdir /assets
RUN groupadd -g ${GID} poduser &&\ # RUN addgroup -g ${GID} poduser &&\
useradd -l -u ${UID} -g poduser poduser &&\ # adduser -l -u ${UID} -g poduser poduser &&\
chown --changes --silent --no-dereference --recursive \ RUN chown --changes --silent --no-dereference --recursive \
${UID}:${GID} \ ${UID}:${GID} \
/assets \ /assets \
/config /config

Loading…
Cancel
Save