paths:
- '.github/workflows/ci.yml'
- 'src/**/**'
- - '.gitmodules'
- 'build.cake'
pull_request:
paths:
- '.github/workflows/ci.yml'
- 'src/**/**'
- - '.gitmodules'
- 'build.cake'
jobs:
steps:
- name: Checkout
- uses: actions/checkout@v3
- with:
- submodules: true
+ uses: actions/checkout@v4
- uses: actions/cache@v3
with:
- name: Push NuGet package
if: github.ref_type == 'tag'
run: |
- dotnet nuget push ./build/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_IMPOSTOR }}
\ No newline at end of file
+ dotnet nuget push ./build/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_IMPOSTOR }}
paths:
- 'src/Impostor.Server/**'
- 'src/Impostor.Shared/**'
- - '.gitmodules'
- '.github/workflows/docker.yml'
- 'Dockerfile'
tags:
paths:
- 'src/Impostor.Server/**'
- 'src/Impostor.Shared/**'
- - '.gitmodules'
- '.github/workflows/docker.yml'
- 'Dockerfile'
runs-on: ubuntu-latest
steps:
- name: Checkout
- uses: actions/checkout@v2
- with:
- submodules: true
+ uses: actions/checkout@v4
- name: Prepare
id: prep
run: |
if [[ $VERSION =~ ^v[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then
TAGS="$TAGS,${DOCKER_IMAGE}:latest"
fi
- echo ::set-output name=version::${VERSION}
- echo ::set-output name=tags::${TAGS}
- echo ::set-output name=versionsuffix::${VERSIONSUFFIX}
- echo ::set-output name=created::$(date -u +'%Y-%m-%dT%H:%M:%SZ')
+ echo name=version::${VERSION} >> $GITHUB_OUTPUT
+ echo name=tags::${TAGS} >> $GITHUB_OUTPUT
+ echo name=versionsuffix::${VERSIONSUFFIX} >> $GITHUB_OUTPUT
+ echo name=created::$(date -u +'%Y-%m-%dT%H:%M:%SZ') >> $GITHUB_OUTPUT
- name: Set up QEMU
- uses: docker/setup-qemu-action@v1
+ uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
- uses: docker/setup-buildx-action@v1
+ uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
if: github.event_name != 'pull_request'
uses: docker/login-action@v1
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
- uses: docker/build-push-action@v2
+ uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile