From aefe5fb2a469d420aa28984cfc7dab56e9fc194a Mon Sep 17 00:00:00 2001 From: Philipp Spinnler Date: Wed, 18 Sep 2024 16:45:17 +0200 Subject: [PATCH] added workflow --- .github/workflows/docker-image.yml | 33 ++++++++++++++++++++++++++++++ .gitignore | 1 + 2 files changed, 34 insertions(+) create mode 100644 .github/workflows/docker-image.yml create mode 100644 .gitignore diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml new file mode 100644 index 0000000..6480b79 --- /dev/null +++ b/.github/workflows/docker-image.yml @@ -0,0 +1,33 @@ +name: CI - Build and Push Docker Image + +on: + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Build and push Docker image + uses: docker/build-push-action@v5 + with: + context: . + push: true + tags: ${{ secrets.DOCKER_USERNAME }}/dashboard-ui:latest diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e43b0f9 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.DS_Store