jimmydot | 8b8addd | 2017-05-08 18:00:46 -0400 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
kurczews | 7b8621d | 2018-09-19 08:17:52 +0200 | [diff] [blame] | 3 | FINAL_CONFIG_FILE=$1/conf/quartz.properties |
| 4 | TEMPLATE_CONFIG_FILE=$1/conf/quartz_template.properties |
jimmydot | 8b8addd | 2017-05-08 18:00:46 -0400 | [diff] [blame] | 5 | |
| 6 | echo "Localizing the VID quartz configuration" |
| 7 | |
| 8 | sed -e 's/${VID_MYSQL_HOST}/'${VID_MYSQL_HOST}'/g' \ |
| 9 | -e 's/${VID_MYSQL_PORT}/'${VID_MYSQL_PORT}'/g' \ |
| 10 | -e 's/${VID_MYSQL_DBNAME}/'${VID_MYSQL_DBNAME}'/g' \ |
| 11 | -e 's/${VID_MYSQL_USER}/'${VID_MYSQL_USER}'/g' \ |
| 12 | -e 's/${VID_MYSQL_PASS}/'${VID_MYSQL_PASS}'/g' \ |
| 13 | -e 's/${VID_MYSQL_MAXCONNECTIONS}/'${VID_MYSQL_MAXCONNECTIONS}'/g' ${TEMPLATE_CONFIG_FILE} > ${FINAL_CONFIG_FILE} || { |
| 14 | echo "ERROR: Could not process template file ${TEMPLATE_CONFIG_FILE} into ${FINAL_CONFIG_FILE}" |
| 15 | exit 4 |
| 16 | } |
| 17 | |
| 18 | echo "Localized ${FINAL_CONFIG_FILE} successfully." |
| 19 | |
| 20 | |