Tweaking settings...

This commit is contained in:
Scott Idem
2024-04-24 16:50:09 -04:00
parent f9b5186afc
commit 43c4dffa9a
2 changed files with 40 additions and 77 deletions

View File

@@ -160,18 +160,16 @@ upstream fastapi_backend {
# zone backend 64k; # Use NGINX Plus' shared memory
# server webserver1 weight=1;
# server webserver2 weight=4;
# Development Environment
# larger number will recieve more requests
# Example of 20 vs 10: 20 will recieve twice as many requests as 10
server aether_api_gunicorn:5005 weight=20 max_fails=1 fail_timeout=7s;
server aether_api_gunicorn_red:5005 weight=20 max_fails=1 fail_timeout=7s;
server aether_api_gunicorn_green:5005 weight=20 max_fails=1 fail_timeout=7s;
server aether_api_gunicorn_blue:5005 weight=20 max_fails=1 fail_timeout=7s;
server aether_api_gunicorn_black:5005 weight=20 max_fails=1 fail_timeout=7s;
# server aether_api_gunicorn_white:5005 weight=20 max_fails=2 fail_timeout=30s;
server aether_api_gunicorn:5005 weight=20 max_fails=1 fail_timeout=5s;
server aether_api_gunicorn_red:5005 weight=20 max_fails=1 fail_timeout=5s;
server aether_api_gunicorn_green:5005 weight=20 max_fails=1 fail_timeout=5s;
server aether_api_gunicorn_blue:5005 weight=20 max_fails=1 fail_timeout=5s;
# server aether_api_gunicorn_black:5005 weight=20 max_fails=1 fail_timeout=5s;
# server aether_api_gunicorn_white:5005 weight=20 max_fails=1 fail_timeout=5s;
# maintain up to 20 idle connections to the group of upstream servers
keepalive 16;
keepalive 10;
}

View File

@@ -1,5 +1,3 @@
version: "3.9"
services:
web:
restart: unless-stopped
@@ -305,41 +303,41 @@ services:
tty: true # docker run -t
# API - Black
aether_api_gunicorn_black:
restart: always
container_name: ${CONTAINER_AE_API_BLACK}
build:
# context: ./builds
context: ./
dockerfile: aether_fastapi_gunicorn.Dockerfile
env_file:
- ./.env
ports:
- "${AE_API_GUNICORN_PORT_BLACK}:5005"
extra_hosts:
- "${DOCKER_AE_SERVER_EXTRA_HOST}"
- "${DOCKER_AE_APP_SERVER_EXTRA_HOST}"
- "${DOCKER_AE_API_SERVER_EXTRA_HOST}"
- "${DOCKER_AE_API_BAK_SERVER_EXTRA_HOST}"
- "${DOCKER_AE_DB_SERVER_EXTRA_HOST}"
- "linode.oneskyit.com:104.237.143.4"
# - "db.oneskyit.com:104.237.143.4"
volumes:
- ./conf/aether_fastapi_gunicorn_conf.py:/conf/gunicorn_fastapi_conf.py
- ./conf/aether_fastapi_requirements_current.txt:/requirements_current.txt
- ./conf/aether_api_config.py:/srv/aether_api/app/config.py
# aether_api_gunicorn_black:
# restart: always
# container_name: ${CONTAINER_AE_API_BLACK}
# build:
# # context: ./builds
# context: ./
# dockerfile: aether_fastapi_gunicorn.Dockerfile
# env_file:
# - ./.env
# ports:
# - "${AE_API_GUNICORN_PORT_BLACK}:5005"
# extra_hosts:
# - "${DOCKER_AE_SERVER_EXTRA_HOST}"
# - "${DOCKER_AE_APP_SERVER_EXTRA_HOST}"
# - "${DOCKER_AE_API_SERVER_EXTRA_HOST}"
# - "${DOCKER_AE_API_BAK_SERVER_EXTRA_HOST}"
# - "${DOCKER_AE_DB_SERVER_EXTRA_HOST}"
# - "linode.oneskyit.com:104.237.143.4"
# # - "db.oneskyit.com:104.237.143.4"
# volumes:
# - ./conf/aether_fastapi_gunicorn_conf.py:/conf/gunicorn_fastapi_conf.py
# - ./conf/aether_fastapi_requirements_current.txt:/requirements_current.txt
# - ./conf/aether_api_config.py:/srv/aether_api/app/config.py
- ./logs/ae_api:/logs
# - ./logs/ae_api:/logs
- ./srv/aether_api_ln:/srv/aether_api
- ./srv/hosted_files_ln:/srv/hosted_files
- ./srv/hosted_tmp_ln:/srv/hosted_tmp
# - ./srv/aether_api_ln:/srv/aether_api
# - ./srv/hosted_files_ln:/srv/hosted_files
# - ./srv/hosted_tmp_ln:/srv/hosted_tmp
- ./temp/ae_api:/temp
depends_on:
- redis
stdin_open: true
tty: true
# - ./temp/ae_api:/temp
# depends_on:
# - redis
# stdin_open: true
# tty: true
# API - White
# aether_api_gunicorn_white:
@@ -375,39 +373,6 @@ services:
# tty: true
# aether_api_v5_gunicorn:
# restart: always
# container_name: ae_api_v5_dev
# build:
# # context: ./builds
# context: ./
# dockerfile: aether_api_v5_fastapi_gunicorn.Dockerfile
# env_file:
# - ./.env
# ports:
# - "5067:5005"
# volumes:
# - ./conf/aether_api_v5_fastapi_gunicorn_conf.py:/conf/gunicorn_fastapi_conf.py
# - ./conf/aether_api_v5_fastapi_requirements_current.txt:/conf/requirements_current.txt
# - ./conf/aether_api_v5_fastapi_config.py:/srv/aether_api/app/config.py
#
# - ./logs/ae_api_v5:/logs
#
# - ./srv/aether_api_v5_ln:/srv/aether_api
# - ./srv/hosted_files_ln:/srv/hosted_files
# - ./srv/hosted_tmp_ln:/srv/hosted_tmp
#
# # - ./tmp/ae_api:/tmp
#
# - ./temp/ae_api:/temp
# # - ./temp/ae_api/aether_fastapi_requirements_current.txt:/temp/requirements_current.txt
# # links:
# # - redis
# depends_on:
# - redis
# stdin_open: true # docker run -i
# tty: true # docker run -t
aether_app_gunicorn:
restart: always
container_name: ${CONTAINER_AE_APP}