@@ -105,23 +105,51 @@ on GitHub (beyond the sources automatically provided there). Instead we add
105
105
a Downloads section that notes the exact tags and digests that the images can
106
106
be found at on quay.io.
107
107
108
- Use the following partial snippet as an example:
109
- ```
110
- Images built for this release can be obtained from the quay.io image registry.
111
-
112
- ### samba-server
113
- * By tag: quay.io/samba.org/samba-server:v0.3
114
- * By digest: quay.io/samba.org/samba-server@sha256:09c867343af39b237230f94a734eacc8313f2330c7d934994522ced46b740715
115
- ### samba-ad-server
116
- * By tag: quay.io/samba.org/samba-ad-server:v0.3
117
- * By digest: quay.io/samba.org/samba-ad-server@sha256:a1d901f44be2af5a516b21e45dbd6ebd2f64500dfbce112886cdce09a5c3cbd5
108
+ The downloads section can be generated using the following shell script:
109
+ ``` bash
110
+ #! /usr/bin/env bash
111
+ # Requires `skopeo` and `jq` to be installed.
112
+
113
+ set -e
114
+
115
+ sk_digest () {
116
+ skopeo inspect " docker://${1} " | jq -r .Digest
117
+ }
118
+
119
+ image_info () {
120
+ curr_img=" quay.io/samba.org/${1} :${2} "
121
+ digest=$( sk_digest " ${curr_img} " )
122
+ # strip preN from tag name
123
+ final_tag=" $( echo " $2 " | sed ' s,pre[0-9]*$,,' ) "
124
+ tag_img=" quay.io/samba.org/${1} :${final_tag} "
125
+ dst_img=" quay.io/samba.org/${1} @${digest} "
126
+
127
+ echo " ### $1 "
128
+ echo " * By tag: $tag_img "
129
+ echo " * By digest: $dst_img "
130
+ echo " "
131
+ }
132
+
133
+ wip_tag=$1
134
+ if [ -z " ${wip_tag} " ] ; then
135
+ echo " No tag provided!" >&2
136
+ exit 1
137
+ fi
138
+
139
+ echo " ## Downloads"
140
+ echo " "
141
+ echo " Images built for this release can be acquired from the quay.io image registry."
142
+ echo " "
143
+ for component in samba-server samba-ad-server samba-client samba-toolbox; do
144
+ image_info " ${component} " " ${wip_tag} "
145
+ done
118
146
```
119
- ... and so on for each image that was pushed earlier
120
147
121
- The tag is pretty obvious - it should match the image tag (minus any pre-release
122
- marker). You can get the digest from the tag using the quay.io UI (do not use
123
- any local digest hashes). Click on the SHA256 link and then copy the full
124
- manifest hash using the UI widget that appears.
148
+ It is important that the digest is fetched from qauy.io after it has been
149
+ pushed. Do not use any local digest hashes. You may want to double check the
150
+ values produced by the script with those in the quay.io UI. Click on the
151
+ SHA256 link and then compare the full manifest hash using the UI widget that
152
+ appears.
125
153
126
154
Perform a final round of reviews, as needed, for the release notes and then
127
155
publish the release.
0 commit comments