Добавлен dockercompose

This commit is contained in:
Alexander 2025-05-12 14:26:04 +03:00
parent c76d546df2
commit f4813bf2e7
3 changed files with 42 additions and 0 deletions

13
Dockerfile.client Normal file
View File

@ -0,0 +1,13 @@
FROM golang:1.24.2-alpine
WORKDIR /pocketbase-signer
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN go build -o client ./cmd/client/main.go
CMD ["./client"]

13
Dockerfile.server Normal file
View File

@ -0,0 +1,13 @@
FROM golang:1.24.2-alpine
WORKDIR /pocketbase-signer
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN go build -ldflags="-s -w" -o server ./cmd/server/main.go
CMD ["./server", "serve", "--http=0.0.0.0:8090"]

16
docker-compose.yml Normal file
View File

@ -0,0 +1,16 @@
version: '3.8'
services:
server:
build:
context: .
dockerfile: Dockerfile.server
ports:
- "8090:8090" # Укажите порт сервера
client:
build:
context: .
dockerfile: Dockerfile.client
depends_on:
- server
ports:
- "8080:8080" # Укажите порт клиента