Skip to content

Commit

Permalink
Merge pull request #269 from blackcandy-org/dev
Browse files Browse the repository at this point in the history
Fix #266, push to multi-registries in GitHub Actions
  • Loading branch information
aidewoode committed Mar 27, 2023
2 parents ab152cd + fed5970 commit 91c1ad7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
15 changes: 10 additions & 5 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,25 +41,30 @@ jobs:
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Set Docker Tag
run: |
echo "DOCKER_TAG=ghcr.io/blackcandy-org/blackcandy:latest,blackcandy/blackcandy:${{ env.VERSION }}" >> $GITHUB_ENV
echo "DOCKER_TAG=blackcandy/blackcandy:latest,blackcandy/blackcandy:${{ env.VERSION }},ghcr.io/blackcandy-org/blackcandy:latest,ghcr.io/blackcandy-org/blackcandy:${{ env.VERSION }}" >> $GITHUB_ENV
- name: Remove Latest Docker Tag
if: contains(github.ref_name, 'beta')
run: |
echo "DOCKER_TAG=ghcr.io/blackcandy-org/blackcandy:${{ env.VERSION }}" >> $GITHUB_ENV
echo "DOCKER_TAG=blackcandy/blackcandy:${{ env.VERSION }},ghcr.io/blackcandy-org/blackcandy:${{ env.VERSION }}" >> $GITHUB_ENV
- name: Set Edge Docker Tag
if: github.ref_name == 'master'
run: |
touch .is-edge-release.txt
echo "DOCKER_TAG=ghcr.io/blackcandy-org/blackcandy:edge" >> $GITHUB_ENV
echo "DOCKER_TAG=blackcandy/blackcandy:edge,ghcr.io/blackcandy-org/blackcandy:edge" >> $GITHUB_ENV
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Login to GHCR
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ There are two parts of data need to persist in Black Candy. First it's the data

```shell
touch production.sqlite3
mkdir uploads_data

docker run -v ./production.sqlite3:/app/db/production.sqlite3 -v ./uploads_data:/app/public/uploads ghcr.io/blackcandy-org/blackcandy:edge
```
Expand Down

0 comments on commit 91c1ad7

Please sign in to comment.