some testing
This commit is contained in:
parent
9cb3b60335
commit
36a94a07a7
1 changed files with 13 additions and 4 deletions
17
deploy.sh
17
deploy.sh
|
@ -1,14 +1,23 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
echo "Target: ${TARGET}"
|
echo "Target: ${ENVIRON}"
|
||||||
if [ "develop" == "${ENVIRON}" ] ; then
|
if [ "develop" == "${ENVIRON}" ] ; then
|
||||||
echo "Deploying ${CI_BUILD_REF_NAME} to develop. You can access it at .../${CI_BUILD_REF_NAME}"
|
echo "Deploying ${CI_BUILD_REF_NAME} to develop. You can access it at .../${CI_BUILD_REF_NAME}"
|
||||||
target="${WWW_DEPLOY_ROOT_DEVELOP}/${CI_BUILD_REF_NAME}"
|
target="${WWW_DEPLOY_ROOT_DEVELOP}/${CI_BUILD_REF_NAME}"
|
||||||
mkdir -p "${target}"
|
rm -rf "${target}"
|
||||||
rm -rf "${target}/*"
|
mkdir -p "${target}/dist"
|
||||||
mkdir "${target}/dist"
|
|
||||||
cp -a index.html manifest.appcache info resources "${target}"
|
cp -a index.html manifest.appcache info resources "${target}"
|
||||||
cp -a dist/*.min.* "${target}/dist"
|
cp -a dist/*.min.* "${target}/dist"
|
||||||
else
|
else
|
||||||
echo "Automatic deployment to ${ENVIRON} is not yet implemented."
|
echo "Automatic deployment to ${ENVIRON} is not yet implemented."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "${WWW_DEPLOY_ROOT_DEVELOP}" == "${TARGET}" ] ; then
|
||||||
|
echo "Deployment to develop requested"
|
||||||
|
elif [ "${WWW_DEPLOY_ROOT_STAGING}" == "${TARGET}" ] ; then
|
||||||
|
echo "Deployment to staging requested"
|
||||||
|
elif [ "${WWW_DEPLOY_ROOT_PRODUCTION}" == "${TARGET}" ] ; then
|
||||||
|
echo "Deployment to PRODUCTION requested"
|
||||||
|
else
|
||||||
|
echo "Unknown environment: ${TARGET}"
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in a new issue