Skip to content

Commit

Permalink
chore: create image script
Browse files Browse the repository at this point in the history
  • Loading branch information
0xzio committed Apr 23, 2024
1 parent c45b2bf commit 249a2f1
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 5 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/create-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Build and Push Docker Image

on:
push:
branches:
- main

jobs:
build-and-push:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}

- name: Build Docker image
run: docker build -f Dockerfile -t 0xzion/penx:postgresql-latest .

- name: Add tags
run: docker tag penx:latest 0xzion/penx:postgresql-latest

- name: Push Docker image to Docker Hub
run: docker push 0xzion/penx:postgresql-latest
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ ENV DATABASE_URL=${DATABASE_URL}
ARG NEXT_PUBLIC_DEPLOY_MODE=SELF_HOSTED

RUN turbo run build --filter=@penx/db
RUN turbo build --filter=web...
RUN turbo run build --filter=web...

FROM base AS runner
WORKDIR /app
Expand Down
8 changes: 4 additions & 4 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 249a2f1

Please sign in to comment.