---
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
  name: kibana
  description: Kibana is a user interface that lets you visualize your Elasticsearch data and navigate the Elastic Stack.

  annotations:
    backstage.io/source-location: url:https://github.com/elastic/kibana/tree/main
    github.com/project-slug: elastic/kibana
    github.com/team-slug: elastic/kibana-tech-leads
    buildkite.com/project-slug: elastic/kibana
    sonarqube.org/project-key: elastic_kibana_AYvOkAHeQZlFqhqWIr9
    pagerduty.com/service-id: PC4TBJY

  tags:
    - typescript
    - javascript
    - dashboards
    - metrics
    - visualizations
    - observability

  links:
    - title: Documentation
      url: https://www.elastic.co/guide/en/kibana/current/index.html

spec:
  type: monorepo
  owner: group:kibana-tech-leads
  lifecycle: production

---
apiVersion: backstage.io/v1alpha1
kind: Location
metadata:
  name: kibana-buildkite-pipelines
  description: A location re-routing file, pointing to individual buildkite pipeline definition files
spec:
  type: url
  target: https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/locations.yml

---
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
  name: Kibana-UI-Service
  description: Kibana UI Service provides the UX for visualizing Elasticsearch data.  It is comprised of a client side for presentation and user event handling and a server side application for UX servicing and interaction with Elasticsearch.
  annotations:
    backstage.io/source-location: url:https://github.com/elastic/kibana/tree/main
    github.com/project-slug: elastic/kibana
    github.com/team-slug: elastic/kibana-tech-leads
    buildkite.com/project-slug: elastic/kibana
    pagerduty.com/service-id: PC4TBJY
  tags:
    - typescript
    - javascript
    - dashboards
    - metrics
    - visualizations
    - observability
  links:
    - title: Documentation
      url: https://www.elastic.co/guide/en/kibana/current/index.html
spec:
  type: service
  owner: group:kibana-tech-leads
  lifecycle: production
  system: control-plane

---
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
  name: Kibana-Background-Tasks-Service
  description: Kibana Background Tasks Service provides additional task processing parallelism for an instance of the Kibana UI Service.  It is comprised of the same codebase as Kibana UI Service but is launched with an alternative configuration.
  annotations:
    backstage.io/source-location: url:https://github.com/elastic/kibana/tree/main
    github.com/project-slug: elastic/kibana
    github.com/team-slug: elastic/kibana-tech-leads
    buildkite.com/project-slug: elastic/kibana
    pagerduty.com/service-id: PC4TBJY
  tags:
    - typescript
    - javascript
    - dashboards
    - metrics
    - visualizations
    - observability
  links:
    - title: Documentation
      url: https://www.elastic.co/guide/en/kibana/current/index.html
spec:
  type: service
  owner: group:kibana-tech-leads
  lifecycle: production
  system: control-plane

---
# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json
apiVersion: backstage.io/v1alpha1
kind: Resource
metadata:
  name: buildkite-pipeline-kibana-sonarqube
  description: Run a SonarQube scan
  links:
    - title: Pipeline
      url: https://buildkite.com/elastic/kibana-sonarqube
spec:
  type: buildkite-pipeline
  owner: group:kibana-operations
  system: buildkite
  implementation:
    apiVersion: buildkite.elastic.dev/v1
    kind: Pipeline
    metadata:
      name: kibana / sonarqube
    spec:
      env:
        SLACK_NOTIFICATIONS_CHANNEL: '#kibana-operations-alerts'
        ELASTIC_SLACK_NOTIFICATIONS_ENABLED: 'true'
      repository: elastic/kibana
      provider_settings:
        trigger_mode: none
      pipeline_file: ".buildkite/pipelines/sonarqube.yml"
      teams:
        kibana-operations:
         access_level: MANAGE_BUILD_AND_READ
        everyone:
          access_level: READ_ONLY

# Please avoid creating new kibana pipelines in this file to avoid bloating.
# Instead, create a new file in the pipeline-resource-definitions directory, and wire it in through the locations.yml file.
