Skip to content

Commit

Permalink
Added more API endpoints and updated script help (#5)
Browse files Browse the repository at this point in the history
* Added more API endpoints
The API endpoint with the nearest physical location can be used.

* Updated script help for private clouds
Output displays now correct key privileges if created with generate_key function.
  • Loading branch information
Decstasy authored Mar 14, 2019
1 parent f1604cd commit eb7045d
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions check_ovh_service_expiry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ Allow access to:
/dedicated/server/*
/domain/*
/vps/*
/dedicatedCloud/*
If you get with enabled debug mode output like this:
{"errorCode":"INVALID_CREDENTIAL","httpCode":"403 Forbidden","message":"This credential is not valid"}
Expand Down Expand Up @@ -274,11 +275,23 @@ while getopts “:hdgW:C:P:t:k:s:c:p:” OPTION; do
C) crit=$OPTARG
;;
P) case $OPTARG in
'ovh') api="https://eu.api.ovh.com/1.0"
# You may change the endpoint to your nearest physical location
'ovh') # Europe
api="https://eu.api.ovh.com/1.0"
# USA
# api="https://api.us.ovhcloud.com/1.0"
# Canada
# api="https://ca.api.ovh.com/1.0"
;;
'sys') api="https://eu.api.soyoustart.com/1.0"
'sys') # Europe
api="https://eu.api.soyoustart.com/1.0"
# Canada
# api="https://ca.api.soyoustart.com/1.0"
;;
'ksf') api="https://eu.api.kimsufi.com/1.0"
'ksf') # Europe
api="https://eu.api.kimsufi.com/1.0"
# Canada
# api="https://ca.api.kimsufi.com/1.0"
;;
*)
>&2 echo "Unknown argument $OPTARG in Option $OPTION. Execute script with -h option to get help."; exit 3
Expand Down

0 comments on commit eb7045d

Please sign in to comment.