Skip to content

Commit

Permalink
Add esc/latest-version (#10039)
Browse files Browse the repository at this point in the history
Add a static page with the latest version number for Pulumi ESC. This will be updated by a CI/CD process to provide a source of truth for various other tooling.
  • Loading branch information
lblackstone authored Oct 10, 2023
1 parent 7e7b0f7 commit f4560a1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion scripts/sync-and-test-bucket.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ node scripts/translate-redirects.js "$build_dir" "$(pulumi -C infrastructure con
aws s3 mb $destination_bucket_uri --region "$(aws_region)" || true
# set `BlockPublicAcls` to false to enable setting the public-read ACL below.
aws s3api put-public-access-block --bucket "$destination_bucket" --public-access-block-configuration BlockPublicAcls=false
# set `ObjectOwnership=ObjectWriter`, since as of April 2023 the default has changed to `BucketOwnerEnforced` which
# set `ObjectOwnership=ObjectWriter`, since as of April 2023 the default has changed to `BucketOwnerEnforced` which
# disables bucket ACLs.
aws s3api put-bucket-ownership-controls --bucket "$destination_bucket" --ownership-controls="Rules=[{ObjectOwnership=ObjectWriter}]"
aws s3api put-bucket-acl --bucket "$destination_bucket" --acl bucket-owner-full-control
Expand Down Expand Up @@ -85,6 +85,8 @@ echo "$s3_website_url"
# Set the content-type of latest-version explicitly. (Otherwise, it'll be set as binary/octet-stream.)
aws s3 cp "$build_dir/latest-version" "${destination_bucket_uri}/latest-version" \
--content-type "text/plain" --acl public-read --region "$(aws_region)" --metadata-directive REPLACE
aws s3 cp "$build_dir/esc/latest-version" "${destination_bucket_uri}/esc/latest-version" \
--content-type "text/plain" --acl public-read --region "$(aws_region)" --metadata-directive REPLACE

# Smoke test the deployed website. Specs are in ../cypress/integration.
echo "Running tests..."
Expand Down
1 change: 1 addition & 0 deletions static/esc/latest-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
0.5.1

0 comments on commit f4560a1

Please sign in to comment.