Skip to content

Commit 6044796

Browse files
fix(ci): upload both GA and preview tarballs in prerelease workflow (#1386)
* fix(ci): upload both GA and preview tarballs in prerelease workflow The bundle script now produces two tarballs (GA + preview) but the prerelease workflow only uploaded the first one it found. Upload both and include install commands in the release notes. Constraint: bundle.mjs names GA as *-<timestamp>.tgz and preview as *-preview-<timestamp>.tgz Confidence: high Scope-risk: narrow * fix(test): increase dev-server integration test timeout to 60s The test starts a dev server, waits up to 20s for health check, then runs two invoke calls. On slow CI runners 30s total is insufficient. Confidence: high Scope-risk: narrow
1 parent bed1de0 commit 6044796

2 files changed

Lines changed: 24 additions & 8 deletions

File tree

.github/workflows/prerelease-tarball.yml

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,22 +43,38 @@ jobs:
4343
- name: Get tarball info
4444
id: tarball
4545
run: |
46-
TARBALL_NAME=$(ls *.tgz | head -1 | xargs basename)
47-
echo "name=$TARBALL_NAME" >> $GITHUB_OUTPUT
46+
GA_TARBALL=$(ls *-[0-9]*[0-9].tgz 2>/dev/null | grep -v preview | head -1 | xargs basename)
47+
PREVIEW_TARBALL=$(ls *preview*.tgz | head -1 | xargs basename)
48+
echo "ga_name=$GA_TARBALL" >> $GITHUB_OUTPUT
49+
echo "preview_name=$PREVIEW_TARBALL" >> $GITHUB_OUTPUT
50+
echo "GA tarball: $GA_TARBALL"
51+
echo "Preview tarball: $PREVIEW_TARBALL"
4852
- name: Create or update prerelease
4953
env:
5054
GH_TOKEN: ${{ steps.app-token.outputs.token }}
51-
TARBALL_NAME: ${{ steps.tarball.outputs.name }}
55+
GA_TARBALL: ${{ steps.tarball.outputs.ga_name }}
56+
PREVIEW_TARBALL: ${{ steps.tarball.outputs.preview_name }}
5257
run: |
5358
TAG="prerelease"
5459
55-
# Delete existing release if it exists (to update the tarball)
60+
# Delete existing release if it exists (to update the tarballs)
5661
gh release delete "$TAG" --yes --cleanup-tag 2>/dev/null || true
5762
58-
# Create a new pre-release with the tarball
63+
# Create a new pre-release with both tarballs
5964
gh release create "$TAG" \
60-
"${TARBALL_NAME}" \
65+
"${GA_TARBALL}" \
66+
"${PREVIEW_TARBALL}" \
6167
--title "Prerelease" \
62-
--notes "Auto-generated tarball from the latest commit on main." \
68+
--notes "Auto-generated tarballs from the latest commit on main.
69+
70+
**GA build** (no harness features):
71+
\`\`\`
72+
npm install -g https://github.com/aws/agentcore-cli/releases/download/prerelease/${GA_TARBALL}
73+
\`\`\`
74+
75+
**Preview build** (harness features enabled):
76+
\`\`\`
77+
npm install -g https://github.com/aws/agentcore-cli/releases/download/prerelease/${PREVIEW_TARBALL}
78+
\`\`\`" \
6379
--prerelease \
6480
--target "${{ github.sha }}"

integ-tests/dev-server.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ describe('integration: dev server', () => {
142142
devProcess.kill('SIGTERM');
143143
devProcess = null;
144144
},
145-
30000
145+
60000
146146
);
147147

148148
it.skipIf(!hasNpm || !hasGit || !hasUv)(

0 commit comments

Comments
 (0)