File tree Expand file tree Collapse file tree 2 files changed +8
-11
lines changed Expand file tree Collapse file tree 2 files changed +8
-11
lines changed Original file line number Diff line number Diff line change @@ -10,13 +10,13 @@ inputs:
10
10
nginx-deployment-name :
11
11
description : ' The name of the NGINX deployment'
12
12
required : true
13
- nginx-config-file-path :
14
- description : ' The file path of the NGINX configuration file in the Git repository'
13
+ nginx-config-relative- file-path :
14
+ description : ' The relative file path of the NGINX configuration file in the Git repository'
15
15
required : true
16
16
default : ' ./config/nginx.conf'
17
17
runs :
18
18
using : " composite"
19
19
steps :
20
20
- name : ' Deploy configuration to the NGINX deployment in Azure'
21
- run : ${{github.action_path}}/src/deploy-config.sh ${{ inputs.subscription-id }} ${{ inputs.resource-group-name }} ${{ inputs.nginx-deployment-name }} ${{ inputs.nginx-config-file-path }}
21
+ run : ${{github.action_path}}/src/deploy-config.sh ${{ inputs.subscription-id }} ${{ inputs.resource-group-name }} ${{ inputs.nginx-deployment-name }} ${{ inputs.nginx-config-relative- file-path }}
22
22
shell : bash
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
-
3
- # Stop on error.
4
- set -e
2
+ set -euo pipefail
3
+ IFS=$' \n\t '
5
4
6
5
subscriptionId=$1
7
6
resourceGroupName=$2
@@ -11,12 +10,10 @@ nginxConfigurationFile=$4
11
10
# Read and encode the NGINX configuration file content.
12
11
if [ -f " $nginxConfigurationFile " ]
13
12
then
14
- echo " NGINX configuration"
15
- cat " $nginxConfigurationFile "
16
- echo " "
13
+ echo " The NGINX configuration file was found."
17
14
else
18
- echo " NGINX configuration $nginxConfigurationFile does not exist."
19
- exit 32
15
+ echo " The NGINX configuration file $nginxConfigurationFile does not exist."
16
+ exit 2
20
17
fi
21
18
22
19
encodedConfigContent=$( base64 $nginxConfigurationFile )
You can’t perform that action at this time.
0 commit comments