feat: update Docker configuration and add nginx setup for reverse proxy
This commit is contained in:
parent
b6d9842bcd
commit
ada7f0b7e0
5 changed files with 29 additions and 3 deletions
|
|
@ -1,3 +1,5 @@
|
|||
.gitignore
|
||||
.git
|
||||
.env
|
||||
.env
|
||||
dev-tester.yml
|
||||
nginx.conf
|
||||
|
|
@ -17,7 +17,7 @@ COPY . .
|
|||
RUN go build -o main .
|
||||
|
||||
# Start a new stage from alpine:latest
|
||||
FROM alpine:latest AS runner
|
||||
FROM alpine:3.22 AS runner
|
||||
|
||||
ARG POSTGRES_USER
|
||||
ARG POSTGRES_PASSWORD
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ const OnboardingServizio = ({
|
|||
width="100%"
|
||||
/>
|
||||
</Row>
|
||||
<Row className="block w-full sm:hidden">
|
||||
<Row className="block w-full ">
|
||||
<div className="mb-[5px] flex h-[24px] w-fit items-center justify-center gap-1 rounded-full bg-indigo-600 px-2 text-[12px] leading-none font-semibold text-white">
|
||||
<strong>Codice: </strong> {annuncio.codice}
|
||||
</div>
|
||||
|
|
|
|||
13
dev-tester.yml
Normal file
13
dev-tester.yml
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
services:
|
||||
reverse-proxy:
|
||||
image: nginx:alpine
|
||||
ports:
|
||||
- "3000:3000" # Expose nginx on host port 3000
|
||||
volumes:
|
||||
- ./nginx.conf:/etc/nginx/conf.d/default.conf # Mount config
|
||||
networks:
|
||||
- dokploy-network
|
||||
|
||||
networks:
|
||||
dokploy-network:
|
||||
external: true
|
||||
11
nginx.conf
Normal file
11
nginx.conf
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
server {
|
||||
listen 3000;
|
||||
|
||||
location / {
|
||||
proxy_pass http://web:3000;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue