Skip to content
Snippets Groups Projects

added button to /workspaces page for creating a std imaging capability request

Merged Andrew Kapuscinski requested to merge WS-268-button-for-std-imaging-requests into main
3 unresolved threads
Files
3
#!/usr/bin/env bash
set -o errexit -o nounset
function usage {
echo "Usage: ingest-request [-c] [workflow_request_id]
This script sets off a Workspaces ingestion workflow of the specified type,
given by the chosen option, for the provided workflow request id.
Options:
-c, --calibration run the ingest_cal workflow for the specified request
-h, --help display this help and exit
"
}
option=$(echo "$1" | tr A-Z a-z)
case $option in
--calibration|-c)
action="ingest_cal"
;;
--help|-h)
usage
;;
esac
WORKFLOW_SERVICE=$(capo -q edu.nrao.archive.workspaces.WorkflowSettings.serviceUrl)
if [ "$action" = "ingest_cal" ]; then
curl -X POST $WORKFLOW_SERVICE/workflows/std_calibration/requests/$2/ingest
fi
Loading