From 6b6bd16970f773ae8f5ecbeb20e34806d8d0c2a9 Mon Sep 17 00:00:00 2001 From: Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> Date: Sat, 3 Sep 2022 15:00:48 +0200 Subject: [PATCH] cors frontend --- nginx/nginx.conf | 13 +++++++++++++ nginx/nginx.local.conf | 10 ++++++++++ run_scripts/cors-school.sh | 1 + 3 files changed, 24 insertions(+) create mode 100644 run_scripts/cors-school.sh diff --git a/nginx/nginx.conf b/nginx/nginx.conf index b8e4361..466b7fc 100644 --- a/nginx/nginx.conf +++ b/nginx/nginx.conf @@ -29,5 +29,18 @@ http { } } + server { + listen 443 ssl; + + ssl_certificate /etc/nginx/certs/live/nilstrieb.dev/fullchain.pem; + ssl_certificate_key /etc/nginx/certs/live/nilstrieb.dev/privkey.pem; + + server_name "cors-school.nilstrieb.dev"; + + location / { + proxy_pass https://cors-school-frontend:80/; + } + } + server_tokens off; } \ No newline at end of file diff --git a/nginx/nginx.local.conf b/nginx/nginx.local.conf index b318c0a..e672944 100644 --- a/nginx/nginx.local.conf +++ b/nginx/nginx.local.conf @@ -23,5 +23,15 @@ http { } } + server { + listen 80; + + server_name "cors-school.nilstrieb.dev"; + + location / { + proxy_pass http://cors-school-frontend/; + } + } + server_tokens off; } \ No newline at end of file diff --git a/run_scripts/cors-school.sh b/run_scripts/cors-school.sh new file mode 100644 index 0000000..bf457f4 --- /dev/null +++ b/run_scripts/cors-school.sh @@ -0,0 +1 @@ +docker run --net internal --name cors-school-frontend -d --restart=always private-docker-registry.nilstrieb.dev/cors-school-frontend:1.0.0 \ No newline at end of file