@@ -25,40 +25,11 @@ inputs:
2525 description : " Name of the Component to deploy"
2626 required : true
2727 default : ' api'
28- nodejs_version :
29- description : " Node.js version, set by the CI/CD pipeline workflow"
30- required : true
31- NODE_AUTH_TOKEN :
32- description : " Token for access to github package registry"
33- required : true
3428
3529runs :
3630 using : composite
3731
3832 steps :
39- - name : Checkout
40- uses : actions/checkout@v4
41- - uses : actions/setup-node@v4
42- with :
43- node-version : ${{ inputs.nodejs_version }}
44- registry-url : ' https://npm.pkg.github.com'
45-
46- - name : " Cache node_modules"
47- uses : actions/cache@v4
48- with :
49- path : |
50- **/node_modules
51- key : ${{ runner.os }}-node-${{ inputs.nodejs_version }}-${{ hashFiles('**/package-lock.json') }}
52- restore-keys : |
53- ${{ runner.os }}-node-${{ inputs.nodejs_version }}-
54-
55- - name : Npm install
56- working-directory : .
57- env :
58- NODE_AUTH_TOKEN : ${{ inputs.NODE_AUTH_TOKEN }}
59- run : npm ci
60- shell : bash
61-
6233 - name : Setup Proxy Name and target
6334 shell : bash
6435 run : |
8758 echo "MTLS_NAME=notify-supplier-mtls-pr$PR_NUMBER" >> $GITHUB_ENV
8859 fi
8960
90- - name : Build ${{ inputs.apimEnv }} oas
91- working-directory : .
92- env :
93- APIM_ENV : ${{ inputs.apimEnv }}
94- shell : bash
95- run : |
96- if [ ${{ env.APIM_ENV }} == "internal-dev-sandbox" ] && [ ${{ inputs.buildSandbox }} == true ]
97- then
98- echo "Building sandbox OAS spec"
99- make build-json-oas-spec APIM_ENV=sandbox
100- else
101- echo "Building env specific OAS spec"
102- make build-json-oas-spec APIM_ENV=${{ env.APIM_ENV }}
103- fi
104-
105- if [[ $APIM_ENV == *-pr ]]; then
106- echo "Removing pr suffix from APIM_ENV after building OAS and calling proxygen"
107- APIM_ENV=$(echo "$APIM_ENV" | sed 's/-pr$//')
108- fi
109- echo "APIM_ENV=$APIM_ENV" >> $GITHUB_ENV
110-
11161 - name : Upload OAS Spec
11262 uses : actions/upload-artifact@v4
11363 with :
11666
11767 - name : Trigger deploy proxy
11868 env :
69+ APIM_ENV : ${{ inputs.apimEnv }}
11970 APP_CLIENT_ID : ${{ env.APP_CLIENT_ID }}
12071 APP_PEM_FILE : ${{ env.APP_PEM_FILE }}
12172 shell : bash
0 commit comments