Skip to content

Commit 4745ac3

Browse files
authored
Remove NGINX_PATH_MODULES and NGINX_CONFIG_PATH (#57)
* Remove NGINX_PATH_MODULES and NGINX_CONFIG_PATH The removal of `NGINXMODULES_PATH` and `NGINX_CONF_PATH` has the advantage of facilitating the execution of our tests, optimizing the utilization of matrix jobs on CircleCI, and streamlining the development workflow. * Update all tests *.conf with the module absolute path. * Update default nginx.conf. * Run nginx on a specific configuration.
1 parent d444238 commit 4745ac3

File tree

103 files changed

+1495
-2836
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+1495
-2836
lines changed

.circleci/config.yml

Lines changed: 965 additions & 2465 deletions
Large diffs are not rendered by default.

bin/generate_jobs_yaml.sh

Lines changed: 117 additions & 220 deletions
Large diffs are not rendered by default.

nginx-version-info.example

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,6 @@
2828
# BASE_IMAGE is not required for the "build" make target, but is required
2929
# for "test", "build-in-docker", and "lab" targets.
3030
#
31-
# NGINX_MODULES_PATH
32-
# This variable is used during testing. It's the path to the nginx modules
33-
# directory in the nginx installation available within $BASE_IMAGE.
34-
#
35-
# NGINX_MODULES_PATH is not required for the "build" or "build-in-docker"
36-
# make targets, but is required for the "test" and "lab" targets.
37-
#
3831
# ARCH
3932
# The docker image architecture to use. The following values are supported:
4033
#
@@ -46,13 +39,10 @@
4639

4740
NGINX_VERSION=1.24.0
4841
BASE_IMAGE=nginx:1.24.0-alpine
49-
NGINX_MODULES_PATH=/usr/lib/nginx/modules
5042
ARCH=amd64
5143

5244
# NGINX_VERSION=1.14.1
5345
# BASE_IMAGE=nginx:1.14.1
54-
# NGINX_MODULES_PATH=/usr/lib/nginx/modules
5546

5647
# NGINX_VERSION=1.22.1
5748
# BASE_IMAGE=amazonlinux:2.0.20230119.1
58-
# NGINX_MODULES_PATH=/usr/share/nginx/modules

test/bin/run

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,10 @@ set -e
66

77
. ../nginx-version-info
88
export BASE_IMAGE
9-
export NGINX_MODULES_PATH="${NGINX_MODULES_PATH:-/usr/lib/nginx/modules}"
10-
export NGINX_CONF_PATH="${NGINX_CONF_PATH:-/etc/nginx/nginx.conf}"
119

12-
printf "===============================\n"
13-
printf "Running test with:\n"
14-
printf " - ARCH=%s\n" "${ARCH}"
15-
printf " - BASE_IMAGE=%s\n" "${BASE_IMAGE}"
16-
printf " - NGINX_CONF_PATH=%s\n" "${NGINX_CONF_PATH}"
17-
printf " - NGINX_MODULES_PATH=%s\n" "${NGINX_MODULES_PATH}"
18-
printf "===============================\n"
10+
printf " arch : %s\n" "${ARCH}"
11+
printf "base image : %s\n" "${BASE_IMAGE}"
12+
printf " test args : %s\n" "$@"
1913

2014
docker compose build --parallel
2115
python3 -m unittest "$@"

test/cases/access_log/conf/default_format.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
error_log stderr info;
47

test/cases/access_log/conf/json_format.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
error_log stderr info;
47

test/cases/access_log/conf/without_tracing.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
error_log stderr info;
47

test/cases/auto_propagation/conf/fastcgi_auto.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/fastcgi_disabled_at_http.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/fastcgi_disabled_at_location.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/fastcgi_disabled_at_server.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/grpc_auto.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/grpc_disabled_at_http.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/grpc_disabled_at_location.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/grpc_disabled_at_server.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/http_auto.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/http_disabled_at_http.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/http_disabled_at_location.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/http_disabled_at_server.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/uwsgi_auto.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/uwsgi_disabled_at_http.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/uwsgi_disabled_at_location.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/auto_propagation/conf/uwsgi_disabled_at_server.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/duplicate/agent_url.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/duplicate/environment.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/duplicate/propagation_styles.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/duplicate/service_name.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_main/agent_url.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_main/environment.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_main/propagation_styles.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_main/service_name.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_server/agent_url.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_server/environment.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_server/propagation_styles.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/error_in_server/service_name.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/in_http.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/propagation_styles.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/propagation_styles_error.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

test/cases/configuration/conf/vanilla.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
load_module modules/ngx_http_datadog_module.so;
1+
# "/datadog-tests" is a directory created by the docker build
2+
# of the nginx test image. It contains the module, the
3+
# nginx config, and "index.html".
4+
load_module /datadog-tests/ngx_http_datadog_module.so;
25

36
events {
47
worker_connections 1024;

0 commit comments

Comments
 (0)