apiVersion: xl/v2
kind: Blueprint

metadata:
  name: docker-compose-cyberark-conjur
  description: |
    Creates a CyberArk Conjur server.
  author: XebiaLabs
  version: 2.0
  suppressXebiaLabsFolder: true
  instructions: Please read xebialabs/USAGE-cyberark-conjur.md.

spec:
  parameters:
  - name: DockerCyberArkAccount
    type: Input
    prompt: "Enter the account name:"

  - name: DockerCyberArkPolicyPath
    type: Input
    prompt: "Enter the policy path:"

  - name: DockerCyberArkKeys
    type: Input
    prompt: "Comma-separated list of secret keys to be created (e.g. key.one,key.two). You will supply the values manually:"
    validate: !expr "regex('^([a-zA-Z0-9._-]+,)*[a-zA-Z0-9._-]+$', DockerCyberArkKeys)"

  files:
  - path: xebialabs/USAGE-cyberark-conjur.md.tmpl
  - path: docker-cyberark-conjur/docker-compose.yaml.tmpl
  - path: docker-cyberark-conjur/conf/policy/root-policy.yaml.tmpl
  - path: docker-cyberark-conjur/conf/policy/dev-policy.yaml.tmpl
  - path: docker-cyberark-conjur/conf/policy/test-policy.yaml.tmpl
  - path: docker-cyberark-conjur/conf/policy/prod-policy.yaml.tmpl
  - path: docker-cyberark-conjur/conjur-client/Dockerfile
  - path: docker-cyberark-conjur/conjur-client/script/provision.sh.tmpl
  - path: docker-cyberark-conjur/conjur-server/Dockerfile
  - path: docker-cyberark-conjur/conjur-server/script/provision.sh.tmpl
  - path: docker-cyberark-conjur/volumes/.gitkeep
