Skip to content

Openverse is a search engine for openly-licensed media. This monorepo includes all application code.

Move NGINX-based services out of the API profile (#4416)

Dhruv Bhanushalie003443d5ac2
diff --git a/api/compose.yml b/api/compose.yml
index 18ca2a052..05522403f 100644
--- a/api/compose.yml
+++ b/api/compose.yml
@@ -2,6 +2,7 @@ services:
cache:
profiles:
- api
+ - api_extra
image: docker.io/redis:7.2.4
ports:
- "50263:6379"
@@ -9,6 +10,7 @@ services:
web:
profiles:
- api
+ - api_extra
build:
target: api
additional_contexts:
@@ -35,7 +37,7 @@ services:
nginx:
profiles:
- - api
+ - api_extra
build:
target: nginx
additional_contexts:
@@ -53,7 +55,7 @@ services:
proxy:
profiles:
- - api
+ - api_extra
image: docker.io/nginx:alpine
ports:
- "50200:9080"
diff --git a/api/justfile b/api/justfile
index ee725d8f9..3e0a6fe0d 100644
--- a/api/justfile
+++ b/api/justfile
@@ -48,6 +48,10 @@ install *args:
up *flags:
env COMPOSE_PROFILES="api" just ../up {{ flags }}
+# Bring up services specific to the API profile, in addition to the API server
+up-extra *flags:
+ env COMPOSE_PROFILES="api_extra" just ../up {{ flags }}
+
# Wait for all profile services to be up
wait-up: up
just ../ingestion_server/wait # API profile includes ingestion server
diff --git a/justfile b/justfile
index 0381c3be8..103400c20 100644
--- a/justfile
+++ b/justfile
@@ -204,7 +204,7 @@ up *flags: env && ps
#!/usr/bin/env bash
set -eo pipefail
while true; do
- if just dc up -d {{ flags }} ; then
+ if just dc up {{ if IS_CI != "" { "--quiet-pull" } else { "" } }} -d {{ flags }} ; then
break
fi
((c++)) && ((c==3)) && break