DO288-apps/s2i-build/.s2i/bin/assemble
2019-05-23 13:13:16 -04:00

25 lines
723 B
Bash
Executable file

#!/bin/bash -e
#
# S2I assemble script for the 's2i-do288-httpd' image.
# The 'assemble' script builds your application source so that it is ready to run.
#
# For more information refer to the documentation:
# https://github.com/openshift/source-to-image/blob/master/docs/builder_image.md
#
if [[ "$1" == "-h" ]]; then
# If the 's2i-do288-httpd' assemble script is executed with '-h' flag,
# print the usage.
exec /usr/libexec/s2i/usage
fi
# Restore artifacts from the previous build (if they exist).
#
if [ "$(ls /tmp/artifacts/ 2>/dev/null)" ]; then
echo "---> Restoring build artifacts..."
mv /tmp/artifacts/. ./
fi
echo "---> Copying source files to web server directory..."
cp -Rf /tmp/src/. /var/www/html/