Skip to content

Commit

Permalink
docker/pipeline changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan-g committed Aug 14, 2024
1 parent 52cc809 commit 4d3612e
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 2 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,7 @@ jobs:
- name: Prepare Stack File
run: >
ENVIRONMENT=${{ env.PRODUCTION }} DOMAIN=${{ env.PRODUCTION_DOMAIN }} CONTAINER_IMAGE=${IMAGE_ID} STACK_NAME=${{ env.PRODUCTION_STACK_NAME }}
docker compose -f ${{ env.DOCKER_STACK_PATH }} config | sed '/^name:*/d' > ${{ env.STACK_FILE }}
docker compose -f ${{ env.DOCKER_STACK_PATH }} config | sed 's/^name:.*/version: "3.9"/' > ${{ env.STACK_FILE }}
- name: Move Stack File to Server
uses: appleboy/[email protected]
Expand Down
2 changes: 2 additions & 0 deletions docker-compose.production.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
version: '3.9'

services:
api:
image: ${CONTAINER_IMAGE:-backend}
Expand Down
64 changes: 64 additions & 0 deletions huh.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: nest-server
services:
api:
build:
context: /home/g/Documents/Code/SAY/2.0.0/nest-server
dockerfile: Dockerfile
command:
- npm
- run
- start:dev
container_name: api_say_nest
depends_on:
say_nest_db:
condition: service_started
required: true
environment:
NODE_ENV: production
PORT: "8002"
networks:
default: null
ports:
- mode: ingress
target: 8002
published: "5000"
protocol: tcp
- mode: ingress
target: 9229
published: "9229"
protocol: tcp
volumes:
- type: bind
source: /home/g/Documents/Code/SAY/2.0.0/nest-server
target: /usr/src/app
bind:
create_host_path: true
say_nest_db:
command:
- postgres
- -c
- listen_addresses=*
container_name: postgresql_say_nest
environment:
PORT: "5432"
POSTGRES_DB: say_nest
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
image: postgres:10.4
networks:
default: null
ports:
- mode: ingress
target: 5432
published: "35000"
protocol: tcp
restart: always
volumes:
- type: bind
source: /home/g/Documents/Code/SAY/2.0.0/nest-server/data/postgres
target: /var/lib/postgresql/data
bind:
create_host_path: true
networks:
default:
name: nest-server_default

0 comments on commit 4d3612e

Please sign in to comment.