Skip to content

Commit d229010

Browse files
soulbirdsoulbird
andauthored
chore: change env var to DEB_xxx (#224)
* chore: change env var to DEB_xxx Co-authored-by: soulbird <[email protected]>
1 parent 93dd736 commit d229010

File tree

3 files changed

+9
-8
lines changed

3 files changed

+9
-8
lines changed

.circleci/config.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,9 @@ jobs:
153153
mkdir -p "${VAR_DEB_WORKBENCH_DIR}"
154154
sudo apt-get update
155155
sudo apt install -y gpg ca-certificates
156-
RPM_GPG_PRIV_KEY=$(echo $RPM_GPG_PRIV_KEY_BASE64 | base64 -d)
157-
echo "${RPM_GPG_PRIV_KEY}" >> /tmp/deb-gpg-publish.private
158-
echo "${RPM_GPG_PASSPHRASE}" >> /tmp/deb-gpg-publish.passphrase
156+
DEB_GPG_PRIV_KEY=$(echo $DEB_GPG_PRIV_KEY_BASE64 | base64 -d)
157+
echo "${DEB_GPG_PRIV_KEY}" >> /tmp/deb-gpg-publish.private
158+
echo "${DEB_GPG_PASSPHRASE}" >> /tmp/deb-gpg-publish.passphrase
159159
./utils/publish-deb.sh init_cos_utils
160160
sudo -E ./utils/publish-deb.sh init_freight_utils
161161
sudo -E ./utils/publish-deb.sh init_gpg

.github/workflows/publish-deb.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,12 @@ jobs:
7979

8080
- name: Init publish utils
8181
env:
82-
GPG_MAIL: ${{ secrets.GPG_MAIL }}
82+
DEB_GPG_MAIL: ${{ secrets.DEB_GPG_MAIL }}
8383
TENCENT_COS_SECRETID: ${{ secrets.TENCENT_COS_SECRETID }}
8484
TENCENT_COS_SECRETKEY: ${{ secrets.TENCENT_COS_SECRETKEY }}
8585
run: |
86-
echo "${{ secrets.RPM_GPG_PRIV_KEY }}" >> /tmp/deb-gpg-publish.private
87-
echo "${{ secrets.RPM_GPG_PASSPHRASE }}" >> /tmp/deb-gpg-publish.passphrase
86+
echo "${{ secrets.DEB_GPG_PRIV_KEY }}" >> /tmp/deb-gpg-publish.private
87+
echo "${{ secrets.DEB_GPG_PASSPHRASE }}" >> /tmp/deb-gpg-publish.passphrase
8888
./utils/publish-deb.sh init_cos_utils
8989
sudo -E ./utils/publish-deb.sh init_freight_utils
9090
sudo -E ./utils/publish-deb.sh init_gpg

utils/publish-deb.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ func_gpg_key_load() {
2828
gpg --import --pinentry-mode loopback \
2929
--batch --passphrase-file "${VAR_GPG_PASSPHRASE}" "${VAR_GPG_PRIV_KET}"
3030

31-
gpg --list-keys --fingerprint | grep "${GPG_MAIL}" -B 1 \
31+
gpg --list-keys --fingerprint | grep "${DEB_GPG_MAIL}" -B 1 \
3232
| tr -d ' ' | head -1 | awk 'BEGIN { FS = "\n" } ; { print $1":6:" }' \
3333
| gpg --import-ownertrust
3434

@@ -152,6 +152,7 @@ func_deb_upload() {
152152
# We will only upload apisix and apisix-base,
153153
# so the directory is fixed: pool/main/a.
154154
# Regardless of other packages.
155+
155156
export COS_CMD=$COS_CMD
156157
export arch_path=$arch_path
157158
export BUCKET=$2
@@ -192,7 +193,7 @@ init_cos_utils)
192193
;;
193194
init_freight_utils)
194195
func_freight_utils_install
195-
func_freight_utils_init ${GPG_MAIL} "/tmp/freight"
196+
func_freight_utils_init ${DEB_GPG_MAIL} "/tmp/freight"
196197
;;
197198
init_gpg)
198199
func_gpg_key_load

0 commit comments

Comments
 (0)