---
# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
  name: apm-server
  description: apm-server
  annotations:
    github.com/project-slug: elastic/apm-server
    github.com/team-slug: elastic/apm-server

spec:
  type: tool
  owner: group:obs-ds-intake-services
  lifecycle: production

---
apiVersion: backstage.io/v1alpha1
kind: Resource
metadata:
  name: buildkite-pipeline-apm-server-package
  description: Buildkite Pipeline for packaging the APM Server
  links:
    - title: Pipeline
      url: https://buildkite.com/elastic/apm-server-package

spec:
  type: buildkite-pipeline
  owner: group:obs-ds-intake-services
  system: buildkite
  implementation:
    apiVersion: buildkite.elastic.dev/v1
    kind: Pipeline
    metadata:
      name: apm-server-package
    spec:
      repository: elastic/apm-server
      pipeline_file: ".buildkite/package.yml"
      provider_settings:
        build_branches: true
        build_pull_requests: true
        build_tags: false
        filter_enabled: true
        filter_condition: build.branch == "main" || build.branch == "8.x" || build.branch =~ /^[0-9]+\.[0-9]+$$/ || build.branch =~ /^feature\//
      cancel_intermediate_builds: false
      skip_intermediate_builds: false
      teams:
        obs-ds-intake-services: {}
        observablt-robots: {}
        everyone:
          access_level: READ_ONLY
      schedules:
        Weekly 7.17:
          branch: "7.17"
          cronline: "@weekly"
          message: Builds `7.17` DRA
