mirror of
https://github.com/ijaric/voice_assistant.git
synced 2025-05-24 14:33:26 +00:00
fix: docker files & minor fixes
This commit is contained in:
parent
5a02281651
commit
8dead13cc2
|
@ -1,5 +1,11 @@
|
|||
FROM python:3.11
|
||||
|
||||
RUN apt-get update \
|
||||
&& DEBIAN_FRONTEND=noninteractive \
|
||||
&& apt-get install -y net-tools netcat-traditional curl \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN mkdir --parents /opt/app
|
||||
COPY pyproject.toml /opt/app/pyproject.toml
|
||||
COPY poetry.lock /opt/app/poetry.lock
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
version: "3"
|
||||
|
||||
services:
|
||||
db:
|
||||
postgres:
|
||||
image: postgres:15.2
|
||||
restart: always
|
||||
environment:
|
||||
|
@ -29,7 +29,7 @@ services:
|
|||
ports:
|
||||
- "${API_PORT}:${API_PORT}"
|
||||
depends_on:
|
||||
- db
|
||||
- postgres
|
||||
networks:
|
||||
- backend_network
|
||||
- api_network
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
version: "3"
|
||||
|
||||
services:
|
||||
db:
|
||||
postgres:
|
||||
image: postgres:15.2
|
||||
restart: always
|
||||
environment:
|
||||
|
@ -29,7 +29,7 @@ services:
|
|||
expose:
|
||||
- "${API_PORT}"
|
||||
depends_on:
|
||||
- db
|
||||
- postgres
|
||||
networks:
|
||||
- backend_network
|
||||
- api_network
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
#!/bin/bash
|
||||
|
||||
while ! (echo > /dev/tcp/db/5432) >/dev/null 2>&1; do
|
||||
sleep 1
|
||||
done
|
||||
while ! nc -z postgres 5432; do sleep 1; done;
|
||||
|
||||
exec .venv/bin/python -m bin
|
|
@ -6,7 +6,7 @@ from .project import *
|
|||
__all__ = [
|
||||
"ApiSettings",
|
||||
"LoggingSettings",
|
||||
"get_logging_config",
|
||||
"PostgresSettings",
|
||||
"ProjectSettings",
|
||||
"get_logging_config",
|
||||
]
|
||||
|
|
|
@ -4,7 +4,7 @@ server {
|
|||
server_name _;
|
||||
|
||||
location /api {
|
||||
proxy_pass http://api:${SERVER_PORT}/api;
|
||||
proxy_pass http://api:${API_PORT}/api;
|
||||
proxy_set_header X-Request-Id $request_id;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user