forked from tendermint/tm-db
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from notional-labs/update-goleveldb
new badgerdb and goleveldb
- Loading branch information
Showing
5 changed files
with
80 additions
and
121 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,56 +1,42 @@ | ||
# This workflow builds and pushes a new version of the build container image | ||
# when the tools directory changes on master. Edit tools/Dockerfile. | ||
# | ||
# This workflow does not push a new image until it is merged, so tests that | ||
# depend on changes in this image will not pass until this workflow succeeds. | ||
# For that reason, changes here should be done in a separate PR in advance of | ||
# work that depends on them. | ||
name: Build & Push | ||
# Build & Push rebuilds the iavl docker image on every push to master and creation of tags | ||
# and pushes the image to https://ghcr.io/osmosis-labs/iavl | ||
|
||
name: Build & Push TM-DB-Testing | ||
on: | ||
pull_request: | ||
paths: | ||
- "tools/*" | ||
push: | ||
branches: | ||
- master | ||
paths: | ||
- "tools/*" | ||
tags: | ||
- "v[0-9]+.[0-9]+.[0-9]+" # Push events to matching v*, i.e. v1.0, v20.15.10 | ||
- "v[0-9]+.[0-9]+.[0-9]+-rc*" # Push events to matching v*, i.e. v1.0-rc1, v20.15.10-rc5 | ||
|
||
jobs: | ||
build: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Prepare | ||
id: prep | ||
run: | | ||
DOCKER_IMAGE=tendermintdev/docker-tm-db-testing | ||
VERSION=noop | ||
if [[ $GITHUB_REF == refs/tags/* ]]; then | ||
VERSION=${GITHUB_REF#refs/tags/} | ||
elif [[ $GITHUB_REF == refs/heads/* ]]; then | ||
VERSION=$(echo ${GITHUB_REF#refs/heads/} | sed -r 's#/+#-#g') | ||
if [ "${{ github.event.repository.default_branch }}" = "$VERSION" ]; then | ||
VERSION=latest | ||
fi | ||
fi | ||
TAGS="${DOCKER_IMAGE}:${VERSION}" | ||
echo ::set-output name=tags::${TAGS} | ||
- name: Set up Docker Buildx | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v2 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v1 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v1 | ||
|
||
- name: Login to DockerHub | ||
uses: docker/login-action@v1 | ||
- | ||
name: Login to GitHub Container Registry | ||
uses: docker/login-action@v1 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
- name: Publish to Docker Hub | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- | ||
name: Build and push | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: ./tools | ||
file: ./tools/Dockerfile | ||
push: ${{ github.event_name != 'pull_request' }} | ||
tags: ${{ steps.prep.outputs.tags }} | ||
context: . | ||
file: tools/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: ghcr.io/${{ github.repository_owner }}/tm-db:latest |
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
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
Oops, something went wrong.