---
- scm:
    name: govuk-provisioning_Network_Config_Deploy_DryRun
    scm:
        - git:
            url: git@github.gds:gds/govuk-provisioning.git
            branches:
              - master

- job:
    name: Network_Config_Deploy_DryRun
    display-name: Network_Config_Deploy_DryRun
    project-type: freestyle
    description: "Dry run only. Use this to observe the diff output before deploying for real. Accepts a branch so that you can test pull requests."
    properties:
        - github:
            url: https://github.gds/gds/govuk-provisioning/
    scm:
      - govuk-provisioning_Network_Config_Deploy_DryRun
    builders:
        - shell: |
            ./vcloud-edge_gateway/jenkins.sh <%= @environment_script_parameter %> --dry-run
    wrappers:
        - ansicolor:
            colormap: xterm
        - build-name:
            name: '#${BUILD_NUMBER} ${ENV,var="component"}'
    parameters:
        - choice:
            name: COMPONENT
            description: Which part of the networking config do you wish to update?
            choices:
                - PLEASE CHOOSE ONE
                - lb
                - nat
                - firewall
                - vpn
        - string:
            name: USERNAME
            description: Vcloud username
        - password:
            name: VCLOUD_PASSWORD
            description: Vcloud Password

---
- scm:
    name: govuk-provisioning_Network_Config_Deploy_DryRun
    scm:
        - git:
            url: git@github.gds:gds/govuk-provisioning.git
            branches:
              - master

- job:
    name: Network_Config_Deploy_DryRun
    display-name: Network_Config_Deploy_DryRun
    project-type: freestyle
    description: "Dry run only. Use this to observe the diff output before deploying for real. Accepts a branch so that you can test pull requests."
    properties:
        - github:
            url: https://github.gds/gds/govuk-provisioning/
    scm:
      - govuk-provisioning_Network_Config_Deploy_DryRun
    builders:
        - shell: |
            ./vcloud-edge_gateway/jenkins.sh <%= @environment_script_parameter %> --dry-run
    wrappers:
        - ansicolor:
            colormap: xterm
        - build-name:
            name: '#${BUILD_NUMBER} ${ENV,var="component"}'
    parameters:
        - choice:
            name: COMPONENT
            description: Which part of the networking config do you wish to update?
            choices:
                - PLEASE CHOOSE ONE
                - lb
                - nat
                - firewall
                - vpn
        - string:
            name: USERNAME
            description: Vcloud username
        - password:
            name: VCLOUD_PASSWORD
            description: Vcloud Password
        - choice:
            name: TARGET_ENVIRONMENT
            description: The environment to deploy network configuration to
            choices:
                <%- @environments.each do |env| -%>
                - <%= env %>
                <%- end -%>

Add environment options to dryrun job
Add environment options to dryrun job

This job should mimic the real job and lacks the options to select which
environment to deploy network changes too.
