diff --git a/bb-stack-final.yaml b/bb-stack-final.yaml deleted file mode 100644 index dd06b99..0000000 --- a/bb-stack-final.yaml +++ /dev/null @@ -1,48 +0,0 @@ -version: '3.7' - -services: - bb-db: - image: ${dockerId}/bb-db:v3 - build: - context: ./bulletin-board-db - networks: - - bb-net - volumes: - - sqlbackup:/var/opt/mssql - - bb-app: - image: ${dockerId}/bb-app:v3.3 - build: - context: ./bulletin-board-app - dockerfile: Dockerfile.v3.3 - networks: - - bb-net - configs: - - source: logConfig - target: /app/config/logConfig.js - secrets: - - source: dbConfig - target: /app/config/dbConfig.js - - bb-proxy: - image: ${dockerId}/bb-proxy:v3 - build: - context: ./bulletin-board-proxy - ports: - - "80:80" - networks: - - bb-net - -networks: - bb-net: - -volumes: - sqlbackup: - -configs: - logConfig: - external: true - -secrets: - dbConfig: - external: true \ No newline at end of file diff --git a/bb-stack.yaml b/bb-stack.yaml index 98c92a7..56e1096 100644 --- a/bb-stack.yaml +++ b/bb-stack.yaml @@ -3,8 +3,6 @@ version: '3.7' services: bb-db: image: ${dockerId}/bb-db:v3 - build: - context: ./bulletin-board-db networks: - bb-net volumes: @@ -12,17 +10,13 @@ services: bb-app: image: ${dockerId}/bb-app:v3 - build: - context: ./bulletin-board-app networks: - bb-net bb-proxy: image: ${dockerId}/bb-proxy:v3 - build: - context: ./bulletin-board-proxy ports: - - "80:80" + - "8000:80" networks: - bb-net @@ -30,4 +24,4 @@ networks: bb-net: volumes: - sqlbackup: \ No newline at end of file + sqlbackup: diff --git a/bulletin-board-app/Dockerfile b/bulletin-board-app/Dockerfile index 22e6ce5..1b4e895 100644 --- a/bulletin-board-app/Dockerfile +++ b/bulletin-board-app/Dockerfile @@ -1,10 +1,5 @@ -FROM node:6.11.5 - +FROM node WORKDIR /usr/src/app -COPY package.json . +COPY . . RUN npm install - -EXPOSE 8080 CMD [ "npm", "start" ] - -COPY . . \ No newline at end of file diff --git a/bulletin-board-app/Dockerfile.v3.1 b/bulletin-board-app/Dockerfile.v3.1 deleted file mode 100644 index b2e1cf2..0000000 --- a/bulletin-board-app/Dockerfile.v3.1 +++ /dev/null @@ -1,15 +0,0 @@ -FROM node AS builder - -WORKDIR /src -COPY package.json . -RUN npm install - -# app image -FROM node - -EXPOSE 8080 -CMD npm start - -WORKDIR /app -COPY --from=builder /src/node_modules/ /app/node_modules/ -COPY . . \ No newline at end of file diff --git a/bulletin-board-app/Dockerfile.v3.2 b/bulletin-board-app/Dockerfile.v3.2 deleted file mode 100644 index 986fc43..0000000 --- a/bulletin-board-app/Dockerfile.v3.2 +++ /dev/null @@ -1,15 +0,0 @@ -FROM node AS builder - -WORKDIR /src -COPY package.json . -RUN npm install - -# app image -FROM node:alpine - -EXPOSE 8080 -CMD npm start - -WORKDIR /app -COPY --from=builder /src/node_modules/ /app/node_modules/ -COPY . . \ No newline at end of file diff --git a/bulletin-board-app/Dockerfile.v3.3 b/bulletin-board-app/Dockerfile.v3.3 deleted file mode 100644 index 03c1075..0000000 --- a/bulletin-board-app/Dockerfile.v3.3 +++ /dev/null @@ -1,19 +0,0 @@ -FROM node:10.15-stretch AS builder - -WORKDIR /src -COPY package.json . -RUN npm install - -# app image -FROM node:10.15.3-alpine - -EXPOSE 8080 -CMD [ "node", "server.js" ] - -USER node -HEALTHCHECK --interval=5s --timeout=10s --start-period=15s \ - CMD [ "node", "healthcheck.js" ] - -WORKDIR /app -COPY --from=builder /src/node_modules/ /app/node_modules/ -COPY . . \ No newline at end of file