Skip to content

Commit

Permalink
fix: have update readme run after version calculation in deploy and r…
Browse files Browse the repository at this point in the history
…elease (#586)

Signed-off-by: Jeromy Cannon <jeromy@swirldslabs.com>
  • Loading branch information
jeromy-cannon committed Sep 17, 2024
1 parent ae1c949 commit 42e1685
Show file tree
Hide file tree
Showing 3 changed files with 128 additions and 189 deletions.
25 changes: 13 additions & 12 deletions .github/workflows/flow-deploy-release-artifact.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,9 @@ permissions:
id-token: write

jobs:
update-readme:
name: "Update README.md"
uses: ./.github/workflows/flow-update-readme.yaml
with:
commit-changes: true
secrets:
GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
GH_ACCESS_GPG_KEY: ${{ secrets.GH_ACCESS_GPG_KEY }}
GH_ACCESS_PASSPHRASE: ${{ secrets.GH_ACCESS_PASSPHRASE }}

prepare-release:
name: Release / Prepare
runs-on: solo-linux-medium
needs: update-readme
outputs:
version: ${{ steps.tag.outputs.version }}
steps:
Expand Down Expand Up @@ -92,11 +81,23 @@ jobs:
[[ "${{ github.event.inputs.dry-run-enabled }}" == true && ! -f VERSION ]] && echo -n "0.0.0-latest" > VERSION
echo "version=$(cat VERSION | tr -d '[:space:]')" >> ${GITHUB_OUTPUT}
update-readme:
name: "Update README.md"
uses: ./.github/workflows/flow-update-readme.yaml
needs: prepare-release
with:
commit-changes: true
secrets:
GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
GH_ACCESS_GPG_KEY: ${{ secrets.GH_ACCESS_GPG_KEY }}
GH_ACCESS_PASSPHRASE: ${{ secrets.GH_ACCESS_PASSPHRASE }}


create-github-release:
name: Github / Release
runs-on: solo-linux-medium
needs:
- prepare-release
- update-readme
steps:
- name: Checkout Code
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
Expand Down
11 changes: 3 additions & 8 deletions .github/workflows/flow-update-readme.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ jobs:
export SOLO_INIT_OUTPUT=$( solo init -i node1,node2,node3 -n "${SOLO_NAMESPACE}" -s \
"${SOLO_CLUSTER_SETUP_NAMESPACE}" | tee test.log )
export SOLO_NODE_KEYS_OUTPUT=$( solo node keys --gossip-keys --tls-keys | tee test.log )
export SOLO_NODE_KEY_PEM_OUTPUT=$( solo node keys --gossip-keys --tls-keys | tee test.log )
export SOLO_CLUSTER_SETUP_OUTPUT=$( solo cluster setup | tee test.log )
Expand All @@ -130,17 +130,12 @@ jobs:
export SOLO_RELAY_DEPLAY_OUTPUT=$( solo relay deploy -i node1,node2 | tee test.log )
export SOLO_INIT_047_OUTPUT=$( solo init -i node1,node2,node3 -n "${SOLO_NAMESPACE}" \
-s "${SOLO_CLUSTER_SETUP_NAMESPACE}" --key-format pem | tee test.log )
export SOLO_NODE_KEY_PEM_OUTPUT=$( solo node keys --gossip-keys --tls-keys --key-format pem | tee test.log )
export SOLO_RELAY_DEPLOY_OUTPUT=$( solo relay deploy | tee test.log )
echo "Generate README.md"
envsubst '$KIND_CREATE_CLUSTER_OUTPUT,$SOLO_INIT_OUTPUT,$SOLO_NODE_KEYS_OUTPUT, $SOLO_CLUSTER_SETUP_OUTPUT, \
envsubst '$KIND_CREATE_CLUSTER_OUTPUT,$SOLO_INIT_OUTPUT,$SOLO_NODE_KEY_PEM_OUTPUT,$SOLO_CLUSTER_SETUP_OUTPUT, \
$SOLO_NETWORK_DEPLOY_OUTPUT,$SOLO_NODE_SETUP_OUTPUT,$SOLO_NODE_START_OUTPUT,$SOLO_MIRROR_NODE_DEPLOY_OUTPUT,\
$SOLO_RELAY_DEPLAY_OUTPUT,$SOLO_INIT_047_OUTPUT,$SOLO_NODE_KEY_PEM_OUTPUT,$SOLO_RELAY_DEPLOY_OUTPUT'\
$SOLO_RELAY_DEPLAY_OUTPUT,$SOLO_RELAY_DEPLOY_OUTPUT'\
< README.md.template > README.md
echo "Remove color codes and lines showing intermediate progress"
Expand Down
Loading

0 comments on commit 42e1685

Please sign in to comment.