Skip to content

[feature] #3953: Transfer Domain ownership #1

[feature] #3953: Transfer Domain ownership

[feature] #3953: Transfer Domain ownership #1

name: I2::Release::Publish
on:
push:
branches: [iroha2-stable, iroha2-lts]
env:
CARGO_TERM_COLOR: always
jobs:
registry:
runs-on: ubuntu-latest
container:
image: hyperledger/iroha2-ci:nightly-2023-06-25
steps:
- uses: actions/checkout@v3
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
with:
install: true
- name: Get tag from branch name
run: |
BRANCH=${{ github.ref_name }}
PREFIX='iroha2-'
TAG=${BRANCH#$PREFIX}
echo "TAG=$TAG" >>$GITHUB_ENV
- name: Get the release from a branch name
run: |
RELEASE=$(curl -s https://raw.githubusercontent.com/hyperledger/iroha/${{ github.ref_name }}/Cargo.toml | sed -n '3p' | sed -e 's/version = "//g' -e 's/"$//' | tr -d '\n')
echo "RELEASE=$RELEASE" >>$GITHUB_ENV
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to Soramitsu Harbor
uses: docker/login-action@v2
with:
registry: docker.soramitsu.co.jp
username: ${{ secrets.HARBOR_USERNAME }}
password: ${{ secrets.HARBOR_TOKEN }}
- name: Build and push iroha2 image
uses: docker/build-push-action@v4
with:
push: true
tags: |
hyperledger/iroha2:${{ env.TAG }}-${{ env.RELEASE }}
docker.soramitsu.co.jp/iroha2/iroha2:${{ env.TAG }}-${{ env.RELEASE }}
labels: commit=${{ github.sha }}
build-args: TAG=${{ env.TAG }}
file: Dockerfile
# This context specification is required
context: .
cache-from: type=gha
cache-to: type=gha,mode=max
configs:
runs-on: ubuntu-latest
container:
image: hyperledger/iroha2-ci:nightly-2023-06-25
steps:
- uses: actions/checkout@v3
with:
ref: iroha2-dev
- name: Setup git config
run: |
cd .git
git config --local user.name "sorabot"
git config --local user.email "<>"
- name: Update configs
run: |
./scripts/update_configs.sh lts
./scripts/update_configs.sh stable
- name: Commit config changes
run: |
git config --global --add safe.directory /__w/iroha/iroha
git add -A
git diff-index --quiet HEAD || git commit -m "[documentation]: Update lts/stable configs following a release" --signoff
git push origin iroha2-dev