summaryrefslogtreecommitdiffstats
path: root/catalog-fe/src/main/resources/scripts/updateSslParams.sh
blob: d9e955e0f561b705693990cd3cd6079b4f7c9743 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh

function usage() {
        echo "$0 <working dir>"
}

function exitOnError() {
        if [ $1 -ne 0 ]
        then
                echo "Failed running task $2"
                exit 2
        fi
}

if [ $# -ne 1 ]
then
        usage
	if [ ${#OLDPWD} -ne 0 ]
	then
		cd -
	fi
        exit 1

fi

WORK_DIR=$1

cd $WORK_DIR

sed -i 's/\(^https.port=\)\(.*\)/\1443/g' start.d/https.ini
exitOnError $? "update_port_in_https_ini"

cd -