mirror of
https://github.com/amineo/t2-stat-parser.git
synced 2026-07-13 07:14:34 +00:00
Refactor folder structure
This commit is contained in:
parent
24d90a384d
commit
9b4d31f9da
8 changed files with 6 additions and 6 deletions
42
build/go-t2-stat-parser/Dockerfile
Normal file
42
build/go-t2-stat-parser/Dockerfile
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
# [ Stage 1] Builder
|
||||
FROM golang:alpine AS builder
|
||||
|
||||
# Set necessary environmet variables needed for our image
|
||||
ENV GO111MODULE=on \
|
||||
CGO_ENABLED=0 \
|
||||
GOOS=linux \
|
||||
GOARCH=amd64
|
||||
|
||||
|
||||
WORKDIR /app
|
||||
COPY ./app/t2-stat-parser /app
|
||||
|
||||
# Copy and download dependency using go mod
|
||||
RUN go mod download
|
||||
|
||||
|
||||
# # Go Packages
|
||||
# RUN go get -u -v \
|
||||
# # GUID Generator
|
||||
# github.com/rs/xid \
|
||||
# # PostgreSQL Driver
|
||||
# github.com/jackc/pgx \
|
||||
# github.com/jmoiron/sqlx \
|
||||
# # Better Error Handling
|
||||
# github.com/pkg/errors
|
||||
|
||||
RUN go build -o main .
|
||||
|
||||
|
||||
# [ Stage 2]
|
||||
|
||||
FROM golang:alpine
|
||||
|
||||
LABEL maintainer="Anthony Mineo <anthonymineo@gmail.com>"
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY --from=builder /app/main /app/main
|
||||
COPY ./app/t2-stat-parser/start.sh /app/start.sh
|
||||
|
||||
ENTRYPOINT ./start.sh
|
||||
Loading…
Add table
Add a link
Reference in a new issue