Skip to content

Commit

Permalink
chore(apps/prod/tekton/configs/pipelines): add fake wait image delive…
Browse files Browse the repository at this point in the history
…ry task in ga release flow (#1182)

### **User description**
Signed-off-by: wuhuizuo <wuhuizuo@126.com>


___

### **PR Type**
Enhancement


___

### **Description**
- Added a new `wait-image-delivery` task in the GA release flow to check
image delivery.
- Simplified the `wait-tiup-delivery` task by removing unnecessary
parameters and installation steps.
- Updated parameter names for consistency across tasks.
- Limited pull concurrency to 1 in the `publish-tiup-from-oci-artifact`
task to reduce read failure.



___



### **Changes walkthrough** 📝
<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>pingcap-release-ga.yaml</strong><dd><code>Add image
delivery check task and simplify existing tasks</code></dd></summary>
<hr>

apps/prod/tekton/configs/pipelines/pingcap-release-ga.yaml

<li>Added a new task <code>wait-image-delivery</code> in the GA release
flow.<br> <li> Simplified the <code>wait-tiup-delivery</code> task by
removing unnecessary <br>parameters and steps.<br> <li> Updated
parameter names for consistency.<br>


</details>


  </td>
<td><a
href="https://github.com/PingCAP-QE/ee-ops/pull/1182/files#diff-af80f59d89e61819937f55f75b7f4a0d8550e37b1b92be09c0ac837d2ec9ea2c">+18/-20</a>&nbsp;
</td>

</tr>                    

<tr>
  <td>
    <details>

<summary><strong>publish-tiup-from-oci-artifact.yaml</strong><dd><code>Limit
pull concurrency in publish task</code>&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>

apps/prod/tekton/configs/tasks/publish-tiup-from-oci-artifact.yaml

- Limited pull concurrency to 1 to reduce read failure.



</details>


  </td>
<td><a
href="https://github.com/PingCAP-QE/ee-ops/pull/1182/files#diff-e25eeac4a20ccf5a8a7e272793d1fa35d11ee3b1524a79014ceda6fcad9eeac9">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>                    
</table></td></tr></tr></tbody></table>

___

> 💡 **PR-Agent usage**:
>Comment `/help` on the PR to get a list of all available PR-Agent tools
and their descriptions

---------

Signed-off-by: wuhuizuo <wuhuizuo@126.com>
  • Loading branch information
wuhuizuo authored Jul 11, 2024
1 parent e75e2c4 commit e648d98
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 21 deletions.
38 changes: 18 additions & 20 deletions apps/prod/tekton/configs/pipelines/pingcap-release-ga.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,21 +43,15 @@ spec:
# force add the tag on repos:
# ./tag-rc2ga-on-repos.sh "$rc_ver" "$ga_ver" "$registry" true
./tag-rc2ga-on-repos.sh "$rc_ver" "$ga_ver" "$registry"
- name: wait-tiup-delivery
runAfter:
- "ga-tag-oci-artifacts"
params:
- name: rc-version
value: "$(params.version)-pre"
- name: ga-version
- name: version
value: $(params.version)
taskSpec:
params:
- name: rc-version
- name: ga-version
- name: tiup-tool-version
default: "v1.14.1"
- name: version
steps:
- name: wait
image: ghcr.io/pingcap-qe/cd/utils/release:v20240325-60-gb6f8928
Expand All @@ -67,18 +61,7 @@ spec:
#! /usr/bin/env bash
set -exo pipefail
# install tiup tool.
TIUP_HOME=~/.tiup
bin_dir=$TIUP_HOME/bin
mkdir -vp "$bin_dir"
ARCH=$([ "$(arch)" = "x86_64" ] && echo amd64 || echo arm64)
download_url=https://tiup-mirrors.pingcap.com/tiup-$(params.tiup-tool-version)-linux-${ARCH}.tar.gz
wget -q -O - "$download_url" | tar -zxvf - -C "$bin_dir"
chmod 755 "$bin_dir/tiup"
export PATH=$bin_dir:$PATH
which tiup
tiup_check_ver="$(params.ga-version)"
tiup_check_ver="$(params.version)"
tiup_mirror="http://tiup.pingcap.net:8987"
oci_registry="hub.pingcap.net"
Expand All @@ -101,6 +84,21 @@ spec:
cat results.yaml || true
- name: wait-image-delivery
runAfter:
- ga-tag-oci-artifacts
params:
- name: version
value: $(params.version)
taskSpec:
params:
- name: version
steps:
- name: wait
image: ghcr.io/pingcap-qe/cd/utils/release:v20240325-60-gb6f8928
script: |
check_ver="$(params.version)"
echo "🤷 This step is not implement yet."
- name: compose-offline-pkgs-amd64-community
runAfter: [wait-tiup-delivery]
taskRef: { name: pingcap-compose-offline-pkgs }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ spec:
fi
# download the artifact
oras pull $(params.artifact-url)
oras pull --concurrency 1 $(params.artifact-url)
echo "✅ Done, the generated script content:"
cat publish.sh
Expand Down

0 comments on commit e648d98

Please sign in to comment.