-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cosmos-simapp example, support for sdk
v0.47.*
, upgrade chart to `0…
….1.35` (#123) * initial commit with cosmos-simapp example * update genesis setup bash script to check for genesis subcommand, add simapp to defaultChain in values.yaml * add devnet 20, update values * fix hermes relayer, move faucet transfer tokens to post start hook in validator, fix scripts * create devnet with 30 validators * Add resources for build chain test for faster initialization
- Loading branch information
Showing
16 changed files
with
335 additions
and
25 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
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,70 @@ | ||
NAME = cosmos-simapp-multi | ||
FILE = configs/local.yaml | ||
|
||
HELM_REPO = starship | ||
HELM_CHART = devnet | ||
HELM_VERSION = v0.1.34 | ||
|
||
############################################################################### | ||
### All commands ### | ||
############################################################################### | ||
|
||
.PHONY: setup | ||
setup: setup-deps setup-helm setup-kind | ||
|
||
.PHONY: stop | ||
stop: stop-forward delete | ||
|
||
.PHONY: clean | ||
clean: stop clean-kind | ||
|
||
############################################################################### | ||
### Dependency check ### | ||
############################################################################### | ||
|
||
.PHONY: check | ||
setup-deps: | ||
bash $(CURDIR)/scripts/dev-setup.sh | ||
|
||
############################################################################### | ||
### Helm Charts ### | ||
############################################################################### | ||
|
||
setup-helm: | ||
helm repo add $(HELM_REPO) https://cosmology-tech.github.io/starship/ | ||
helm repo update | ||
helm search repo $(HELM_REPO)/$(HELM_CHART) --version $(HELM_VERSION) | ||
|
||
install: | ||
helm install -f $(FILE) $(NAME) $(HELM_REPO)/$(HELM_CHART) --version $(HELM_VERSION) | ||
|
||
install-base: | ||
helm install -f $(FILE) $(NAME) ../../charts/$(HELM_CHART) | ||
|
||
delete: | ||
-helm delete $(NAME) | ||
|
||
############################################################################### | ||
### Port forward ### | ||
############################################################################### | ||
|
||
.PHONY: port-forward | ||
port-forward: | ||
bash $(CURDIR)/scripts/port-forward.sh --config=$(FILE) | ||
|
||
.PHONY: stop-forward | ||
stop-forward: | ||
-pkill -f "port-forward" | ||
|
||
############################################################################### | ||
### Local Kind Setup ### | ||
############################################################################### | ||
KIND_CLUSTER=starship | ||
|
||
.PHONY: setup-kind | ||
setup-kind: | ||
kind create cluster --name $(KIND_CLUSTER) | ||
|
||
.PHONY: clean-kind | ||
clean-kind: | ||
kind delete cluster --name $(KIND_CLUSTER) |
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,17 @@ | ||
chains: | ||
- name: simapp | ||
type: simapp | ||
numValidators: 20 | ||
ports: | ||
rest: 1317 | ||
rpc: 26657 | ||
|
||
registry: | ||
enabled: true | ||
ports: | ||
rest: 8081 | ||
|
||
explorer: | ||
enabled: true | ||
ports: | ||
rest: 8080 |
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,35 @@ | ||
chains: | ||
- name: simapp | ||
type: simapp | ||
numValidators: 30 | ||
ports: | ||
rest: 1317 | ||
rpc: 26657 | ||
|
||
registry: | ||
enabled: true | ||
ports: | ||
rest: 8081 | ||
|
||
explorer: | ||
enabled: true | ||
ports: | ||
rest: 8080 | ||
|
||
exposer: | ||
resources: | ||
limits: | ||
cpu: "0.1" | ||
memory: "100M" | ||
requests: | ||
cpu: "0.1" | ||
memory: "100M" | ||
|
||
faucet: | ||
resources: | ||
limits: | ||
cpu: "0.4" | ||
memory: "500M" | ||
requests: | ||
cpu: "0.4" | ||
memory: "500M" |
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,24 @@ | ||
chains: | ||
- name: simapp | ||
type: simapp | ||
numValidators: 2 | ||
ports: | ||
rest: 1317 | ||
rpc: 26657 | ||
resources: | ||
limits: | ||
cpu: "1" | ||
memory: "2Gi" | ||
requests: | ||
cpu: "1" | ||
memory: "2Gi" | ||
|
||
registry: | ||
enabled: true | ||
ports: | ||
rest: 8081 | ||
|
||
explorer: | ||
enabled: true | ||
ports: | ||
rest: 8080 |
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,65 @@ | ||
#!/bin/bash | ||
|
||
set -euo pipefail | ||
|
||
function color() { | ||
local color=$1 | ||
shift | ||
local black=30 red=31 green=32 yellow=33 blue=34 magenta=35 cyan=36 white=37 | ||
local color_code=${!color:-$green} | ||
printf "\033[%sm%s\033[0m\n" "$color_code" "$*" | ||
} | ||
|
||
# Define a function to install a binary on macOS | ||
install_macos() { | ||
case $1 in | ||
kubectl) brew install kubectl ;; | ||
helm) brew install helm ;; | ||
yq) brew install yq ;; | ||
kind) brew install kind ;; | ||
esac | ||
} | ||
|
||
# Define a function to install a binary on Linux | ||
install_linux() { | ||
color green "Installing $1 at ~/.local/bin, please add it to PATH" | ||
mkdir -p ~/.local/bin | ||
case $1 in | ||
kubectl) curl -Lks "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" > ~/.local/bin/kubectl && chmod +x ~/.local/bin/kubectl ;; | ||
helm) curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash ;; | ||
yq) curl -Lks "https://github.com/mikefarah/yq/releases/download/v4.33.3/yq_linux_amd64" > ~/.local/bin/yq && chmod +x ~/.local/bin/yq ;; | ||
kind) curl -Lks https://kind.sigs.k8s.io/dl/v0.18.1/kind-linux-amd64 > ~/.local/bin/kind && chmod +x ~/.local/bin/kind ;; | ||
esac | ||
} | ||
|
||
# Define a function to install a binary | ||
install_binary() { | ||
if [[ $(uname -s) == "Darwin" ]]; then | ||
install_macos $1 | ||
else | ||
install_linux $1 | ||
fi | ||
} | ||
|
||
# Define a function to check for the presence of a binary | ||
check_binary() { | ||
if ! command -v $1 &> /dev/null | ||
then | ||
echo "$1 is not installed" | ||
install_binary $1 | ||
if ! command -v $1 &> /dev/null | ||
then | ||
color red "Installation of $1 failed, exiting..." | ||
color red "Please install $1 manually, then run me again to verify the installation" | ||
exit 1 | ||
fi | ||
fi | ||
} | ||
|
||
# Check the binaries | ||
check_binary kubectl | ||
check_binary helm | ||
check_binary yq | ||
check_binary kind | ||
|
||
color green "All binaries are installed" |
Oops, something went wrong.