Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 96fc6a2

Browse files
authoredJan 10, 2024
Merge pull request #3444 from NginxProxyManager/bookworm-base
Use nginxproxymanager/nginx-full image base
2 parents be39253 + e696849 commit 96fc6a2

File tree

17 files changed

+666
-432
lines changed

17 files changed

+666
-432
lines changed
 

‎Jenkinsfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,12 +240,12 @@ pipeline {
240240
sh 'figlet "SUCCESS"'
241241
}
242242
failure {
243-
archiveArtifacts(artifacts: 'debug/**.*', allowEmptyArchive: true)
243+
archiveArtifacts(artifacts: 'debug/**/*.*', allowEmptyArchive: true)
244244
juxtapose event: 'failure'
245245
sh 'figlet "FAILURE"'
246246
}
247247
unstable {
248-
archiveArtifacts(artifacts: 'debug/**.*', allowEmptyArchive: true)
248+
archiveArtifacts(artifacts: 'debug/**/*.*', allowEmptyArchive: true)
249249
juxtapose event: 'unstable'
250250
sh 'figlet "UNSTABLE"'
251251
}

‎backend/internal/proxy-host.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ const internalProxyHost = {
225225
.query()
226226
.where('is_deleted', 0)
227227
.andWhere('id', data.id)
228-
.allowGraph('[owner,access_list,access_list.[clients,items],certificate]')
228+
.allowGraph('[owner,access_list.[clients,items],certificate]')
229229
.first();
230230

231231
if (access_data.permission_visibility !== 'all') {

‎docker/Dockerfile

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
# This file assumes that the frontend has been built using ./scripts/frontend-build
55

6-
FROM jc21/nginx-full:certbot-node
6+
FROM nginxproxymanager/nginx-full:certbot-node
77

88
ARG TARGETPLATFORM
99
ARG BUILD_VERSION
@@ -20,7 +20,8 @@ ENV SUPPRESS_NO_CONFIG_WARNING=1 \
2020
NODE_ENV=production \
2121
NPM_BUILD_VERSION="${BUILD_VERSION}" \
2222
NPM_BUILD_COMMIT="${BUILD_COMMIT}" \
23-
NPM_BUILD_DATE="${BUILD_DATE}"
23+
NPM_BUILD_DATE="${BUILD_DATE}" \
24+
NODE_OPTIONS="--openssl-legacy-provider"
2425

2526
RUN echo "fs.file-max = 65535" > /etc/sysctl.conf \
2627
&& apt-get update \
@@ -47,9 +48,7 @@ COPY docker/rootfs /
4748

4849
# Remove frontend service not required for prod, dev nginx config as well
4950
RUN rm -rf /etc/s6-overlay/s6-rc.d/user/contents.d/frontend /etc/nginx/conf.d/dev.conf \
50-
&& chmod 644 /etc/logrotate.d/nginx-proxy-manager \
51-
&& pip uninstall --yes setuptools \
52-
&& pip install --no-cache-dir "setuptools==58.0.0"
51+
&& chmod 644 /etc/logrotate.d/nginx-proxy-manager
5352

5453
VOLUME [ "/data", "/etc/letsencrypt" ]
5554
ENTRYPOINT [ "/init" ]

‎docker/dev/Dockerfile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM jc21/nginx-full:certbot-node
1+
FROM nginxproxymanager/nginx-full:certbot-node
22
LABEL maintainer="Jamie Curnow <jc@jc21.com>"
33

44
# See: https://github.com/just-containers/s6-overlay/blob/master/README.md
@@ -7,7 +7,8 @@ ENV SUPPRESS_NO_CONFIG_WARNING=1 \
77
S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0 \
88
S6_FIX_ATTRS_HIDDEN=1 \
99
S6_KILL_FINISH_MAXTIME=10000 \
10-
S6_VERBOSITY=2
10+
S6_VERBOSITY=2 \
11+
NODE_OPTIONS="--openssl-legacy-provider"
1112

1213
RUN echo "fs.file-max = 65535" > /etc/sysctl.conf \
1314
&& apt-get update \

‎docker/docker-compose.ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ services:
2222
depends_on:
2323
- db
2424
healthcheck:
25-
test: ["CMD", "/bin/check-health"]
25+
test: ["CMD", "/usr/bin/check-health"]
2626
interval: 10s
2727
timeout: 3s
2828

@@ -43,7 +43,7 @@ services:
4343
- 80
4444
- 443
4545
healthcheck:
46-
test: ["CMD", "/bin/check-health"]
46+
test: ["CMD", "/usr/bin/check-health"]
4747
interval: 10s
4848
timeout: 3s
4949

‎docker/rootfs/etc/s6-overlay/s6-rc.d/backend/run

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
set -e
55

6-
. /bin/common.sh
6+
. /usr/bin/common.sh
77

88
cd /app || exit 1
99

‎docker/rootfs/etc/s6-overlay/s6-rc.d/frontend/run

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ set -e
66
# This service is DEVELOPMENT only.
77

88
if [ "$DEVELOPMENT" = 'true' ]; then
9-
. /bin/common.sh
9+
. /usr/bin/common.sh
1010
cd /app/frontend || exit 1
1111
HOME=$NPMHOME
1212
export HOME

‎docker/rootfs/etc/s6-overlay/s6-rc.d/nginx/run

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
set -e
55

6-
. /bin/common.sh
6+
. /usr/bin/common.sh
77

88
log_info 'Starting nginx ...'
99
exec s6-setuidgid "$PUID:$PGID" nginx

‎docker/rootfs/etc/s6-overlay/s6-rc.d/prepare/00-all.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
set -e
55

6-
. /bin/common.sh
6+
. /usr/bin/common.sh
77

88
if [ "$(id -u)" != "0" ]; then
99
log_fatal "This docker container must be run as root, do not specify a user.\nYou can specify PUID and PGID env vars to run processes as that user and group after initialization."

‎docker/rootfs/etc/s6-overlay/s6-rc.d/prepare/30-ownership.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ chown -R "$PUID:$PGID" /etc/nginx/nginx.conf
2424
chown -R "$PUID:$PGID" /etc/nginx/conf.d
2525

2626
# Prevents errors when installing python certbot plugins when non-root
27-
chown -R "$PUID:$PGID" /opt/certbot/lib/python3.7/site-packages
27+
chown -R "$PUID:$PGID" /opt/certbot/lib/python*/site-packages
File renamed without changes.
File renamed without changes.

‎docs/advanced-config/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ feature by adding the following to the service in your `docker-compose.yml` file
7676

7777
```yml
7878
healthcheck:
79-
test: ["CMD", "/bin/check-health"]
79+
test: ["CMD", "/usr/bin/check-health"]
8080
interval: 10s
8181
timeout: 3s
8282
```

‎frontend/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@
2727
"messageformat-loader": "^0.8.1",
2828
"mini-css-extract-plugin": "^0.9.0",
2929
"moment": "^2.29.4",
30-
"node-sass": "^6.0.1",
30+
"node-sass": "^9.0.0",
3131
"nodemon": "^2.0.2",
3232
"numeral": "^2.0.6",
33-
"sass-loader": "10.2.0",
33+
"sass-loader": "^10.0.0",
3434
"style-loader": "^1.1.3",
3535
"tabler-ui": "git+https://github.com/tabler/tabler.git#00f78ad823311bc3ad974ac3e5b0126198f0a813",
3636
"underscore": "^1.12.1",

‎frontend/yarn.lock

Lines changed: 626 additions & 408 deletions
Large diffs are not rendered by default.

‎scripts/ci/frontend-build

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,22 @@
33
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
44
. "$DIR/../.common.sh"
55

6-
DOCKER_IMAGE=jc21/nginx-full:certbot-node
6+
DOCKER_IMAGE=nginxproxymanager/nginx-full:certbot-node
77

88
# Ensure docker exists
99
if hash docker 2>/dev/null; then
1010
docker pull "${DOCKER_IMAGE}"
1111
cd "${DIR}/../.."
1212
echo -e "${BLUE}${CYAN}Building Frontend ...${RESET}"
13-
docker run --rm -e CI=true -v "$(pwd)/frontend:/app/frontend" -v "$(pwd)/global:/app/global" -w /app/frontend "$DOCKER_IMAGE" sh -c "yarn install && yarn build && yarn build && chown -R $(id -u):$(id -g) /app/frontend"
13+
14+
docker run --rm \
15+
-e CI=true \
16+
-e NODE_OPTIONS=--openssl-legacy-provider \
17+
-v "$(pwd)/frontend:/app/frontend" \
18+
-v "$(pwd)/global:/app/global" \
19+
-w /app/frontend "$DOCKER_IMAGE" \
20+
sh -c "yarn install && yarn build && yarn build && chown -R $(id -u):$(id -g) /app/frontend"
21+
1422
echo -e "${BLUE}${GREEN}Building Frontend Complete${RESET}"
1523
else
1624
echo -e "${RED}❯ docker command is not available${RESET}"

‎scripts/ci/test-and-build

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,31 @@
11
#!/bin/bash -e
22

3-
DOCKER_IMAGE=jc21/nginx-full:certbot-node
3+
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
. "$DIR/../.common.sh"
5+
6+
DOCKER_IMAGE=nginxproxymanager/nginx-full:certbot-node
47
docker pull "${DOCKER_IMAGE}"
58

69
# Test
10+
echo -e "${BLUE}${CYAN}Testing backend ...${RESET}"
711
docker run --rm \
812
-v "$(pwd)/backend:/app" \
913
-v "$(pwd)/global:/app/global" \
1014
-w /app \
1115
"${DOCKER_IMAGE}" \
1216
sh -c 'yarn install && yarn eslint . && rm -rf node_modules'
17+
echo -e "${BLUE}${GREEN}Testing Complete${RESET}"
1318

1419
# Build
15-
docker build --pull --no-cache --squash --compress \
20+
echo -e "${BLUE}${CYAN}Building ...${RESET}"
21+
docker build --pull --no-cache --compress \
1622
-t "${IMAGE}:ci-${BUILD_NUMBER}" \
1723
-f docker/Dockerfile \
24+
--progress=plain \
1825
--build-arg TARGETPLATFORM=linux/amd64 \
1926
--build-arg BUILDPLATFORM=linux/amd64 \
2027
--build-arg BUILD_VERSION="${BUILD_VERSION}" \
2128
--build-arg BUILD_COMMIT="${BUILD_COMMIT}" \
2229
--build-arg BUILD_DATE="$(date '+%Y-%m-%d %T %Z')" \
2330
.
31+
echo -e "${BLUE}${GREEN}Building Complete${RESET}"

0 commit comments

Comments
 (0)
Please sign in to comment.