diff options
author | Lasse Haugen <haugen.lasse@gmail.com> | 2023-04-05 22:35:38 +0200 |
---|---|---|
committer | Lasse Haugen <haugen.lasse@gmail.com> | 2023-04-07 18:43:03 +0200 |
commit | 4cf3c338ad7bc5b171eb3b7d18c8d5494ac1a6df (patch) | |
tree | ae7bc513d81c0abb6cba7f8c7f530cf569ee72fd /web/api/write/fap | |
parent | 73712230cccb52757abdf3b3197b441ee301638a (diff) |
tg23 fixtg23
Diffstat (limited to 'web/api/write/fap')
-rwxr-xr-x | web/api/write/fap | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/web/api/write/fap b/web/api/write/fap new file mode 100755 index 0000000..69058eb --- /dev/null +++ b/web/api/write/fap @@ -0,0 +1,19 @@ +#!/bin/bash + +fil=/var/log/apache2/kek +echo 'Content-Type: text/html' +echo +echo +pw="<REDACTED>" +sw=$(echo $PATH_INFO | sed 's/^\///') +POST -H'Content-Type: application/json' https://gondul:${pw}@awx.tg23.gathering.org/api/v2/job_templates/19/launch/ >/dev/null 2>&1 <<_EOF_ +{"credential_passwords":{},"limit":"$sw","extra_vars":{}} +_EOF_ +ret=$? +./oplog >/dev/null 2>&1 <<_EOF_ +{"systems": "$sw", "log": "Refap queued in AWX for $sw"} +_EOF_ +while read; do + true +done +echo '"ok"' |