Refactor Docker entrypoints and remove unused scripts

- Removed custom entrypoint scripts for backend, frontend, and PostgreSQL services from docker-compose files.
- Added a new entrypoint script in the backend and frontend Dockerfiles to handle initialization without relying on host-mounted scripts.
- Updated Dockerfiles to ensure proper permissions for the new entrypoint scripts.
- Enhanced database initialization logic by moving schema and extension creation to the Alembic migration script.
This commit is contained in:
2026-04-24 12:53:11 -05:00
parent e1d07ba460
commit 9d63b000bc
12 changed files with 102 additions and 173 deletions

View File

@@ -42,6 +42,10 @@ COPY requirements.txt .
# Instalar dependencias Python
RUN pip install --no-cache-dir -r requirements.txt
# Entrypoint (espera Postgres/Keycloak; no montar desde el host)
COPY docker-entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
# Copiar código
COPY . .
@@ -52,5 +56,7 @@ ENV APP_VERSION=${APP_VERSION}
# Exponer puerto
EXPOSE 8000
ENTRYPOINT ["/entrypoint.sh"]
# Comando por defecto
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]