Workaround to logging issues with ICP

Workaround to errors being encountered with the version of kubernetes
used in ICP. Logging broke in ICP v1.2 with the update to k8s 1.6.2
as it would hang after the container finished. In ICP v2.1 logging does
not work 100% of the time when getting the logs of multiple pods
simultaneously. As a workaround, adding a new variable that will be used
to launch the workaround template and instead of logging do a kubectl
exec to get the log output.

Now let me explain what the workaround is, instead of launching directly
into the script at container start, it will instead sleep for 2 hours.
Then the logging section of the kubernetes-launch.sh will instead of
logging do an exec command to start the script. This will stream the
output of running the script to whatever shell launched the script. It
will then rely on the "purge" variable to clear out the container once
the script completes.

Change-Id: I23e2ef48731bfc4c9ea8e0a3128fa32ca1901d9f
Signed-off-by: Alanny Lopez <alanny.lopez@ibm.com>
3 files changed