[Ops/BK] Migrate serverless-release (#179063)

Candidate for the first buildkite pipeline to be migrated from
`kibana-buildkite` to the elastic-wide system.
The pipeline represented is:
https://buildkite.com/elastic/kibana-serverless-release-1

Quirk:
- When the pipeline was created, another pipeline was created (that's
since now been removed) with the same name, so this was assigned a `-1`
at the end. Hopefully not a problem when we're considering the takeover

This PR contains:
- `kibana-serverless-release.yml` - an automatic rewrite of the pipeline
resource from
https://github.com/elastic/kibana-buildkite/blob/main/pipelines/kibana-serverless-release.tf
- `locations.yml` - since we collect the pipelines in such a file to
avoid bloating `catalog-info.yaml`, the location needs to be updated
- `create_deployment_tag.yml` - updates the pipeline implementations
with agent targeting rules (since we no longer can use
(https://github.com/elastic/buildkite-agent-manager)

---------

Co-authored-by: Jon <jon@budzenski.me>
This commit is contained in:
Alex Szabo 2024-03-22 11:38:00 +01:00 committed by GitHub
parent 917f8546f8
commit 09a9f71b89
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 47 additions and 1 deletions

View file

@ -0,0 +1,42 @@
# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json
apiVersion: backstage.io/v1alpha1
kind: Resource
metadata:
name: buildkite-pipeline-serverless-release
description: Initiate kibana serverless releases
links:
- title: Pipeline
url: https://buildkite.com/elastic/kibana-serverless-release-1
spec:
type: buildkite-pipeline
owner: 'group:kibana-operations'
system: buildkite
implementation:
apiVersion: buildkite.elastic.dev/v1
kind: Pipeline
metadata:
name: kibana / serverless / release
description: Initiate kibana serverless releases
spec:
env:
SLACK_NOTIFICATIONS_CHANNEL: '#kibana-operations-alerts'
ELASTIC_SLACK_NOTIFICATIONS_ENABLED: 'false'
default_branch: main
repository: elastic/kibana
pipeline_file: .buildkite/pipelines/serverless_deployment/create_deployment_tag.yml
provider_settings:
build_branches: false
build_pull_requests: false
publish_commit_status: false
trigger_mode: none
build_tags: false
teams:
kibana-release-operators:
access_level: MANAGE_BUILD_AND_READ
schedules:
Weekly automated promotion to QA:
cronline: 0 6 * * 1
message: Weekly automated promotion to QA
env:
AUTO_SELECT_COMMIT: 'true'
branch: main

View file

@ -7,3 +7,4 @@ spec:
type: url
targets:
- https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-migration-staging.yml
- https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-release.yml

View file

@ -1,7 +1,10 @@
## Creates deploy@<timestamp> tag on Kibana
agents:
queue: kibana-default
image: family/kibana-ubuntu-2004
imageProject: elastic-images-qa
provider: gcp
machineType: n2-standard-2
steps:
- label: "List potential commits"