git.delta.rocks / unique-network / refs/commits / 4972f3780184

difftreelog

Additional log collection on docker build failure has been added.

Alexander Aksenov2022-08-12parent: #9ce5f25.patch.diff
in: master

1 file changed

modified.github/workflows/forkless-update-nodata.ymldiffbeforeafterboth
114 - name: Build the stack114 - name: Build the stack
115 run: docker-compose -f ".docker/docker-compose-forkless.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --force-recreate --timeout 300115 run: docker-compose -f ".docker/docker-compose-forkless.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --force-recreate --timeout 300
116
117 - name: Collect Docker Logs
118 if: failure()
119 uses: jwalton/gh-docker-logs@v2.2.0
120 with:
121 dest: './forkless-parachain-update-nodata-logs.${{ matrix.features }}'
116122
117123
118 - name: Check if docker logs consist logs related to Runtime Upgrade testing.124 - name: Check if docker logs consist logs related to Runtime Upgrade testing.
119 if: success()125 if: success()
120 run: |126 run: |
121 counter=160127 counter=160
122 function do_docker_logs {128 function do_docker_logs {
123 docker logs --details node-parachain 2>&1129 docker logs --details node-parachain 2>&1
124 }130 }
125 function is_started {131 function is_started {
126 echo "Check Docker logs"132 echo "Check Docker logs"
127 DOCKER_LOGS=$(do_docker_logs)133 DOCKER_LOGS=$(do_docker_logs)
128 if [[ ${DOCKER_LOGS} = *"RUNTIME UPGRADE TESTING"* ]];then134 if [[ ${DOCKER_LOGS} = *"RUNTIME UPGRADE TESTING"* ]];then
129 echo "Function is_started: Return 0"135 echo "Function is_started: Return 0"
130 return 0136 return 0
131 fi137 fi
132 echo "Function is_started: Return 1"138 echo "Function is_started: Return 1"
133 return 1139 return 1
134 }140 }
135 while ! is_started; do141 while ! is_started; do
136 echo "Waiting for "RUNTIME UPGRADE TESTING" in container logs"142 echo "Waiting for "RUNTIME UPGRADE TESTING" in container logs"
137 sleep 30s143 sleep 30s
138 counter=$(( $counter - 1 ))144 counter=$(( $counter - 1 ))
139 echo "Counter: $counter"145 echo "Counter: $counter"
140 if [ "$counter" -gt "0" ]; then146 if [ "$counter" -gt "0" ]; then
141 continue147 continue
142 else148 else
143 break149 break
144 fi150 fi
145 done151 done
146 echo "Test completed."152 echo "Test completed."
147 exit 1153 exit 0
148 shell: bash154 shell: bash
149155
150 - name: Collect Docker Logs156 - name: Collect Docker Logs