Skip to content

Commit

Permalink
create tools/readme.adoc
Browse files Browse the repository at this point in the history
  • Loading branch information
fridim committed Oct 9, 2023
1 parent 7792a05 commit 69e10a0
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 2 deletions.
19 changes: 19 additions & 0 deletions tools/readme.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
== Run admin pod ==

----
oc run -n babylon-sandbox-api admin \
--image=quay.io/rhpds/sandbox-admin:latest -i -t --restart=Never --rm -- /bin/bash
----

== `reserve.hurl` ==

.Example create a summit reservation of 4 AwsSandbox
----
# Run from within the admin pod
hurl reserve.hurl \
--variable host=sandbox-api.babylon-sandbox-api.svc.cluster.local:8080 \
--variable login_token_admin=... \
--variable reservation_name=summit \
--variable reservation_resource_kind=AwsSandbox \
--variable reservation_resource_count=4 --verbose
----
4 changes: 2 additions & 2 deletions tools/reserve.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#################################################################################

GET http://{{host}}/api/v1/login
Authorization: Bearer {{login_token}}
Authorization: Bearer {{login_token_admin}}
HTTP 200
[Captures]
access_token: jsonpath "$.access_token"
Expand All @@ -17,7 +17,7 @@ jsonpath "$.access_token_exp" isString
#################################################################################

POST http://{{host}}/api/v1/reservations
Authorization: Bearer {{access_token_admin}}
Authorization: Bearer {{access_token}}
{
"name": "{{reservation_name}}",
"resources": [
Expand Down

0 comments on commit 69e10a0

Please sign in to comment.