docker update
This commit is contained in:
@ -1,26 +1,54 @@
|
|||||||
version: '3.1'
|
version: '3.8'
|
||||||
|
|
||||||
services:
|
services:
|
||||||
cmc-new-backend:
|
backend:
|
||||||
|
build: backend
|
||||||
|
restart: always
|
||||||
|
environment:
|
||||||
|
MYSQL_HOST: db
|
||||||
|
MYSQL_USER: support_portal_user
|
||||||
|
MYSQL_PASSWORD: support_portal_password
|
||||||
|
MYSQL_DATABASE: support-portal
|
||||||
|
networks:
|
||||||
|
- angular-spring
|
||||||
|
- spring-mysql
|
||||||
|
depends_on:
|
||||||
|
db:
|
||||||
|
condition: service_healthy
|
||||||
|
|
||||||
|
db:
|
||||||
|
image: mysql:8.0.19
|
||||||
|
environment:
|
||||||
|
MYSQL_USER: support_portal_user
|
||||||
|
MYSQL_PASSWORD: support_portal_password
|
||||||
|
MYSQL_DATABASE: support-portal
|
||||||
|
MYSQL_ROOT_PASSWORD: root_password # required for MySQL root access
|
||||||
|
restart: always
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD", "mysqladmin", "ping", "-h", "127.0.0.1", "--silent"]
|
||||||
|
interval: 3s
|
||||||
|
retries: 5
|
||||||
|
start_period: 30s
|
||||||
|
volumes:
|
||||||
|
- db-data:/var/lib/mysql
|
||||||
|
networks:
|
||||||
|
- spring-mysql
|
||||||
|
|
||||||
|
frontend:
|
||||||
build:
|
build:
|
||||||
context: ./support-portal-backend
|
context: support-portal-frontend
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
restart: always
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
- "8070:8080"
|
- "8072:80"
|
||||||
environment:
|
|
||||||
- DATABASE_HOST=mysql-common-mysql-1
|
|
||||||
- SPRING_DATASOURCE_URL=jdbc:mysql://mysql-common-mysql-1:3306/demo
|
|
||||||
- SPRING_DATASOURCE_USERNAME=youruser
|
|
||||||
- SPRING_DATASOURCE_PASSWORD=youruserpassword
|
|
||||||
networks:
|
networks:
|
||||||
- cmc-forntend
|
- angular-spring
|
||||||
- mysql-common_mynetwork
|
depends_on:
|
||||||
|
- backend
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
db-data: {}
|
db-data: {}
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
cmc-forntend: {}
|
angular-spring: {}
|
||||||
mysql-common_mynetwork:
|
spring-mysql: {}
|
||||||
external: true
|
|
||||||
|
|||||||
@ -14,10 +14,6 @@ FROM nginx:1.17.1-alpine
|
|||||||
# COPY nginx.conf /etc/nginx/nginx.conf
|
# COPY nginx.conf /etc/nginx/nginx.conf
|
||||||
COPY --from=build /usr/src/app/dist/support-portal-frontend /usr/share/nginx/html
|
COPY --from=build /usr/src/app/dist/support-portal-frontend /usr/share/nginx/html
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Expose port 80 to the Docker host, so we can access it
|
# Expose port 80 to the Docker host, so we can access it
|
||||||
# from the outside.
|
# from the outside.
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|||||||
@ -3,6 +3,6 @@ export const environment = {
|
|||||||
// apiUrl: 'http://support-portal.shyshkin.net:5000',
|
// apiUrl: 'http://support-portal.shyshkin.net:5000',
|
||||||
// apiUrl: 'http://dockerapp.shyshkin.net:8080',
|
// apiUrl: 'http://dockerapp.shyshkin.net:8080',
|
||||||
// apiUrl: 'https://dockerapp.shyshkin.net',
|
// apiUrl: 'https://dockerapp.shyshkin.net',
|
||||||
apiUrl: 'https://cncbackend.techzoos.in',
|
apiUrl: 'https://cmcbackend.rootxwire.com',
|
||||||
publicUrls: ['/user/login', '/user/register', '/user/*/profile-image', '/user/*/profile-image/**']
|
publicUrls: ['/user/login', '/user/register', '/user/*/profile-image', '/user/*/profile-image/**']
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user