File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 8585 --network=web \
8686 --volume com_profcomff_api_timetable_test_static:/app/static \
8787 --env DB_DSN=${{ secrets.DB_DSN }} \
88+ --env GUNICORN_CMD_ARGS='--log-config logging_test.conf' \
8889 --env GOOGLE_CLIENT_SECRET='${{ secrets.GOOGLE_CLIENT_SECRET }}' \
8990 --env STATIC_PATH=static \
9091 --name ${{ env.CONTAITER_NAME }} \
@@ -131,6 +132,7 @@ jobs:
131132 --env ADMIN_SECRET='${{ secrets.ADMIN_SECRET }}' \
132133 --env REDIRECT_URL='https://www.profcomff.com/timetable/google' \
133134 --env GOOGLE_CLIENT_SECRET='${{ secrets.GOOGLE_CLIENT_SECRET }}' \
135+ --env GUNICORN_CMD_ARGS='--log-config logging_prod.conf' \
134136 --env STATIC_PATH=static \
135137 --name ${{ env.CONTAITER_NAME }} \
136138 ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
Original file line number Diff line number Diff line change @@ -8,6 +8,8 @@ RUN pip install -U -r /app/requirements.txt
88COPY ./static /app/static/
99
1010COPY ./alembic.ini /alembic.ini
11+ COPY ./logging_prod.conf /app/
12+ COPY ./logging_test.conf /app/
1113COPY ./migrations /migrations/
1214
1315COPY ./${APP_NAME} /app/${APP_NAME}
Original file line number Diff line number Diff line change 1+ [loggers]
2+ keys=root,gunicorn.error,gunicorn.access
3+
4+ [handlers]
5+ keys=all
6+
7+ [formatters]
8+ keys=json
9+
10+ [logger_root]
11+ level=INFO
12+ handlers=all
13+
14+ [logger_gunicorn.error]
15+ level=INFO
16+ handlers=all
17+ propagate=0
18+ qualname=gunicorn.error
19+ formatter=json
20+
21+ [logger_gunicorn.access]
22+ level=INFO
23+ handlers=all
24+ propagate=0
25+ qualname=gunicorn.access
26+ formatter=json
27+
28+ [handler_all]
29+ class=StreamHandler
30+ formatter=json
31+ level=INFO
32+ args=(sys.stdout,)
33+
34+ [formatter_json]
35+ class=logger.formatter.JSONLogFormatter
Original file line number Diff line number Diff line change 1+ [loggers]
2+ keys=root,gunicorn.error,gunicorn.access
3+
4+ [handlers]
5+ keys=all
6+
7+ [formatters]
8+ keys=json
9+
10+ [logger_root]
11+ level=DEBUG
12+ handlers=all
13+
14+ [logger_gunicorn.error]
15+ level=DEBUG
16+ handlers=all
17+ propagate=0
18+ qualname=gunicorn.error
19+ formatter=json
20+
21+ [logger_gunicorn.access]
22+ level=DEBUG
23+ handlers=all
24+ propagate=0
25+ qualname=gunicorn.access
26+ formatter=json
27+
28+ [handler_all]
29+ class=StreamHandler
30+ formatter=json
31+ level=DEBUG
32+ args=(sys.stdout,)
33+
34+ [formatter_json]
35+ class=logger.formatter.JSONLogFormatter
Original file line number Diff line number Diff line change @@ -15,4 +15,5 @@ SQLAlchemy
1515gunicorn
1616python-multipart
1717httpx
18- Pillow
18+ Pillow
19+ logging-profcomff
You can’t perform that action at this time.
0 commit comments