feat: add config-url support with Dockerfile and NGINX configuration

Signed-off-by: d9pouces <github@19pouces.net>
This commit is contained in:
d9pouces
2026-09-07 07:15:58 +02:00
parent 88380b6ab6
commit 9de98d4744
5 changed files with 81 additions and 1 deletions
@@ -0,0 +1,14 @@
# Static id-configurator configuration served by the config-url-repo fixture,
# to be downloaded (not copied in locally) via `id-configurator apply
# --config-url ... --config-url-cacert-content ...`
# (tests/dockerfiles/ConfigUrl.Dockerfile). No per-run templating is needed:
# unlike the module-* fixtures, nothing in this document needs to reference
# its own server's dynamic host:port.
uuid: 8f3e4b2c-9a41-4d3e-8f1a-2b6c7d8e9f01
organisation: InterDiode
description: Configuration downloaded via --config-url
configurations:
certificates:
- name: config-url-marker
content: |
test-only certificate fetched via --config-url by the id-configurator integration tests
@@ -0,0 +1,13 @@
# Serves a static id-configurator configuration document over TLS, using the
# same Test CA as the other *-repo fixtures, used by tox-docker to exercise
# `id-configurator apply --config-url ... --config-url-cacert-content ...`
# (tests/dockerfiles/ConfigUrl.Dockerfile).
#
# Built by tox-docker, whose build context is this directory (not the repo
# root) - every COPY source below must live under tests/dockerfiles/repos/.
FROM nginx:alpine
COPY config-url-config.yaml /srv/config.yaml
COPY repo-server.crt.pem /etc/nginx/certs/repo-server.crt.pem
COPY repo-server.key.pem /etc/nginx/certs/repo-server.key.pem
COPY config-url-repo.nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 8443
@@ -0,0 +1,10 @@
server {
listen 8443 ssl default_server;
server_name _;
ssl_certificate /etc/nginx/certs/repo-server.crt.pem;
ssl_certificate_key /etc/nginx/certs/repo-server.key.pem;
root /srv;
autoindex off;
}