vikunja/Dockerfile

42 lines
853 B
Docker
Raw Normal View History

2018-09-08 13:08:33 +00:00
###################################
#Build stage
FROM golang:1.11-alpine3.7 AS build-env
ARG VIKUNJA_VERSION
ENV TAGS "sqlite"
#Build deps
2018-09-08 13:18:57 +00:00
RUN apk --no-cache add build-base git
2018-09-08 13:08:33 +00:00
#Setup repo
COPY . ${GOPATH}/src/code.vikunja.io/vikunja
WORKDIR ${GOPATH}/src/code.vikunja.io/vikunja
#Checkout version if set
RUN if [ -n "${VIKUNJA_VERSION}" ]; then git checkout "${VIKUNJA_VERSION}"; fi \
2018-09-08 13:18:57 +00:00
&& make clean build
2018-09-08 13:08:33 +00:00
FROM alpine:3.7
LABEL maintainer="maintainers@vikunja.io"
EXPOSE 3456
RUN apk --no-cache add \
bash \
ca-certificates \
curl \
gettext \
linux-pam \
s6 \
sqlite \
su-exec \
tzdata
ENTRYPOINT ["/usr/bin/entrypoint"]
CMD ["/bin/s6-svscan", "/etc/s6"]
COPY docker /
COPY --from=build-env /go/src/code.vikunja.io/vikunja/vikunja /app/vikunja/vikunja
RUN ln -s /app/vikunja/vikunja /usr/local/bin/vikunja