Skip to content

Commit

Permalink
compose: Add letsencryt compose
Browse files Browse the repository at this point in the history
  • Loading branch information
yongjhih committed Apr 6, 2016
1 parent 99830fa commit 859d4f6
Show file tree
Hide file tree
Showing 2 changed files with 120 additions and 5 deletions.
120 changes: 120 additions & 0 deletions docker-compose-le.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
parse-server:
#build: .
image: yongjhih/parse-server
ports:
- "1337:1337"
- "2022:22"
environment:
DATABASE_URI: $DATABASE_URI
APP_ID: $APP_ID
MASTER_KEY: $MASTER_KEY
PARSE_MOUNT: $PARSE_MOUNT # /parse
COLLECTION_PREFIX: $COLLECTION_PREFIX
CLIENT_KEY: $CLIENT_KEY
REST_API_KEY: $REST_API_KEY
DOTNET_KEY: $DOTNET_KEY
JAVASCRIPT_KEY: $JAVASCRIPT_KEY
DOTNET_KEY: $DOTNET_KEY
FILE_KEY: $FILE_KEY
FACEBOOK_APP_IDS: $FACEBOOK_APP_IDS
SERVER_URL: $SERVER_URL
MAX_UPLOAD_SIZE: $MAX_UPLOAD_SIZE # 20mb
GCM_ID: $GCM_ID
GCM_KEY: $GCM_KEY
PRODUCTION_PFX: $PRODUCTION_PFX
PRODUCTION_BUNDLE_ID: $PRODUCTION_BUNDLE_ID
PRODUCTION_CERT: $PRODUCTION_CERT # prodCert.pem
PRODUCTION_KEY: $PRODUCTION_KEY # prodKey.pem
DEV_PFX: $DEV_PFX
DEV_BUNDLE_ID: $DEV_BUNDLE_ID
DEV_CERT: $DEV_CERT # devCert.pem
DEV_KEY: $DEV_KEY # devKey.pem
VERIFY_USER_EMAILS: $VERIFY_USER_EMAILS # false
ENABLE_ANON_USERS: $ENABLE_ANON_USERS # true
ALLOW_CLIENT_CLASS_CREATION: $ALLOW_CLIENT_CLASS_CREATION # true
APP_NAME: $APP_NAME
PUBLIC_SERVER_URL: $PUBLIC_SERVER_URL
TRUST_PROXY: $TRUST_PROXY
links:
- mongo
volumes_from:
- parse-cloud-code
parse-cloud-code:
#build: cloud/.
image: yongjhih/parse-cloud-code
volumes:
- /parse/cloud
command: "ls /parse/cloud"
mongo:
image: mongo
ports:
- "27017:27017"
volumes_from:
- mongo-data
# command: "--smallfiles --logpath=/dev/null --setParameter failIndexKeyTooLong=false --rest --auth"
command: "--smallfiles --logpath=/dev/null --setParameter failIndexKeyTooLong=false"
# ref. http://www.diogogmt.com/running-mongodb-with-docker-and-compose/
mongo-data:
image: mongo
volumes:
- /data/db
command: "--break-mongo"

parse-dashboard:
image: yongjhih/parse-dashboard
links:
- parse-server
environment:
PARSE_SERVER_URL: $PARSE_SERVER_URL
PARSE_APP_ID: $PARSE_APP_ID
PARSE_MASTER_KEY: $PARSE_MASTER_KEY
PARSE_JS_KEY: $PARSE_JS_KEY
PARSE_REST_KEY: $PARSE_REST_KEY
PARSE_APP_NAME: $PARSE_APP_NAME
SERVER_URL: $SERVER_URL
APP_ID: $APP_ID
MASTER_KEY: $MASTER_KEY
APP_NAME: $APP_NAME
PARSE_DASHBOARD_ALLOW_INSECURE_HTTP: $PARSE_DASHBOARD_ALLOW_INSECURE_HTTP
USER1: $USER1
USER1_PASSWORD: $USER1_PASSWORD
VIRTUAL_HOST: $VIRTUAL_HOST
LETSENCRYPT_HOST: $LETSENCRYPT_HOST
LETSENCRYPT_EMAIL: $LETSENCRYPT_EMAIL
ports:
- "4040:4040"
# volumes:
# - "parse-dashboard-config.json:/src/Parse-Dashboard/parse-dashboard-config.json"

nginx:
image: nginx
container_name: nginx
ports:
- "80:80"
- "443:443"
volumes:
- "/etc/nginx/conf.d"
- "/etc/nginx/vhost.d"
- "/usr/share/nginx/html"
- "./volumes/proxy/certs:/etc/nginx/certs:ro"
nginx-gen:
image: jwilder/docker-gen
container_name: nginx-gen
volumes:
- "/var/run/docker.sock:/tmp/docker.sock:ro"
- "./volumes/proxy/templates/nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl:ro"
volumes_from:
- nginx
entrypoint: /usr/local/bin/docker-gen -notify-sighup nginx -watch -only-exposed -wait 5s:30s /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
letsencrypt-nginx-proxy-companion:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: letsencrypt-nginx-proxy-companion
volumes_from:
- nginx
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "./volumes/proxy/certs:/etc/nginx/certs:rw"
environment:
- NGINX_DOCKER_GEN_CONTAINER=nginx-gen

# vim:set et ts=2 sw=2:
5 changes: 0 additions & 5 deletions volumes/examples/simple-site/conf.d/site.example.com.conf

This file was deleted.

0 comments on commit 859d4f6

Please sign in to comment.