Skip to content

Commit

Permalink
[Console] Console definitions script should generate separate prs for…
Browse files Browse the repository at this point in the history
… main and 8.x (elastic#207036)
  • Loading branch information
sabarasaba authored Jan 28, 2025
1 parent 23b7f0f commit 9e60b8e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ spec:
SLACK_NOTIFICATIONS_CHANNEL: '#kibana-management'
ELASTIC_SLACK_NOTIFICATIONS_ENABLED: 'true'
allow_rebuilds: false
branch_configuration: main
branch_configuration: main 8.x
default_branch: main
repository: elastic/kibana
pipeline_file: .buildkite/pipelines/console_definitions_sync.yml
Expand Down
14 changes: 11 additions & 3 deletions .buildkite/scripts/steps/console_definitions_sync.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ main () {
report_main_step "Cloning repositories"

rm -rf elasticsearch-specification
if ! git clone https://github.com/elastic/elasticsearch-specification --depth 1; then
if ! git clone --branch "$BUILDKITE_BRANCH" https://github.com/elastic/elasticsearch-specification --depth 1; then
echo "Error: Failed to clone the elasticsearch-specification repository."
exit 1
fi
Expand All @@ -40,7 +40,7 @@ main () {
git config --global user.name "$KIBANA_MACHINE_USERNAME"
git config --global user.email '[email protected]'

PR_TITLE='[Console] Update console definitions'
PR_TITLE="[Console] Update console definitions (${branch_name})"
PR_BODY='This PR updates the console definitions to match the latest ones from the @elastic/elasticsearch-specification repo.'

# Check if a PR already exists
Expand All @@ -66,7 +66,15 @@ main () {
git push origin "$BRANCH_NAME"

# Create PR
gh pr create --title "$PR_TITLE" --body "$PR_BODY" --base main --head "${BRANCH_NAME}" --label 'release_note:skip' --label 'Feature:Console' --label 'Team:Kibana Management'
gh pr create \
--title "$PR_TITLE" \
--body "$PR_BODY" \
--base "$BUILDKITE_BRANCH" \
--head "$BRANCH_NAME" \
--label 'backport:skip' \
--label 'release_note:skip' \
--label 'Feature:Console' \
--label 'Team:Kibana Management'
}

main

0 comments on commit 9e60b8e

Please sign in to comment.