Initialize Tinder API Wrapper with server configuration and Docker setup
This commit is contained in:
commit
e99b56e434
17 changed files with 1459 additions and 0 deletions
25
cmd/server/Dockerfile
Normal file
25
cmd/server/Dockerfile
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
FROM golang:1.18-alpine AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy go mod files
|
||||
COPY go.mod ./
|
||||
COPY go.sum ./
|
||||
RUN go mod download
|
||||
|
||||
# Copy source code
|
||||
COPY . .
|
||||
|
||||
# Build the application
|
||||
RUN go build -o /tinder-proxy ./cmd/server
|
||||
|
||||
# Use a smaller image for the final container
|
||||
FROM alpine:latest
|
||||
|
||||
WORKDIR /
|
||||
|
||||
COPY --from=builder /tinder-proxy /tinder-proxy
|
||||
|
||||
EXPOSE 8080
|
||||
|
||||
ENTRYPOINT ["/tinder-proxy"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue