use port 8080 instead

So that it doesn't clash with the local react server
pull/4/head
Cameron Clough 2022-03-21 21:44:25 +00:00
parent 3ef44a5ce5
commit cbe4ba728b
No known key found for this signature in database
GPG Key ID: BFB3B74B026ED43F
5 changed files with 11 additions and 11 deletions

View File

@ -14,7 +14,7 @@ ALLOW_REGISTRATION=true
AUTH_2FA_ISSUER=RetroPilot AUTH_2FA_ISSUER=RetroPilot
HTTP_INTERFACE=0.0.0.0 HTTP_INTERFACE=0.0.0.0
HTTP_PORT=3000 HTTP_PORT=8080
# Set to false to skip sending mail, all attempted mail is logged under DEBUG # Set to false to skip sending mail, all attempted mail is logged under DEBUG
CAN_SEND_MAIL=true CAN_SEND_MAIL=true
@ -26,16 +26,16 @@ SMTP_PASS=
SMTP_FROM="no-reply@retropilot.org" SMTP_FROM="no-reply@retropilot.org"
# base url of the retropilot server # base url of the retropilot server
BASE_URL="http://192.168.1.165:3000/" BASE_URL="http://192.168.1.165:8080/"
# base url sent to devices for POSTing drives & logs # base url sent to devices for POSTing drives & logs
BASE_UPLOAD_URL="http://192.168.1.165:3000/backend/post_upload" BASE_UPLOAD_URL="http://192.168.1.165:8080/backend/post_upload"
# base download url for drive & log data # base download url for drive & log data
BASE_DRIVE_DOWNLOAD_URL="http://192.168.1.165:3000/realdata/" BASE_DRIVE_DOWNLOAD_URL="http://192.168.1.165:8080/realdata/"
# path mapping of above download url for expressjs, prefix with "/" # path mapping of above download url for expressjs, prefix with "/"
BASE_DRIVE_DOWNLOAD_PATH_MAPPING="/realdata" BASE_DRIVE_DOWNLOAD_PATH_MAPPING="/realdata"
# relative or absolute ( "/..." for absolute path ) # relative or absolute ( "/..." for absolute path )
STORAGE_PATH="realdata/" STORAGE_PATH="realdata/"
CABANA_URL="http://192.168.1.165:3000/cabana/index.html" CABANA_URL="http://192.168.1.165:8080/cabana/index.html"
DEVICE_STORAGE_QUOTA_MB=200000 DEVICE_STORAGE_QUOTA_MB=200000
DEVICE_EXPIRATION_DAYS=30 DEVICE_EXPIRATION_DAYS=30

View File

@ -23,5 +23,5 @@ RUN npm run build
COPY --from=cabana /cabana/build cabana COPY --from=cabana /cabana/build cabana
EXPOSE 3000 EXPOSE 8080
CMD ["npm", "run", "server"] CMD ["npm", "run", "server"]

View File

@ -18,7 +18,7 @@ server {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://server:3000; proxy_pass http://server:8080;
} }
ssl_certificate /etc/letsencrypt/live/uat.api.retropilot.org/fullchain.pem; ssl_certificate /etc/letsencrypt/live/uat.api.retropilot.org/fullchain.pem;
@ -26,4 +26,4 @@ server {
include /etc/letsencrypt/options-ssl-nginx.conf; include /etc/letsencrypt/options-ssl-nginx.conf;
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
} }

View File

@ -8,7 +8,7 @@ services:
volumes: volumes:
- retropilot-realdata:/realdata - retropilot-realdata:/realdata
ports: ports:
- "3000:3000" - "8080:8080"
- "4040:4040" - "4040:4040"
env_file: env_file:
- .env - .env
@ -30,7 +30,7 @@ services:
image: postgres:14-bullseye image: postgres:14-bullseye
restart: always restart: always
ports: ports:
- '5438:5432' - "5432:5432"
volumes: volumes:
- ./sql/create_tables.sql:/docker-entrypoint-initdb.d/create_tables.sql - ./sql/create_tables.sql:/docker-entrypoint-initdb.d/create_tables.sql
- retropilot-db:/var/lib/postgresql/data - retropilot-db:/var/lib/postgresql/data

View File

@ -54,7 +54,7 @@ if (process.env.ATHENA_ENABLED) {
logger.log('Athena disabled'); logger.log('Athena disabled');
} }
app.use(cors({ origin: 'http://localhost:3000' })); app.use(cors({ origin: 'http://localhost:8080' }));
app.use(cookieParser()); app.use(cookieParser());
app.use('/favicon.ico', express.static('static/favicon.ico')); app.use('/favicon.ico', express.static('static/favicon.ico'));
app.use(process.env.BASE_DRIVE_DOWNLOAD_PATH_MAPPING, express.static(process.env.STORAGE_PATH)); app.use(process.env.BASE_DRIVE_DOWNLOAD_PATH_MAPPING, express.static(process.env.STORAGE_PATH));