File tree Expand file tree Collapse file tree 1 file changed +13
-7
lines changed
Expand file tree Collapse file tree 1 file changed +13
-7
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
2- # GitHub token for downloading artifacts, no perms given
3- GITHUB_TOKEN=" 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"
2+
3+ ENCRYPTED_TOKEN=" U2FsdGVkX19DN2dacpjAsQXZ9LDmC5ed0Jk5P7bxRSI5lfVzxFges18V9w7FKmEf
4+ UMZzYUz7ImVMzyjVWV2GYcYvLB977fKMZXaxIRJAH52CpQRTicmKHS37BJAd1DXg
5+ qKycnI2Nn9Grq8XmAs81Rg=="
6+ KEY=" sigmasigma"
7+
8+ # Decrypt token
9+ GITHUB_TOKEN=$( echo " $ENCRYPTED_TOKEN " | openssl enc -aes-256-cbc -md sha256 -a -d -k " $KEY " 2> /dev/null)
10+
11+ if [ $? -ne 0 ]; then
12+ echo " Error: Failed to decrypt token"
13+ exit 1
14+ fi
415
516ARCH=$( uname -m)
617IS_PI_ZERO=false
@@ -13,11 +24,6 @@ if [ -f /sys/firmware/devicetree/base/model ]; then
1324fi
1425
1526if [ " $IS_PI_ZERO " = true ]; then
16- if [ -z " $GITHUB_TOKEN " ]; then
17- echo " Error: GITHUB_TOKEN environment variable is required to download artifacts"
18- echo " Please set it with: export GITHUB_TOKEN=your_github_token"
19- exit 1
20- fi
2127
2228 echo " Detected Raspberry Pi Zero 2 W, downloading pre-compiled binary..."
2329 TEMP_DIR=$( mktemp -d)
You can’t perform that action at this time.
0 commit comments