From af02a2397bbb5522091072c1e951e61308cb60d7 Mon Sep 17 00:00:00 2001 From: Andrew Clayton Date: Thu, 17 Oct 2024 21:38:44 +0100 Subject: [PATCH] cidbg --- .github/workflows/ci.yml | 11 ++++++----- src/nxt_isolation.c | 3 +++ test/python/ns_inspect/wsgi.py | 4 ++++ 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 03209406d..b8d99389b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -266,7 +266,8 @@ jobs: - name: Configure python3 run: | - sudo ./configure python --config=python3-config + sudo ./configure python --config=${Python_ROOT_DIR}/bin/python3-config --lib-path=$LD_LIBRARY_PATH + cat build/include/nxt_python3_mounts.h if: steps.metadata.outputs.module == 'python' - name: Make python3 @@ -351,10 +352,10 @@ jobs: namei -l ${{ github.workspace }} # Install python3 if not present - - uses: actions/setup-python@v5 - with: - python-version: '3' - if: steps.metadata.outputs.module != 'wasm' +# - uses: actions/setup-python@v5 +# with: +# python-version: '3' +# if: steps.metadata.outputs.module != 'wasm' - name: Install pytest run: | diff --git a/src/nxt_isolation.c b/src/nxt_isolation.c index 909a43f4b..194d7be3f 100644 --- a/src/nxt_isolation.c +++ b/src/nxt_isolation.c @@ -790,6 +790,9 @@ nxt_isolation_prepare_rootfs(nxt_task_t *task, nxt_process_t *process) if (nxt_slow_path(ret != NXT_OK)) { goto undo; } + + printf("%s: mounted [%s] -> [%s]\n", __func__, + (const char *)mnt[i].src, (const char *)dst); } return NXT_OK; diff --git a/test/python/ns_inspect/wsgi.py b/test/python/ns_inspect/wsgi.py index fa1222e4f..a07b7e822 100644 --- a/test/python/ns_inspect/wsgi.py +++ b/test/python/ns_inspect/wsgi.py @@ -1,5 +1,6 @@ import json import os +import sys try: # Python 3 @@ -10,6 +11,9 @@ def application(environ, start_response): + print("pwd:", os.getcwd()) + print("sys.path:\n", sys.path, file=sys.stdout) + ret = { 'FileExists': False, }