-
Notifications
You must be signed in to change notification settings - Fork 8.6k
[build] Upload CDN assets #173159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[build] Upload CDN assets #173159
Changes from 4 commits
e9d7e30
3598ce8
452f1cb
ccc1ebb
c3b7749
8bd4c9a
db0dcc6
a8fbf3d
5c90002
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,7 +26,7 @@ if docker manifest inspect $KIBANA_IMAGE &> /dev/null; then | |
| exit 1 | ||
| fi | ||
|
|
||
| echo "--- Build images" | ||
| echo "--- Build Kibana" | ||
| node scripts/build \ | ||
| --debug \ | ||
| --release \ | ||
|
|
@@ -37,8 +37,7 @@ node scripts/build \ | |
| --skip-docker-ubuntu \ | ||
| --skip-docker-ubi \ | ||
| --skip-docker-cloud \ | ||
| --skip-docker-contexts \ | ||
| --skip-cdn-assets | ||
| --skip-docker-contexts | ||
|
|
||
| echo "--- Tag images" | ||
| docker rmi "$KIBANA_IMAGE" | ||
|
|
@@ -88,12 +87,21 @@ fi | |
| echo "--- Build dependencies report" | ||
| node scripts/licenses_csv_report "--csv=target/dependencies-$GIT_ABBREV_COMMIT.csv" | ||
|
|
||
| echo "--- Upload artifacts" | ||
| echo "--- Upload CDN assets" | ||
| gcloud auth activate-service-account --key-file <(echo "$GCS_SA_CDN_QA_KEY") | ||
|
|
||
| CDN_ASSETS_FOLDER=$(mktemp -d) | ||
| tar -xf "kibana-$BASE_VERSION-cdn-assets.tar.gz" -C "$CDN_ASSETS_FOLDER" --strip=1 | ||
|
|
||
| gsutil -m cp -r "$CDN_ASSETS_FOLDER/*" "gs://$GCS_SA_CDN_QA_BUCKET/$GIT_ABBREV_COMMIT" | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How would we construct this path to point to the static assets from index.html? We already use a build number https://github.com/elastic/kibana/blob/main/packages/core/rendering/core-rendering-server-internal/src/bootstrap/bootstrap_renderer.ts#L82 Is this
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The build number doesn't contain all assets and in a branching scenario can cause conflicts.
It is, build.sha{0,12}. It's also available to the controller as the id used to reference a build. |
||
|
|
||
| echo "--- Upload archives" | ||
| cd target | ||
| buildkite-agent artifact upload "kibana-$BASE_VERSION-linux-x86_64.tar.gz" | ||
| buildkite-agent artifact upload "kibana-$BASE_VERSION-linux-aarch64.tar.gz" | ||
| buildkite-agent artifact upload "kibana-$BASE_VERSION-docker-image.tar.gz" | ||
| buildkite-agent artifact upload "kibana-$BASE_VERSION-docker-image-aarch64.tar.gz" | ||
| buildkite-agent artifact upload "kibana-$BASE_VERSION-cdn-assets.tar.gz" | ||
| buildkite-agent artifact upload "dependencies-$GIT_ABBREV_COMMIT.csv" | ||
| cd - | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.