Skip to content

Commit cd029a8

Browse files
Tested with NGINX Instance Manager 2.12.0 (#108)
* Added API Connectivity Manager 1.5.0 support * Ownership fix * Startup script fix * NGINX App Protect WAF updates * Tested with NGINX Instance Manager 2.9.1 * Added docker-compose support * Tested with NGINX Instance Manager 2.10.0 and Security Monitoring 1.4.0 * Tested with NGINX Instance Manager 2.10.0 and API Connectivity Manager 1.5.0 * Tested with API Connectivity Manager 1.6.0 * Tested with API Connectivity Manager 1.6.0 * README updated * Added support for NGINX Instance Manager 2.10.1 and App Delivery Manager 4.0.0 * Fixed NGINX App Protect detection bug for NGINX Instance Manager 2.10.0+ * Fixed agent syslog receiver bug * README updated * Tested with NGINX Instance Manager 2.11.0 and Security Monitoring 1.5.0 * Tested with NGINX Instance Manager 2.11.0 * Tested with NGINX API Connectivity Manager 1.7.0 * Tested with NGINX Instance Manager 2.12.0 and Security Monitoring 1.6.0 * Tested with API Connectivity Manager 1.8.0 * Tested with API Connectivity Manager 1.8.0 * Tested with NGINX Instance Manager 2.12.0 --------- Signed-off-by: 65397 <[email protected]>
1 parent 5b1b25c commit cd029a8

File tree

2 files changed

+14
-13
lines changed

2 files changed

+14
-13
lines changed

nginx-agent-docker/Dockerfile

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,14 @@ ARG NAP_WAF=false
77
# Initial packages setup
88
RUN apt-get -y update \
99
&& apt-get -y install apt-transport-https lsb-release ca-certificates wget gnupg2 curl debian-archive-keyring \
10-
# NGINX Instance Manager agent setup
1110
&& mkdir -p /deployment /etc/ssl/nginx \
12-
# Agent installation
13-
&& bash -c 'curl -k $NMS_URL/install/nginx-agent | sh' && echo "Agent installed from NMS"
14-
15-
# Startup script
16-
COPY ./container/start.sh /deployment/
11+
&& addgroup --system --gid 20983 nginx \
12+
&& adduser --system --disabled-login --ingroup nginx --no-create-home --home /nonexistent --gecos "nginx user" --shell /bin/false --uid 20983 nginx
1713

18-
# Download certificate and key from the customer portal (https://account.f5.com)
19-
# and copy to the build context
14+
# Use certificate and key from kubernetes secret
2015
RUN --mount=type=secret,id=nginx-crt,dst=/etc/ssl/nginx/nginx-repo.crt,mode=0644 \
2116
--mount=type=secret,id=nginx-key,dst=/etc/ssl/nginx/nginx-repo.key,mode=0644 \
2217
set -x \
23-
# Startup script
24-
&& chmod +x /deployment/start.sh && touch /.dockerenv \
2518
# Install prerequisite packages:
2619
&& wget -qO - https://cs.nginx.com/static/keys/nginx_signing.key | gpg --dearmor > /usr/share/keyrings/nginx-archive-keyring.gpg \
2720
&& printf "deb [signed-by=/usr/share/keyrings/nginx-archive-keyring.gpg] https://pkgs.nginx.com/plus/debian `lsb_release -cs` nginx-plus\n" > /etc/apt/sources.list.d/nginx-plus.list \
@@ -53,7 +46,15 @@ RUN --mount=type=secret,id=nginx-crt,dst=/etc/ssl/nginx/nginx-repo.crt,mode=0644
5346

5447
&& groupadd -g 1001 nginx-agent \
5548
&& usermod root -G nginx-agent \
56-
&& usermod nginx -G nginx-agent
49+
&& usermod nginx -G nginx-agent \
50+
51+
# NGINX Instance Manager agent installation
52+
&& bash -c 'curl -k $NMS_URL/install/nginx-agent | sh' && echo "Agent installed from NMS"
53+
54+
# Startup script
55+
COPY ./container/start.sh /deployment/
56+
RUN chmod +x /deployment/start.sh && touch /.dockerenv
57+
5758

5859
EXPOSE 80
5960
STOPSIGNAL SIGTERM

nginx-agent-docker/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ This repository can be used to build a docker image with NGINX Plus and NGINX In
88

99
This repository has been tested with NGINX agent for:
1010

11-
- NGINX Instance Manager 2.4.0, 2.5.0, 2.5.1, 2.6.0, 2.7.0, 2.8.0, 2.9.0, 2.10.0, 2.10.1, 2.11.0
12-
- API Connectivity Manager 1.4.0, 1.5.0, 1.6.0
11+
- NGINX Instance Manager 2.4.0, 2.5.0, 2.5.1, 2.6.0, 2.7.0, 2.8.0, 2.9.0, 2.10.0, 2.10.1, 2.11.0, 2.12.0
12+
- API Connectivity Manager 1.4.0, 1.5.0, 1.6.0, 1.7.0, 1.8.0
1313
- NGINX App Protect WAF 4.100.1+
1414

1515
## Prerequisites

0 commit comments

Comments
 (0)