fix(infra): lab5 fix docker entrypoints, migration index and worker deps
This commit is contained in:
+1
-1
@@ -33,4 +33,4 @@ USER app
|
|||||||
HEALTHCHECK --interval=10s --timeout=3s --start-period=5s --retries=3 \
|
HEALTHCHECK --interval=10s --timeout=3s --start-period=5s --retries=3 \
|
||||||
CMD wget -q -O - http://127.0.0.1:8080/health/live >/dev/null || exit 1
|
CMD wget -q -O - http://127.0.0.1:8080/health/live >/dev/null || exit 1
|
||||||
|
|
||||||
ENTRYPOINT ["/server"]
|
CMD ["/server"]
|
||||||
@@ -13,6 +13,7 @@ ALTER TABLE attachments ADD CONSTRAINT attachments_error_code_consistency
|
|||||||
);
|
);
|
||||||
|
|
||||||
DROP INDEX IF EXISTS attachments_pending_idx;
|
DROP INDEX IF EXISTS attachments_pending_idx;
|
||||||
|
DROP INDEX IF EXISTS attachments_active_idx;
|
||||||
CREATE INDEX attachments_active_idx
|
CREATE INDEX attachments_active_idx
|
||||||
ON attachments (created_at)
|
ON attachments (created_at)
|
||||||
WHERE status IN ('queued', 'processing');
|
WHERE status IN ('queued', 'processing');
|
||||||
|
|||||||
+3
-1
@@ -143,7 +143,7 @@ services:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
image: mtusi-messenger-api:lab3
|
image: mtusi-messenger-api:lab3
|
||||||
restart: "no"
|
restart: "no"
|
||||||
command: ["migrate"]
|
command: ["/server", "migrate"]
|
||||||
environment:
|
environment:
|
||||||
DATABASE_URL_FILE: /run/secrets/database_url
|
DATABASE_URL_FILE: /run/secrets/database_url
|
||||||
secrets:
|
secrets:
|
||||||
@@ -250,6 +250,8 @@ services:
|
|||||||
condition: service_completed_successfully
|
condition: service_completed_successfully
|
||||||
minio:
|
minio:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
mc-init:
|
||||||
|
condition: service_completed_successfully
|
||||||
rabbitmq:
|
rabbitmq:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
deploy:
|
deploy:
|
||||||
|
|||||||
Reference in New Issue
Block a user