Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix dev:oidc npm script #1036

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,4 @@ npm-debug.log*
!/.nginx/.gitkeep

/.eslintcache
/public/client-config.json
4 changes: 2 additions & 2 deletions Procfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
vue: vue-cli-service build --mode development --watch
nginx: nginx -c "$PWD/main.nginx.conf" -p "$PWD" -e stderr
vue: echo "{\"oidcEnabled\":${VUE_APP_OIDC_ENABLED-false}}" >./public/client-config.json && vue-cli-service build --mode development --watch
nginx: docker run --rm --network=host -v $PWD/nginx-conf:/etc/nginx/:ro -v $PWD/dist:/odk-central-frontend/dist nginx
File renamed without changes.
17 changes: 6 additions & 11 deletions main.nginx.conf → nginx-conf/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
# This configuration file is for development only. For production, see
# https://github.com/getodk/central.

daemon off;
pid ./.nginx/nginx.pid;
error_log /dev/stdout;
pid /tmp/nginx.pid;

events {
}
http {
access_log ./.nginx/nginx-access.log;
client_body_temp_path ./.nginx/client_body_temp;
proxy_temp_path ./.nginx/proxy_temp 1 2;
access_log /dev/stdout;
client_body_temp_path /tmp/client_body_temp;
proxy_temp_path /tmp/proxy_temp 1 2;

types {
text/html html htm shtml;
Expand Down Expand Up @@ -94,13 +94,8 @@ http {
proxy_set_header X-Forwarded-Proto https;
}

location = /client-config.json {
include ./common-headers.nginx.conf;
return 200 "{}";
}

location / {
root ./dist;
root /odk-central-frontend/dist;

include ./common-headers.nginx.conf;
# We return this header for more files in development than we do in
Expand Down