diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.yml new file mode 100644 index 0000000..dff8840 --- /dev/null +++ b/.github/workflows/docker-build.yml @@ -0,0 +1,30 @@ +name: Build and Push Docker Image to GitHub Packages + +on: + push: + branches: + - main + +jobs: + build-and-push: + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - uses: actions/checkout@v2 + + - name: Log in to GitHub Container Registry + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Build and push Docker image + uses: docker/build-push-action@v2 + with: + context: . + push: true + tags: ghcr.io/${{ github.repository }}/monapp:latest diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..fd1b092 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/.idea/ +*.iml \ No newline at end of file