Skip to content

Commit

Permalink
add docker file
Browse files Browse the repository at this point in the history
  • Loading branch information
sentriz committed Jul 31, 2019
1 parent 0fab584 commit fced0ac
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.git
.github
.gitignore
.golangci.yml
*testdata*
*_test.go
*.db
README.md
15 changes: 15 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
FROM golang:1.12-alpine AS builder
WORKDIR /src
COPY . .
RUN \
apk add taglib-dev sqlite build-base git && \
./_do_build_server && \
./_do_build_scanner && \
apk del build-base && \
mv ./gonic ./gonicscan /bin/
VOLUME ["/data", "/music"]
EXPOSE 80
ENV GONIC_LISTEN_ADDR :80
ENV GONIC_DB_PATH /data/gonic.db
ENV GONIC_MUSIC_PATH /music
CMD ["gonic"]

0 comments on commit fced0ac

Please sign in to comment.