commit ec896051ac426f611e18932a60c39c62ee0b964e Author: Andrea Zucchelli Date: Wed Nov 13 23:49:55 2024 +0100 first diff --git a/.gitea/workflows/build-container.yaml b/.gitea/workflows/build-container.yaml new file mode 100644 index 0000000..cdce546 --- /dev/null +++ b/.gitea/workflows/build-container.yaml @@ -0,0 +1,60 @@ +name: Create and publish a Docker image + +on: + push: + branches: ['main','test'] + release: + types: [published] +env: + REGISTRY: git.zukka.net + IMAGE_NAME: ${{ gitea.repository }} + +jobs: + build-and-push-image: + runs-on: x86-64 + permissions: + contents: read + packages: write + + steps: + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Checkout repository + uses: actions/checkout@v3 + + + + - name: Log in to the Container registry + uses: docker/login-action@v3 + with: + registry: ${{ env.REGISTRY }} + username: ${{ gitea.repository_owner }} + password: ${{ secrets.PAT }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + #uses: docker/metadata-action@v4 + uses: https://github.com/docker/metadata-action@v4 + with: + images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} + tags: | + type=ref,event=branch + type=ref,event=pr + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} + type=raw,value=latest,enable={{is_default_branch}} + + - name: Build and push Docker image + uses: docker/build-push-action@v4 + with: + context: . + platforms: linux/amd64,linux/arm64 + #platforms: linux/amd64 + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file diff --git a/.gitea/workflows/demo.yaml b/.gitea/workflows/demo.yaml new file mode 100644 index 0000000..9d28383 --- /dev/null +++ b/.gitea/workflows/demo.yaml @@ -0,0 +1,19 @@ +name: Gitea Actions Demo +run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀 +on: [push] + +jobs: + Explore-Gitea-Actions: + runs-on: x86-64 + steps: + - run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event." + - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!" + - run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}." + - name: Check out repository code + uses: actions/checkout@v3 + - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." + - run: echo "🖥️ The workflow is now ready to test your code on the runner." + - name: List files in the repository + run: | + ls ${{ gitea.workspace }} + - run: echo "🍏 This job's status is ${{ job.status }}." \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..39685c0 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,3 @@ +FROM docker.io/alpine + +CMD ["echo","bao"] diff --git a/README.md b/README.md new file mode 100644 index 0000000..f70c458 --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +Per il runner: vediamo se va...