diff --git a/.github/workflows/deploy-to-nais.yml b/.github/workflows/deploy-to-nais.yml index ffb15d7..ab69d8e 100644 --- a/.github/workflows/deploy-to-nais.yml +++ b/.github/workflows/deploy-to-nais.yml @@ -1,6 +1,38 @@ name: Deploy to NAIS on: + workflow_dispatch: + inputs: + registry: + description: Registry, for example "europe-north1-docker.pkg.dev" + required: true + type: string + repository: + description: Registry repository + required: true + type: string + image-name: + description: Image name + required: true + type: string + image-tag: + description: Tag for the image + required: true + type: string + cluster: + description: NAIS cluster environment + required: true + type: string + nais-config-path: + description: Path to the NAIS configuration file + required: true + type: string + ref: + description: "Commit reference of the deployment" + required: false + default: master + type: string + workflow_call: inputs: registry: @@ -69,14 +101,14 @@ jobs: ls -la ${ext_config_dir} tree -L 6 ext-config echo ${ext_config_dir} - ls -la ${app_config_dir} - cat ${ext_config_dir}/bootstrap-${{ inputs.cluster }}.yml - echo "ext_config=${app_config_dir}" >> $GITHUB_ENV + ls -la ${ext_config_dir} + cat ${ext_config_dir}/maskinporten-clients.yml + echo "ext_config=${ext_config_dir}" >> $GITHUB_ENV - uses: nais/deploy/actions/deploy@v2 env: CLUSTER: ${{ inputs.cluster }} - RESOURCE: ${{ inputs.nais-config-path }},${{ env.ext_config }}/maskinporten-client.yml - VAR: image=${{ inputs.registry }}/${{ secrets.registry-project }}/${{ inputs.repository }}/${{ inputs.image-name }}:${{ inputs.image-tag }} + RESOURCE: ${{ inputs.nais-config-path }},${{ env.ext_config }}/maskinporten-clients.yml + VAR: image=${{ inputs.registry }}/${{ secrets.NAIS_MANAGEMENT_PROJECT_ID }}/${{ inputs.repository }}/${{ inputs.image-name }}:${{ inputs.image-tag }} DEPLOY_SERVER: deploy.ssb.cloud.nais.io:443 REF: ${{ inputs.ref }} \ No newline at end of file