build #325
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: | |
- master | |
schedule: | |
- cron: '0 8 * * 1' | |
jobs: | |
latest: | |
runs-on: ubuntu-latest | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v3 | |
- | |
name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- | |
name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- | |
name: Get date (YYYY.MM.dd) | |
id: fullDate | |
run: echo "fullDate=$(date +'%Y.%m.%d')" >> $GITHUB_OUTPUT | |
- | |
name: Get date (YYYY.MM) | |
id: yearMonthDate | |
run: echo "yearMonthDate=$(date +'%Y.%m')" >> $GITHUB_OUTPUT | |
- | |
name: Get date (YYYY) | |
id: yearDate | |
run: echo "yearDate=$(date +'%Y')" >> $GITHUB_OUTPUT | |
- | |
name: Dockerhub login | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- | |
name: Build | |
run: | | |
docker buildx build \ | |
--pull \ | |
--push \ | |
--platform linux/amd64,linux/arm64 \ | |
--tag mondedie/rutorrent:latest \ | |
--tag mondedie/rutorrent:${{ steps.fullDate.outputs.fullDate }} \ | |
--tag mondedie/rutorrent:${{ steps.yearMonthDate.outputs.yearMonthDate }} \ | |
--tag mondedie/rutorrent:${{ steps.yearDate.outputs.yearDate }} . | |
filebot: | |
runs-on: ubuntu-latest | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v3 | |
- | |
name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- | |
name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- | |
name: Get date (YYYY.MM.dd) | |
id: fullDate | |
run: echo "fullDate=$(date +'%Y.%m.%d')" >> $GITHUB_OUTPUT | |
- | |
name: Get date (YYYY.MM) | |
id: yearMonthDate | |
run: echo "yearMonthDate=$(date +'%Y.%m')" >> $GITHUB_OUTPUT | |
- | |
name: Get date (YYYY) | |
id: yearDate | |
run: echo "yearDate=$(date +'%Y')" >> $GITHUB_OUTPUT | |
- | |
name: Dockerhub login | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- | |
name: Build | |
run: | | |
docker buildx build \ | |
--pull \ | |
--push \ | |
--build-arg FILEBOT=true \ | |
--platform linux/amd64,linux/arm64 \ | |
--tag mondedie/rutorrent:filebot \ | |
--tag mondedie/rutorrent:filebot-${{ steps.fullDate.outputs.fullDate }} \ | |
--tag mondedie/rutorrent:filebot-${{ steps.yearMonthDate.outputs.yearMonthDate }} \ | |
--tag mondedie/rutorrent:filebot-${{ steps.yearDate.outputs.yearDate }} . |