-
Notifications
You must be signed in to change notification settings - Fork 26
Running plugins on the MOC (ppc64le OpenShift)
Elizabeth Slade edited this page May 3, 2020
·
11 revisions
This page documents some pfcon
related commands for executing plugins on the Massachusetts Open Cloud by communicating with a pman
and pfioh
exposed the OpenShift cluster.
Set the access IP to the machine running pfcon
. This snippet sets a variable HOST_IP
on Linux hosts. This will NOT work on macOS. Also, even on Linux, please check with an echo $HOST_IP
that this value is indeed sane and correct!
export HOST_IP=$(ip route | grep -v docker | awk '{if(NF==11) print $9}' | head -n 1)
pfurl --verb POST --raw \
--http ${HOST_IP}:5005/api/v1/cmd \
--httpResponseBodyParse \
--jsonwrapper 'payload' \
--msg \
'{ "action": "internalctl",
"meta": {
"var": "/service/moc-ppc64le",
"set": {
"compute": {
"addr": "pman2-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/",
"baseURLpath": "api/v1/cmd/",
"status": "undefined",
"authToken": "password"
},
"data": {
"addr": "pfioh-ppc64le-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/pfioh/",
"baseURLpath": "api/v1/cmd/",
"status": "undefined",
"authToken": "password"
}
}
}
}'
pfurl --verb POST --raw \
--http ${HOST_IP}:5005/api/v1/cmd \
--httpResponseBodyParse \
--jsonwrapper 'payload' \
--msg \
'{ "action": "internalctl",
"meta": {
"var": "/service/moc-ppc64le",
"set": {
"compute": {
"addr": "pman-ppc64le-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/pman/",
"baseURLpath": "api/v1/cmd/",
"status": "undefined",
"authToken": "password"
},
"data": {
"addr": "pfioh-ppc64le-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/pfioh/",
"baseURLpath": "api/v1/cmd/",
"status": "undefined",
"authToken": "password"
}
}
}
}'
pfurl --verb POST --raw \
--http ${HOST_IP}:5005/api/v1/cmd \
--httpResponseBodyParse \
--jsonwrapper 'payload' \
--msg \
'{ "action": "internalctl",
"meta": {
"var": "/self",
"set": {
"httpProxy": {
"httpSpec": "http://proxy.tch.harvard.edu:3128",
"use": true
}
}
}
}'
pfurl --verb POST --raw --http ${HOST_IP}:5005/api/v1/cmd \
--httpResponseBodyParse --jsonwrapper 'payload' --msg \
'{ "action": "hello",
"meta": {
"askAbout": "sysinfo",
"echoBack": "Hi there!",
"service": "moc-ppc64le"
}
}'
pfurl --verb POST --raw \
--http pman2-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/api/v1/cmd \
--jsonwrapper 'payload' --msg \
'{ "action": "hello",
"meta": {
"askAbout": "sysinfo",
"echoBack": "Hi there!"
}
}' --quiet --authToken 'password'
pfurl --verb POST --raw \
--http pman-ppc64le-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/pman/api/v1/cmd \
--jsonwrapper 'payload' --msg \
'{ "action": "hello",
"meta": {
"askAbout": "sysinfo",
"echoBack": "Hi there!"
}
}' --quiet --authToken 'password'
pfurl --verb POST --raw \
--http pfioh-ppc64le-benchmarking-chris-on-the-moc.p9-apps.osh.massopen.cloud/pfioh/api/v1/cmd \
--jsonwrapper 'payload' --msg \
'{ "action": "hello",
"meta": {
"askAbout": "sysinfo",
"echoBack": "Hi there!"
}
}' --quiet --authToken 'password'
-30-