udpated api proxy

This commit is contained in:
liquidrinu 2025-05-15 18:55:18 +02:00
parent 5b4c85e612
commit 85f53a81be
2 changed files with 11 additions and 3 deletions

@ -107,7 +107,15 @@ The frontend will be available at http://localhost:3000
docker-compose up --build
```
2. **Environment Variables**
2. **Run Migrations and Seeders in Production**
After your containers are up, run the following commands to apply database migrations and seed data inside the backend container:
```bash
docker exec -it fusero-app-backend npx mikro-orm migration:up
docker exec -it fusero-app-backend npm run seed
```
**Note:** These commands must be run inside the backend container so they use the correct Docker network and environment variables.
3. **Environment Variables**
- Ensure all environment variables are properly set in your production environment
- Never commit `.env` files to version control

@ -3,7 +3,7 @@ server {
server_name _;
location ^~ /api/ {
proxy_pass http://fusero-app-backend:14000/;
proxy_pass http://fusero-app-backend:14000/api/;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
@ -29,7 +29,7 @@ server {
ssl_certificate_key /etc/nginx/certs/fusero-selfsigned.key;
location ^~ /api/ {
proxy_pass http://fusero-app-backend:14000/;
proxy_pass http://fusero-app-backend:14000/api/;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;