Allowing a second argument to response to specify the value.
This commit is contained in:
+8
-1
@@ -16,4 +16,11 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
curl -sf -X PUT --data-binary @- ${KAPOW_URL}/connections/${KAPOW_CONNECTION}/response$1
|
||||
if [ $# -lt 1 ]; then
|
||||
echo "Response object is mandatory" >&2
|
||||
exit 1
|
||||
elif [ $# -eq 1 ]; then
|
||||
curl -N -sf -X PUT --data-binary @- ${KAPOW_URL}/connections/${KAPOW_CONNECTION}/response$1
|
||||
else
|
||||
curl -sf -X PUT --data-binary "$2" ${KAPOW_URL}/connections/${KAPOW_CONNECTION}/response$1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user