mirror of
https://github.com/fluencelabs/registry.git
synced 2025-04-25 10:12:13 +00:00
add script to deploy and to add aliases
This commit is contained in:
parent
1a2c68aca1
commit
cebe300728
7
alias.air
Normal file
7
alias.air
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
(xor
|
||||||
|
(seq
|
||||||
|
(call relay ("srv" "add_alias") [alias service] result)
|
||||||
|
(call %init_peer_id% (returnService "run") [result])
|
||||||
|
)
|
||||||
|
(call %init_peer_id% (returnService "run") [%last_error%])
|
||||||
|
)
|
11
deploy.sh
Normal file
11
deploy.sh
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
IFS=$'\n' read -rd '' -a node_list <<<"$(fldist env --env krasnodar)"
|
||||||
|
|
||||||
|
for i in "${node_list[@]}"
|
||||||
|
do
|
||||||
|
IFS=$'\n' read -rd '' -a out <<<"$(fldist --node-addr $i new_service --ms artifacts/sqlite3.wasm:sqlite3_cfg.json artifacts/aqua-dht.wasm:aqua-dht_cfg.json -n aqua-dht --seed 4VzczoMt73wVenKyJhZ6MySsT8jCy1MXKC6kD8vvgDoK -v)"
|
||||||
|
service_id=$(cut -d ":" -f2- <<< "${out[${#out[@]}-2]}" | xargs)
|
||||||
|
echo $service_id deployed
|
||||||
|
fldist --node-addr $i --seed 4VzczoMt73wVenKyJhZ6MySsT8jCy1MXKC6kD8vvgDoK -v run_air -p alias.air -d "{\"service\": \"$service_id\", \"alias\": \"aqua-dht\"}"
|
||||||
|
done
|
Loading…
x
Reference in New Issue
Block a user