Richard Allred
2019-05-23 497620c4d1bcb410267c56351432f87fb3aee5a4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/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/