Skip to content

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

Allow runtime configuration of nginx listening port (#3219)

sarayourfriend93b64b50685c
diff --git a/frontend/Dockerfile.nginx b/frontend/Dockerfile.nginx
index d8854202f..6e47a8c8f 100644
--- a/frontend/Dockerfile.nginx
+++ b/frontend/Dockerfile.nginx
@@ -27,3 +27,4 @@ ENV OPENVERSE_NGINX_ENVIRONMENT="local"
# Add the release version to the docker container
ARG SEMANTIC_VERSION
ENV OPENVERSE_NGINX_GIT_REVISION=$SEMANTIC_VERSION
+ENV OPENVERSE_NGINX_LISTEN_PORT="8080"
diff --git a/frontend/nginx.conf.template b/frontend/nginx.conf.template
index 268104d00..004092aaf 100644
--- a/frontend/nginx.conf.template
+++ b/frontend/nginx.conf.template
@@ -45,7 +45,7 @@ upstream ov_service {
server {
access_log /var/log/nginx/access.log json_combined;
- listen 8080;
+ listen $OPENVERSE_NGINX_LISTEN_PORT;
server_name _;
charset utf-8;
client_max_body_size 75M;