Skip to content

Commit 1099957

Browse files
committed
I should not expect this to fail
1 parent 8999c95 commit 1099957

File tree

2 files changed

+29
-26
lines changed

2 files changed

+29
-26
lines changed

.github/workflows/rust-release.yml

Lines changed: 28 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ env:
2424
APPLE_CERTIFICATE_PASSWORD: codex-test-password
2525
# SHA-1 fingerprint of the test certificate; codesign accepts this format.
2626
APPLE_CODESIGN_IDENTITY: 4E7E4C6F30634C3C9E308723F109FE7C83C061ED
27-
CODESIGN_TEST: true
27+
CODESIGN_DEBUG: false
2828

2929
jobs:
3030
tag-check:
@@ -75,18 +75,18 @@ jobs:
7575
target: aarch64-apple-darwin
7676
- runner: macos-14
7777
target: x86_64-apple-darwin
78-
- runner: ubuntu-24.04
79-
target: x86_64-unknown-linux-musl
80-
- runner: ubuntu-24.04
81-
target: x86_64-unknown-linux-gnu
82-
- runner: ubuntu-24.04-arm
83-
target: aarch64-unknown-linux-musl
84-
- runner: ubuntu-24.04-arm
85-
target: aarch64-unknown-linux-gnu
86-
- runner: windows-latest
87-
target: x86_64-pc-windows-msvc
88-
- runner: windows-11-arm
89-
target: aarch64-pc-windows-msvc
78+
# - runner: ubuntu-24.04
79+
# target: x86_64-unknown-linux-musl
80+
# - runner: ubuntu-24.04
81+
# target: x86_64-unknown-linux-gnu
82+
# - runner: ubuntu-24.04-arm
83+
# target: aarch64-unknown-linux-musl
84+
# - runner: ubuntu-24.04-arm
85+
# target: aarch64-unknown-linux-gnu
86+
# - runner: windows-latest
87+
# target: x86_64-pc-windows-msvc
88+
# - runner: windows-11-arm
89+
# target: aarch64-pc-windows-msvc
9090

9191
steps:
9292
- uses: actions/checkout@v5
@@ -135,31 +135,39 @@ jobs:
135135
exit 1
136136
fi
137137
138-
cert_path="${RUNNER_TEMP}/apple_signing_certificate.p12"
139-
echo "$APPLE_CERTIFICATE" | base64 -d > "$cert_path"
138+
# TODO: we will be directly using the p12 from github secrets
139+
# cert_path="${RUNNER_TEMP}/apple_signing_certificate.p12"
140+
# echo "$APPLE_CERTIFICATE" | base64 -d > "$cert_path"
140141
141142
keychain_path="${RUNNER_TEMP}/codex-signing.keychain-db"
142143
security create-keychain -p "$KEYCHAIN_PASSWORD" "$keychain_path"
143144
security set-keychain-settings -lut 21600 "$keychain_path"
144145
security unlock-keychain -p "$KEYCHAIN_PASSWORD" "$keychain_path"
145146
146147
keychain_args=()
148+
147149
while IFS= read -r keychain; do
148150
[[ -n "$keychain" ]] && keychain_args+=("$keychain")
149151
done < <(security list-keychains | sed 's/^[[:space:]]*//;s/[[:space:]]*$//;s/"//g')
152+
150153
if ((${#keychain_args[@]} > 0)); then
151154
security list-keychains -s "$keychain_path" "${keychain_args[@]}"
152155
else
153156
security list-keychains -s "$keychain_path"
154157
fi
158+
155159
security default-keychain -s "$keychain_path"
156160
security import "$cert_path" -k "$keychain_path" -P "$APPLE_CERTIFICATE_PASSWORD" -T /usr/bin/codesign -T /usr/bin/security
157161
security set-key-partition-list -S apple-tool:,apple: -s -k "$KEYCHAIN_PASSWORD" "$keychain_path"
158162
159-
echo "::group::Imported signing identities"
160-
security find-identity -v -p codesigning "$keychain_path" || true
161-
security find-certificate -a -Z "$keychain_path" || true
162-
echo "::endgroup::"
163+
if [[ "${CODESIGN_DEBUG:-}" == "true" ]]; then
164+
echo "::group::Imported signing identities"
165+
# TODO: we will need to grab the identity from this and then use it in the next step
166+
# TODO: WE DEFINITELY NEED TO GET RID OF THOSE
167+
security find-identity -v -p codesigning "$keychain_path" || true
168+
security find-certificate -a -Z "$keychain_path" || true
169+
echo "::endgroup::"
170+
fi
163171
164172
rm -f "$cert_path"
165173
@@ -187,12 +195,7 @@ jobs:
187195
188196
for binary in codex codex-responses-api-proxy; do
189197
path="target/${{ matrix.target }}/release/${binary}"
190-
if [[ "${CODESIGN_TEST:-}" == "true" ]]; then
191-
echo "Ad-hoc signing $path (test mode)"
192-
codesign --force --sign - "$path"
193-
else
194-
codesign --force --options runtime --timestamp --sign "$APPLE_CODESIGN_IDENTITY" "${keychain_args[@]}" "$path"
195-
fi
198+
codesign --force --options runtime --timestamp --sign "$APPLE_CODESIGN_IDENTITY" "${keychain_args[@]}" "$path"
196199
codesign --verify --deep --strict "$path"
197200
done
198201

codex-rs/Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)