<commit_before>- type: replace
  path: /releases/-
  value:
    name: uaa
    version: 22
    url: https://bosh.io/d/github.com/cloudfoundry/uaa-release?v=24
    sha1: d0feb5494153217f3d62b346f426ad2b2f43511a

# Switch Director to use UAA
- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/provider
  value: uaa

- type: remove
  path: /instance_groups/name=bosh/properties/director/user_management/local

- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/uaa?/url
  value: "https://((internal_ip)):8443"

- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/uaa/public_key?
  value: ((uaa_jwt_signing_key.public_key))

# Add UAA job
- type: replace
  path: /instance_groups/name=bosh/jobs/-
  value:
    name: uaa
    release: uaa
    properties:
      uaa:
        url: "https://((internal_ip)):8443"
        sslPrivateKey: ((uaa_ssl.private_key))
        sslCertificate: ((uaa_ssl.certificate))
        jwt:
          signing_key: ((uaa_jwt_signing_key.private_key))
          verification_key: ((uaa_jwt_signing_key.public_key))
        scim:
          users:
          - name: admin
            groups: [scim.write, scim.read, bosh.admin]
            password: ((<PASSWORD>))
        clients:
          bosh_cli:
            override: true
            authorized-grant-types: password,refresh_token
            scope: openid,bosh.admin,bosh.read,bosh.*.admin,bosh.*.read
            authorities: uaa.none
            access-token-validity: 120 # 2 min
            refresh-token-validity: 86400 # 1 day
            secret: ""
          hm:
            override: true
            authorized-grant-types: client_credentials
            scope: ""
            authorities: bosh.admin
            secret: ((hm_password))
        admin: {client_secret: ((uaa_admin_client_secret))}
        login: {client_secret: ((uaa_login_client_secret))}
        zones: {internal: {hostnames: []}}
      login:
        saml:
          serviceProviderKey: ((uaa_service_provider_ssl.private_key))
          serviceProviderCertificate: ((uaa_service_provider_ssl.certificate))
      uaadb:
        address: 127.0.0.1
        port: 5432
        db_scheme: postgresql
        databases:
        - tag: uaa
          name: uaa
        roles:
        - tag: admin
          name: postgres
          password: ((<PASSWORD>))

- type: replace
  path: /instance_groups/name=bosh/properties/postgres/additional_databases?/-
  value: uaa<commit_msg>uaa.yml has login.saml.serviceProviderKeyPassword<commit_after>- type: replace
  path: /releases/-
  value:
    name: uaa
    version: 22
    url: https://bosh.io/d/github.com/cloudfoundry/uaa-release?v=24
    sha1: d0feb5494153217f3d62b346f426ad2b2f43511a

# Switch Director to use UAA
- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/provider
  value: uaa

- type: remove
  path: /instance_groups/name=bosh/properties/director/user_management/local

- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/uaa?/url
  value: "https://((internal_ip)):8443"

- type: replace
  path: /instance_groups/name=bosh/properties/director/user_management/uaa/public_key?
  value: ((uaa_jwt_signing_key.public_key))

# Add UAA job
- type: replace
  path: /instance_groups/name=bosh/jobs/-
  value:
    name: uaa
    release: uaa
    properties:
      uaa:
        url: "https://((internal_ip)):8443"
        sslPrivateKey: ((uaa_ssl.private_key))
        sslCertificate: ((uaa_ssl.certificate))
        jwt:
          signing_key: ((uaa_jwt_signing_key.private_key))
          verification_key: ((uaa_jwt_signing_key.public_key))
        scim:
          users:
          - name: admin
            groups: [scim.write, scim.read, bosh.admin]
            password: ((<PASSWORD>))
        clients:
          bosh_cli:
            override: true
            authorized-grant-types: password,refresh_token
            scope: openid,bosh.admin,bosh.read,bosh.*.admin,bosh.*.read
            authorities: uaa.none
            access-token-validity: 120 # 2 min
            refresh-token-validity: 86400 # 1 day
            secret: ""
          hm:
            override: true
            authorized-grant-types: client_credentials
            scope: ""
            authorities: bosh.admin
            secret: ((hm_password))
        admin: {client_secret: ((uaa_admin_client_secret))}
        login: {client_secret: ((uaa_login_client_secret))}
        zones: {internal: {hostnames: []}}
      login:
        saml:
          serviceProviderKey: ((uaa_service_provider_ssl.private_key))
          serviceProviderKeyPassword: "" # TODO: Remove this when UAA defaults this value
          serviceProviderCertificate: ((uaa_service_provider_ssl.certificate))
      uaadb:
        address: 127.0.0.1
        port: 5432
        db_scheme: postgresql
        databases:
        - tag: uaa
          name: uaa
        roles:
        - tag: admin
          name: postgres
          password: ((<PASSWORD>))

- type: replace
  path: /instance_groups/name=bosh/properties/postgres/additional_databases?/-
  value: uaa
{'fraction_non_alphanumeric': 0.10991129965291169, 'fraction_numerical': 0.023139220979560355, 'mean_word_length': 2.4192485168094926, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5403335', 'n_tokens_mistral': 1766, 'n_tokens_neox': 1670, 'n_words': 300}