mirror of
https://github.com/Joxit/docker-registry-ui.git
synced 2025-04-25 14:39:54 +03:00
fix(entrypoint): nginx crashes when overriding default.conf
fixes #247 closes #251
This commit is contained in:
parent
1939b47677
commit
c84c9f36e6
7 changed files with 10 additions and 8 deletions
|
@ -23,7 +23,7 @@ ENV NGINX_LISTEN_PORT '80'
|
|||
ENV SHOW_CATALOG_NB_TAGS 'false'
|
||||
|
||||
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY bin/entrypoint /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY bin/90-docker-registry-ui.sh /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY dist/ /usr/share/nginx/html/
|
||||
COPY favicon.ico /usr/share/nginx/html/
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ ENV NGINX_LISTEN_PORT '80'
|
|||
ENV SHOW_CATALOG_NB_TAGS 'false'
|
||||
|
||||
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY bin/entrypoint /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY bin/90-docker-registry-ui.sh /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY dist/ /usr/share/nginx/html/
|
||||
COPY favicon.ico /usr/share/nginx/html/
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ ENV NGINX_LISTEN_PORT '80'
|
|||
ENV SHOW_CATALOG_NB_TAGS 'false'
|
||||
|
||||
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY bin/entrypoint /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY bin/90-docker-registry-ui.sh /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY dist/ /usr/share/nginx/html/
|
||||
COPY favicon.ico /usr/share/nginx/html/
|
||||
|
||||
|
|
|
@ -58,11 +58,13 @@ if [ -n "${NGINX_PROXY_PASS_URL}" ] ; then
|
|||
fi
|
||||
|
||||
if [ "$(whoami)" != "root" ]; then
|
||||
if [ "$NGINX_LISTEN_PORT" = 80 ]; then
|
||||
if [ "$NGINX_LISTEN_PORT" = "80" ]; then
|
||||
NGINX_LISTEN_PORT="8080"
|
||||
fi
|
||||
sed -i "/user nginx;/d" /etc/nginx/nginx.conf
|
||||
sed -i "s,/var/run/nginx.pid,/tmp/nginx.pid," /etc/nginx/nginx.conf
|
||||
fi
|
||||
|
||||
sed -i "s,listen 80;,listen $NGINX_LISTEN_PORT;," /etc/nginx/conf.d/default.conf
|
||||
if [ "$NGINX_LISTEN_PORT" != "80" ]; then
|
||||
sed -i "s,listen 80;,listen $NGINX_LISTEN_PORT;," /etc/nginx/conf.d/default.conf
|
||||
fi
|
|
@ -23,7 +23,7 @@ ENV NGINX_LISTEN_PORT '80'
|
|||
ENV SHOW_CATALOG_NB_TAGS 'false'
|
||||
|
||||
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY bin/entrypoint /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY bin/90-docker-registry-ui.sh /docker-entrypoint.d/90-docker-registry-ui.sh
|
||||
COPY dist/ /usr/share/nginx/html/
|
||||
COPY favicon.ico /usr/share/nginx/html/
|
||||
|
||||
|
|
2
dist/docker-registry-ui.js
vendored
2
dist/docker-registry-ui.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "docker-registry-ui",
|
||||
"version": "2.2.0",
|
||||
"version": "2.2.1",
|
||||
"scripts": {
|
||||
"format": "npm run format-html && npm run format-js && npm run format-riot",
|
||||
"format-html": "find src rollup rollup.config.js -name '*.html' -exec prettier --config .prettierrc -w --parser html {} \\;",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue