Add dockerfiles

This commit is contained in:
2023-09-15 23:23:44 +02:00
parent b455eabb79
commit af83f72dac
4 changed files with 35 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
FROM golang:1.20-alpine
WORKDIR /app
COPY go.mod ./
# go.sum
# RUN go mod download
COPY . .
RUN go build -o ./tide
EXPOSE 7890
CMD ./tide
+6
View File
@@ -0,0 +1,6 @@
FROM golang:1.20-alpine
RUN go install github.com/mitranim/gow@latest
WORKDIR /app
EXPOSE 7890
CMD gow -r=false run .
+12
View File
@@ -0,0 +1,12 @@
version: "3.8"
services:
api:
build:
context: ./api
dockerfile: Dockerfile.dev
ports:
- "7890:7890"
restart: on-failure
volumes:
- ./api:/app
+6
View File
@@ -0,0 +1,6 @@
version: "3.8"
services:
api:
build: ./api
restart: on-failure