- Change SSL to only be enabled via an environment variable. Nginx will be terminating SSL for the ER.

- Add the missing dependencies to the requirements.txt
- Change the builder ports to non-standard locations
- Add the /b1/socket and /b1/controller endpoints in nginx, to map to the build manager
- Have the build manager start automatically.
This commit is contained in:
Joseph Schorr 2014-11-25 18:08:18 -05:00
parent 04fc6d82a5
commit 9d675b51ed
9 changed files with 45 additions and 6 deletions

View file

@ -23,3 +23,11 @@ upstream verbs_app_server {
upstream registry_app_server {
server unix:/tmp/gunicorn_registry.sock fail_timeout=0;
}
upstream build_manager_controller_server {
server localhost:8686;
}
upstream build_manager_websocket_server {
server localhost:8787;
}

2
conf/init/buildmanager/log/run Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/buildmanager/

8
conf/init/buildmanager/run Executable file
View file

@ -0,0 +1,8 @@
#! /bin/bash
echo 'Starting internal build manager'
cd /
venv/bin/python -m buildman.builder 2>&1
echo 'Internal build manager exited'

View file

@ -24,7 +24,7 @@ location / {
location /realtime {
proxy_pass http://web_app_server;
proxy_buffering off;
proxy_request_buffering off;
proxy_request_buffering off;
}
location /v1/ {
@ -59,4 +59,16 @@ location /v1/_ping {
add_header X-Docker-Registry-Version 0.6.0;
add_header X-Docker-Registry-Standalone 0;
return 200 'true';
}
location ~ ^/b1/controller(/?)(.*) {
proxy_pass http://build_manager_controller_server/$2;
proxy_read_timeout 2000;
}
location ~ ^/b1/socket(/?)(.*) {
proxy_pass http://build_manager_websocket_server/$2;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}