diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml deleted file mode 100644 index 7174a9fa..00000000 --- a/.gitea/workflows/deploy.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: Deploy - -on: - push: - tags: - - "v*" - -env: - REGISTRY: git.bga.sh - DOCKER_BUILDKIT: 1 - VERSION: ${{ github.ref_name }} - -jobs: - deploy: - name: Build & Deploy - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Login to Gitea Registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ secrets.REGISTRY_USER }} - password: ${{ secrets.RELEASE_TOKEN }} - - - name: Build and push Docker image - run: | - LATEST="${{ env.REGISTRY }}/${{ github.repository_owner }}/vat-api.eu:latest" - docker build -t "$LATEST" . - docker push "$LATEST" - - - name: Trigger deployment - run: | - echo "TODO: Add webhook URL" - # curl -X POST "" diff --git a/.gitea/workflows/tag.yml b/.gitea/workflows/tag.yml deleted file mode 100644 index 4ff764ef..00000000 --- a/.gitea/workflows/tag.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Publish - -on: - push: - branches: - - main - -env: - -jobs: - trigger_tag: - name: Trigger Tag Function - runs-on: ubuntu-latest - if: github.ref == 'refs/heads/main' - steps: - - name: Checkout code - uses: actions/checkout@v4 - with: - token: ${{ secrets.RELEASE_TOKEN }} - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: "18" - - - name: Install dependencies - run: | - apt install -y git - npm install --frozen-lockfile --ignore-scripts --workspaces=false - - - name: Publish Package - env: - GITEA_TOKEN: ${{ secrets.RELEASE_TOKEN }} - GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }} - GIT_AUTHOR_NAME: "CI Bot" - GIT_AUTHOR_EMAIL: "ci@git.bga.sh" - GIT_COMMITTER_NAME: "CI Bot" - GIT_COMMITTER_EMAIL: "ci@git.bga.sh" - run: npm run publish diff --git a/build-and-push.sh b/build-and-push.sh new file mode 100755 index 00000000..ac355589 --- /dev/null +++ b/build-and-push.sh @@ -0,0 +1,2 @@ +docker build -t git.bga.sh/bennetgallein/vat-api.eu:latest . +docker push git.bga.sh/bennetgallein/vat-api.eu:latest