A clean, Markdown-based publishing platform made for writers. Write together, and build a community. https://writefreely.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

34 lines
620 B

  1. FROM golang:1.11.2-alpine3.8 as build
  2. RUN apk add --update nodejs nodejs-npm make git
  3. RUN npm install -g less
  4. RUN npm install -g less-plugin-clean-css
  5. WORKDIR /go/src/app
  6. COPY . .
  7. RUN make install
  8. RUN make ui
  9. RUN make deps
  10. RUN mkdir /stage && \
  11. cp -R /go/bin \
  12. /go/src/app/templates \
  13. /go/src/app/static \
  14. /go/src/app/schema.sql \
  15. /go/src/app/pages \
  16. /go/src/app/keys \
  17. /stage
  18. FROM alpine:3.8
  19. RUN apk add --no-cache openssl ca-certificates
  20. COPY --from=build --chown=daemon:daemon /stage /go
  21. WORKDIR /go
  22. VOLUME /go/keys
  23. EXPOSE 8080
  24. USER daemon
  25. CMD ["bin/writefreely"]