Created
January 9, 2022 21:38
-
-
Save mkusiciel/e70edd509081947d42007868c01b6f01 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| services: | |
| angular_web: | |
| build: angular/angular | |
| volumes: | |
| - ./angular/angular:/project | |
| - /project/node_modules | |
| apache_php_web: | |
| build: apache-php/app | |
| volumes: | |
| - ./apache-php/app:/var/www/html/ | |
| aspnet_mssql_web: | |
| build: aspnet-mssql/app/aspnetapp | |
| aspnet_mssql_db: | |
| environment: | |
| ACCEPT_EULA: "Y" | |
| SA_PASSWORD: example_123 | |
| # mssql server image isn't available for arm64 architecture, so we use azure-sql instead | |
| image: mcr.microsoft.com/azure-sql-edge:1.0.4 | |
| # If you really want to use MS SQL Server, uncomment the following line | |
| #image: mcr.microsoft.com/mssql/server | |
| restart: always | |
| healthcheck: | |
| test: ["CMD-SHELL", "/opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P example_123 -Q 'SELECT 1' || exit 1"] | |
| interval: 10s | |
| retries: 10 | |
| start_period: 10s | |
| timeout: 3s | |
| django_web: | |
| build: django/app | |
| elasticsearch: | |
| image: elasticsearch:7.16.1 | |
| environment: | |
| discovery.type: single-node | |
| ES_JAVA_OPTS: "-Xms512m -Xmx512m" | |
| healthcheck: | |
| test: ["CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1"] | |
| interval: 10s | |
| timeout: 10s | |
| retries: 3 | |
| networks: | |
| - elastic | |
| logstash: | |
| image: logstash:7.16.1 | |
| environment: | |
| discovery.seed_hosts: logstash | |
| LS_JAVA_OPTS: "-Xms512m -Xmx512m" | |
| volumes: | |
| - ./elasticsearch-logstash-kibana/logstash/pipeline/logstash-nginx.config:/usr/share/logstash/pipeline/logstash-nginx.config | |
| - ./elasticsearch-logstash-kibana/logstash/nginx.log:/home/nginx.log | |
| depends_on: | |
| - elasticsearch | |
| networks: | |
| - elastic | |
| command: logstash -f /usr/share/logstash/pipeline/logstash-nginx.config | |
| kibana: | |
| image: kibana:7.16.1 | |
| depends_on: | |
| - elasticsearch | |
| networks: | |
| - elastic | |
| minecraft: | |
| image: itzg/minecraft-server | |
| environment: | |
| EULA: "TRUE" | |
| deploy: | |
| resources: | |
| limits: | |
| memory: 1.5G | |
| volumes: | |
| - "~/minecraft_data:/data" | |
| react_backend: | |
| build: | |
| args: | |
| - NODE_ENV=development | |
| context: react-express-mysql/backend | |
| command: npm run start-watch | |
| environment: | |
| - DATABASE_DB=example | |
| - DATABASE_USER=root | |
| - DATABASE_PASSWORD=/run/secrets/db-password | |
| - DATABASE_HOST=db | |
| - NODE_ENV=development | |
| secrets: | |
| - db-password | |
| volumes: | |
| - ./react-express-mysql/backend/src:/code/src:ro | |
| - ./react-express-mysql/backend/package.json:/code/package.json | |
| - ./react-express-mysql/backend/package-lock.json:/code/package-lock.json | |
| networks: | |
| - public | |
| - private | |
| depends_on: | |
| - react_db | |
| react_db: | |
| # We use a mariadb image which supports both amd64 & arm64 architecture | |
| image: mariadb:10.6.4-focal | |
| # If you really want to use MySQL, uncomment the following line | |
| #image: mysql:8.0.27 | |
| command: '--default-authentication-plugin=mysql_native_password' | |
| restart: always | |
| secrets: | |
| - db-password | |
| networks: | |
| - private | |
| environment: | |
| - MYSQL_DATABASE=example | |
| - MYSQL_ROOT_PASSWORD_FILE=/run/secrets/db-password | |
| react_frontend: | |
| build: | |
| context: react-express-mysql/frontend | |
| target: development | |
| volumes: | |
| - ./react-express-mysql/frontend/src:/code/src | |
| - /code/node_modules | |
| networks: | |
| - public | |
| depends_on: | |
| - react_backend | |
| spring_backend: | |
| build: spring-postgres/backend | |
| environment: | |
| - POSTGRES_DB=example | |
| networks: | |
| - spring-postgres | |
| spring_db: | |
| image: postgres | |
| restart: always | |
| secrets: | |
| - spring-db-password | |
| networks: | |
| - spring-postgres | |
| environment: | |
| - POSTGRES_DB=example | |
| - POSTGRES_PASSWORD_FILE=/run/secrets/spring-db-password | |
| vuejs_web: | |
| build: vuejs/vuejs | |
| volumes: | |
| - ./vuejs/vuejs:/project | |
| - /project/node_modules | |
| secrets: | |
| db-password: | |
| file: react-express-mysql/db/password.txt | |
| spring-db-password: | |
| file: spring-postgres/db/password.txt | |
| networks: | |
| public: | |
| private: | |
| spring-postgres: | |
| elastic: | |
| driver: bridge | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment