Skip to content

Commit

Permalink
docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Addy832 committed Nov 13, 2023
1 parent df29d66 commit f1bd29b
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Docker Image CI

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Build the Docker image
run: docker-compose -f docker-compose.yml build

- name: Docker Push
run: docker-compose push nextjs
13 changes: 13 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,22 @@ version: "3"
services:
nextjs:
build: ./
container_name: well_pharmacy
image: a7medabdo6/well_pharmacy
ports:
- 3000:3000
# nginx:
# build: ./nginx
# ports:
# - 80:80
watchtower:
image: containrrr/watchtower
restart: always
environment:
# WATCHTOWER_SCHEDULE: "0 0 1 * * *"
TZ: America/Chicago
WATCHTOWER_CLEANUP: "true"
WATCHTOWER_DEBUG: "true"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
command: --interval 60 well_pharmacy well_pharmacy

0 comments on commit f1bd29b

Please sign in to comment.