diff --git a/compose/docker-compose.yml b/compose/docker-compose.yml index 586b21d..3cf97f4 100755 --- a/compose/docker-compose.yml +++ b/compose/docker-compose.yml @@ -1,20 +1,3 @@ -web: - build: . - command: node index-db.js - ports: - - "3000:3000" - links: - - db - environment: - MYSQL_DATABASE: myapp - MYSQL_USER: myapp - MYSQL_PASSWORD: mysecurepass - MYSQL_HOST: db -db: - image: orchardup/mysql - ports: - - "3306:3306" - environment: - MYSQL_DATABASE: myapp - MYSQL_USER: myapp - MYSQL_PASSWORD: mysecurepass +services: + web: + image: nginx:latest diff --git a/compose/proxy/nginx.conf b/compose/proxy/nginx.conf index 77e44d1..00a0594 100644 --- a/compose/proxy/nginx.conf +++ b/compose/proxy/nginx.conf @@ -2,9 +2,9 @@ events {} http{ upstream backend{ - server web:80; - server web_2:80; - server web_3:80; + server proxy-web-1:80; + server proxy-web-2:80; + server proxy-web-3:80; } server{ @@ -13,4 +13,4 @@ http{ proxy_pass http://backend; } } -} \ No newline at end of file +} diff --git a/compose/proxy/proxy.yml b/compose/proxy/proxy.yml index ae26954..3d53a93 100644 --- a/compose/proxy/proxy.yml +++ b/compose/proxy/proxy.yml @@ -1,9 +1,7 @@ services: web: image: nginx:alpine - volumes: - - ./web:/usr/share/nginx/html:ro - + proxy: image: nginx:alpine ports: @@ -11,4 +9,4 @@ services: volumes: - ./nginx.conf:/etc/nginx/nginx.conf:ro depends_on: - - web \ No newline at end of file + - web