-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docker: drop RPC flag and add REST API flags
Related to removal of RPC API support in: waku-org/nwaku#2416 Signed-off-by: Jakub Sokołowski <[email protected]>
- Loading branch information
Showing
8 changed files
with
61 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/usr/bin/env bash | ||
# vim: set ft=sh: | ||
|
||
TIMEOUT="${TIMEOUT:-5}" | ||
URL="http://localhost:{{ nim_waku_rest_port }}/" | ||
|
||
# List known useful endpoints when called without arguments. | ||
read -r -d '' ENDPOINTS << EOF | ||
/health | ||
/debug/v1/info | ||
/debug/v1/version | ||
/admin/v1/peers | ||
EOF | ||
if [[ $# == 0 ]]; then | ||
echo "${ENDPOINTS}" | fzf \ | ||
--preview='{{ nim_waku_cont_vol }}/api.sh ${1}' \ | ||
--preview-window=bottom,22 | ||
exit 0 | ||
elif [[ $# > 1 ]]; then | ||
echo "Too many arguments!" >&2 | ||
exit 1 | ||
fi | ||
ENDPOINT="${1}" | ||
|
||
# The jq script checks if error exists and adjusts exit code. | ||
curl --silent --max-time "${TIMEOUT}" --show-error --fail-with-body \ | ||
"${URL}${ENDPOINT}" | jq |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.