Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #
- echo
- echo
- echo "Starting up services fxa.localhorst.home"
- echo
- docker run --detach --rm --name httpdb \
- --env "HOST=0.0.0.0" \
- --env "MYSQL_PASSWORD=xxxxxxxx" \
- --env "MYSQL_SLAVE_PASSWORD=xxxxxxxx" \
- --env "MYSQL_HOST=172.17.0.1" \
- --env "MYSQL_SLAVE_HOST=172.17.0.1" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-auth-db-mysql:latest
- docker run --detach --rm --name verifier \
- --env "IP_ADDRESS=0.0.0.0" \
- --env "PORT=5050" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-browserid-verifier:latest
- docker run --detach --rm --name profile \
- --publish 1112:1112 \
- --publish 1113:1113 \
- --env "PUBLIC_URL=https://fxa.localhorst.home:1111" \
- --env "AUTH_SERVER_URL=https://fxa.localhorst.home:9000/v1" \
- --env "OAUTH_SERVER_URL=https://fxa.localhorst.home:9010/v1" \
- --env "DB=mysql" \
- --env "MYSQL_HOST=172.17.0.1" \
- --env "MYSQL_PASSWORD=xxxxxxxx" \
- --env "REDIS_HOST=172.17.0.1" \
- --env "IMG=local" \
- --env "HOST=0.0.0.0" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-profile-server:latest
- docker run --detach --rm --name content \
- --env "PUBLIC_URL=https://fxa.localhorst.home:3030" \
- --env "FXA_OAUTH_URL=https://fxa.localhorst.home:9010" \
- --env "FXA_PROFILE_URL=https://fxa.localhorst.home:1111" \
- --env "SYNC_TOKENSERVER_URL=https://fxa.localhorst.home:5000/token" \
- --env "FXA_URL=https://fxa.localhorst.home:9000" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --env "GEODB_ENABLED=false" \
- --env "CSP_ENABLED=false" \
- --env "REDIRECT_PORT=3031" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-content-server:latest
- echo
- echo "Sleeping 5 sec. to let services come up before linking"
- echo
- sleep 5
- docker run --detach --rm --name sync \
- --env "SYNCSERVER_PUBLIC_URL=https://fxa.localhorst.home:5000" \
- --env "SYNCSERVER_SECRET=xxxxxxxxxxxxxxxxxxxxxxxxxxx" \
- --env "SYNCSERVER_SQLURI=pymysql://xxxxxxxx:xxxxxxxx@172.17.0.1/fxa_sync" \
- --env "SYNCSERVER_IDENTITY_PROVIDER=https://fxa.localhorst.home:3030" \
- --env "SYNCSERVER_BROWSERID_VERIFIER=https://fxa.localhorst.home:5050/v2" \
- --env "SYNCSERVER_BATCH_UPLOAD_ENABLED=true" \
- --env "SYNCSERVER_ALLOW_NEW_USERS=true" \
- --env "SYNCSERVER_FORCE_WSGI_ENVIRON=true" \
- --env "REQUESTS_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt" \
- fxa-syncserver:latest
- docker run --detach --rm --name auth \
- --env "IP_ADDRESS=0.0.0.0" \
- --env "REDIS_HOST=172.17.0.1" \
- --env "GEODB_ENABLED=false" \
- --env "SMTP_HOST=mxxxxxxxxx" \
- --env "SMTP_USER=xxxxxxxxxxxx" \
- --env "SMTP_PORT=465" \
- --env "SMTP_SECURE=true" \
- --env "SMTP_PASS=xxxxxxxxxxxxx" \
- --env "SMTP_SENDER=Firefox Accounts Server <xxxxxxxxxxx>" \
- --env "PUBLIC_URL=https://fxa.localhorst.home:9000" \
- --env "HTTPDB_URL=https://fxa.localhorst.home:8000" \
- --env "CONTENT_SERVER_URL=https://fxa.localhorst.home:3030" \
- --env "OAUTH_URL=https://fxa.localhorst.home:9010" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-auth-server:latest
- docker run --detach --rm --name oauth \
- --env "GEODB_ENABLED=false" \
- --env "HOST=0.0.0.0" \
- --env "PUBLIC_URL=https://fxa.localhorst.home:9010" \
- --env "CONTENT_URL=https://fxa.localhorst.home:3030/oauth" \
- --env "VERIFICATION_URL=https://fxa.localhorst.home:5050/v2" \
- --env "ISSUER=fxa.localhorst.home:9000" \
- --env "DB=mysql" \
- --env "MYSQL_HOST=172.17.0.1" \
- --env "MYSQL_PASSWORD=xxxxxxxx" \
- --env "NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/hsp_root_cert.crt" \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- --entrypoint npm \
- fxa-oauth-server:latest run start-oauth
- echo
- echo "Sleeping 5 sec. to let services come up before linking"
- echo
- sleep 5
- echo
- echo Setting up proxy
- docker run --detach --rm --name proxy \
- --link="profile" \
- --link="content" \
- --link="sync" \
- --link="verifier" \
- --link="httpdb" \
- --link="auth" \
- --link="oauth" \
- --publish 1111:1111 \
- --publish 3030:3030 \
- --publish 5000:5000 \
- --publish 5050:5050 \
- --publish 8000:8000 \
- --publish 9000:9000 \
- --publish 9010:9010 \
- --add-host="fxa.localhorst.home:192.168.0.2" \
- fxa-self-hosting:latest
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement