1
0
mirror of https://github.com/JustKato/FreePad.git synced 2026-02-23 15:50:46 +02:00

Initial Commit

This commit is contained in:
2022-05-15 12:43:42 +03:00
commit 21b8605fc0
21 changed files with 282 additions and 0 deletions

21
Dockerfile Normal file
View File

@@ -0,0 +1,21 @@
FROM golang:1.18.2-alpine
ENV GO111MODULE=on
ENV MYSQL_USER=${MYSQL_USER}
ENV MYSQL_PASSWORD=${MYSQL_PASSWORD}
ENV MYSQL_DATABASE=${MYSQL_DATABASE}
RUN mkdir /app
WORKDIR /app
COPY . /app
# Install & Run migrations
RUN wget -O /tmp/migrations.tar.gz "https://github.com/golang-migrate/migrate/releases/download/v4.15.2/migrate.linux-386.tar.gz" && \
tar -xzvf /tmp/migrations.tar.gz -C /tmp/ && \
mv /tmp/migrate /usr/bin/migrate
EXPOSE 8080
CMD ["sh", "run.sh"]