services:
  - type: 'org.apache.brooklyn.entity.stock.BasicApplication'
    name: AWS AppRegistry Discovery
    brooklyn.policies:
      - type: 'cmdb-discovery-policy'
        brooklyn.config:
          period: 10s
          command: amp-cmdb appregistry --export --profile amp-aws --output $AWS_FILE --all > /dev/null 2>&1 && cat $AWS_FILE
          env:
            AWS_FILE: /tmp/aws.discovered.json
