From cb3644590778643d15a2cdbfa017290d40c7c068 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Paul=20Li=C3=A9tar?= Date: Wed, 9 Oct 2024 15:55:14 +0100 Subject: [PATCH] Build docker image in CI (#1) --- .github/workflows/docker.yaml | 40 +++++++++++++++++++++++++++++++++++ inst/static/index.html | 2 -- web/public/index.html | 14 ++---------- 3 files changed, 42 insertions(+), 14 deletions(-) create mode 100644 .github/workflows/docker.yaml delete mode 100644 inst/static/index.html diff --git a/.github/workflows/docker.yaml b/.github/workflows/docker.yaml new file mode 100644 index 0000000..498b861 --- /dev/null +++ b/.github/workflows/docker.yaml @@ -0,0 +1,40 @@ +name: Build Docker Image + +on: + push: + branches: [main, master] + pull_request: + branches: [main, master] + +jobs: + docker: + runs-on: ubuntu-latest + steps: + - name: Docker meta + id: meta + uses: docker/metadata-action@v5 + with: + images: | + mrcide/rrq.dashboard + tags: | + type=raw,value=latest,enable={{is_default_branch}} + type=ref,event=branch + type=sha,prefix= + + - uses: actions/checkout@v4 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Build and push containers + uses: docker/build-push-action@v5 + with: + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} diff --git a/inst/static/index.html b/inst/static/index.html deleted file mode 100644 index 90531a4..0000000 --- a/inst/static/index.html +++ /dev/null @@ -1,2 +0,0 @@ - - diff --git a/web/public/index.html b/web/public/index.html index aa069f2..ff28084 100644 --- a/web/public/index.html +++ b/web/public/index.html @@ -2,19 +2,9 @@ - - - - - - - React App + rrq dashboard