Commit e14bead7 authored by Egor Kremnev's avatar Egor Kremnev

fix scripts

parent f689ff77
...@@ -84,8 +84,6 @@ info "# Database folder permission" ...@@ -84,8 +84,6 @@ info "# Database folder permission"
chmod -R 775 database chmod -R 775 database
chown -R $(whoami) database chown -R $(whoami) database
cp scripts/nginx/default /etc/nginx/sites-available/default
info "# Restart nginx server" info "# Restart nginx server"
service nginx restart service nginx restart
......
...@@ -39,6 +39,7 @@ script_execution_dir=$(pwd) ...@@ -39,6 +39,7 @@ script_execution_dir=$(pwd)
info "Scripts run under ${script_execution_dir} directory" info "Scripts run under ${script_execution_dir} directory"
scp ${PATH_TO_SCRIPTS_DIR}/apply-update.sh ${HOST}:${APPLICATION_ROOT_PATH} scp ${PATH_TO_SCRIPTS_DIR}/apply-update.sh ${HOST}:${APPLICATION_ROOT_PATH}
scp ${PATH_TO_NGINX_CONFIG_FILE} ${HOST}:/etc/nginx/sites-available/default
scp ${LATEST_ARTIFACT_PATH} ${HOST}:${APPLICATION_ROOT_PATH} scp ${LATEST_ARTIFACT_PATH} ${HOST}:${APPLICATION_ROOT_PATH}
echo ${VERSION} > VERSION echo ${VERSION} > VERSION
...@@ -47,6 +48,6 @@ scp VERSION ${HOST}:${APPLICATION_ROOT_PATH} ...@@ -47,6 +48,6 @@ scp VERSION ${HOST}:${APPLICATION_ROOT_PATH}
# shellcheck disable=SC2087 # shellcheck disable=SC2087
echo ${HOST} echo ${HOST}
ssh ${HOST} <<EOL ssh ${HOST} <<EOL
chmod +x apply-update.sh
${APPLICATION_ROOT_PATH}/apply-update.sh ${INSTANCE_NAME} ${LATEST_ARTIFACT_NAME} ${APPLICATION_ROOT_PATH} ${APPLICATION_ROOT_PATH}/apply-update.sh ${INSTANCE_NAME} ${LATEST_ARTIFACT_NAME} ${APPLICATION_ROOT_PATH}
chmod +x ${APPLICATION_ROOT_PATH}/apply-update.sh
EOL EOL
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment