diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml new file mode 100644 index 0000000..f2f4678 --- /dev/null +++ b/.github/workflows/deploy.yaml @@ -0,0 +1,54 @@ +name: Build and Deploy +on: + push: + tags: + - "v*.*.*" + branches: + - master + workflow_call: + +env: + CARGO_TERM_COLOR: always + +jobs: + build: + name: Build Action Runner 🚀 + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + - name: Docker meta + id: meta + uses: docker/metadata-action@v4 + with: + images: | + ghcr.io/v3xlabs/action-runner + tags: | + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} + type=edge + type=sha + + - name: Login to GitHub Container Registry + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Build and push + id: docker_build + uses: docker/build-push-action@v3 + with: + push: true + file: Dockerfile + context: server + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + cache-from: type=registry,ref=ghcr.io/v3xlabs/action-runner:edge + cache-to: type=inline diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..6156d45 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,2 @@ +FROM ubuntu:22.04 + diff --git a/README.md b/README.md index 61b6816..1cd92ce 100644 --- a/README.md +++ b/README.md @@ -1,3 +1 @@ -# Hello World - -Never going to give you up. +# Action Runner