Skip to content

Commit

Permalink
update status/restore functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
root committed Apr 17, 2024
1 parent 8a4e08c commit 8e17535
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Workbench/scripts/gethealth.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
print("<table><tr><th style='text-align:left;width:150px'>Container</th><th style='text-align:left'>Health Status</th></tr>")
for container in containers:
from subprocess import Popen, PIPE
dcmd = "docker ps -f name=workbench_" + container + "_1 --format '{{ .Status }} '"
dcmd = "docker ps -f name=workbench-" + container + "-1 --format '{{ .Status }} '"
pipe = Popen(dcmd, shell=True, stdout=PIPE)
healthstatus = '<font color="grey">unknown</font>'
for line in pipe.stdout:
Expand Down
2 changes: 1 addition & 1 deletion Workbench/scripts/update-health-status.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

/csp-tap/InCommonTAP-Examples/Workbench/scripts/gethealth.py > /csp-tap/InCommonTAP-Examples/Workbench/scripts/gethealth-output.txt

docker cp /csp-tap/InCommonTAP-Examples/Workbench/scripts/gethealth-output.txt workbench_webproxy_1:/var/www/html/status/index.html
docker cp /csp-tap/InCommonTAP-Examples/Workbench/scripts/gethealth-output.txt workbench-webproxy-1:/var/www/html/status/index.html
1 change: 1 addition & 0 deletions Workbench/webproxy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ RUN sed -i 's/TransferLog logs\/ssl_access_log/TransferLog \/tmp\/logpipe/g' /et

#set hostname
RUN /usr/local/bin/setservername.sh
RUN mkdir -p /run/php-fpm/

HEALTHCHECK --interval=1m --timeout=30s \
CMD curl -k -f -u csp:workbench https://127.0.0.1/Shibboleth.sso/Status || exit 1
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/sh
/usr/local/bin/startup.sh &
php-fpm -D &

#wait for IdPUI's API, then load metadata into it
pushd /mdload
Expand Down

0 comments on commit 8e17535

Please sign in to comment.