diff --git a/README.md b/README.md index a7cfc1cf80..7d94cc85f9 100644 --- a/README.md +++ b/README.md @@ -33,6 +33,7 @@ Umee will allow a multitude of decentralized debt products. - [Recommended Database Backend](#recommended-database-backend) - [Swagger](#swagger) - [Cosmovisor](#cosmovisor) +- [Validators](#validators) - [Liquidators](#liquidators) ## Releases @@ -83,7 +84,7 @@ You don't need to do anything if you are using our Docker image. Public: - [umee-1](networks/umee-1) (mainnet) -- canon-3 (testnet) +- canon-4 (testnet) ## Build @@ -192,6 +193,10 @@ $ wget https://raw.githubusercontent.com/CosmWasm/wasmvm/v1.5.0/internal/api/lib - To use `cosmovisor` for starting `umeed` process, instead of calling `umeed start`, use `cosmovisor run start [umeed flags]` +## Validators + +Please follow [Validator Instructions](./VALIDATOR.md) for setting up a validator node. + ## Liquidators A guide to running liquidations on Umee can be found [here](./x/leverage/LIQUIDATION.md) diff --git a/VALIDATOR.md b/VALIDATOR.md new file mode 100644 index 0000000000..76c106d0e4 --- /dev/null +++ b/VALIDATOR.md @@ -0,0 +1,85 @@ +# Validator Notes + +This document describes a process of joining a testnet or a mainnet as a validator. + +## Umeeversity + +Full documentation is hosted at [learning.ux.xyz](https://learning.ux.xyz). However it may not be up to date. + +## Getting a Binary + +To run a validator you need 2 binaries: `umeed` and `price-feeder`. + +### Umeed + +You can get a binary by: + +1. [Build](./README.md#build) yourself and follow the latest [Release Notes](./RELEASE_NOTES.md). + If you build the binary on a different OS than your validator OS, then you need to copy `libwasmvm`: + + ```sh + scp $GOPATH/pkg/mod/github.com/!cosm!wasm/wasmvm@/internal/api/libwasmvm.$(uname -m).so running_os:/ + ``` + + NOTE: use the correct `wasmvm` version, according to the latest [Release Notes](./RELEASE_NOTES.md) or the [compatibility matrix](./README.md#release-compatibility-matrix). + +2. Download latest [binary build](https://github.com/umee-network/umee/releases). The build is compatible with the latest Ubuntu LTS x86-64. You MUST also copy the `libwasmvm` (see note in 1. about libwasmvm version): + + ```sh + wget https://raw.githubusercontent.com/CosmWasm/wasmvm//internal/api/libwasmvm.$(uname -m).so -O /lib/libwasmvm.$(uname -m).so + ``` + +3. Use our released docker [umeed container](https://github.com/umee-network/umee/pkgs/container/umeed). + +To test if the `libwasm` is linked correctly, run `umeed version`. + +### Price Feeder + +We are using Ojo Price Feeder. Please follow the [instructions](https://github.com/ojo-network/price-feeder/blob/umee/README.md). Make sure you use the latest release with the `umee/` prefix (eg: `umee/v2.4.0`). +NOTE: for self building and configuration examples you MUST use the [umee branch](https://github.com/ojo-network/price-feeder/tree/umee). + +- Copy the [`price-feeder.toml`](https://github.com/ojo-network/price-feeder/blob/umee/price-feeder.example.toml). +- For the provider config you can use our latest [umee-provider-config directory](https://github.com/ojo-network/price-feeder/tree/umee/umee-provider-config) as is. + +## Running a node + +1. Update the `app.toml` , `client.toml` and `config.toml` based on your preference. You MUST set non zero min gas prices in `app.toml`. Query `umeed q ugov min-gas-price` to see the what is the minimum acceptable value: + + ```toml + # your app.toml file + minimum-gas-prices = "0.1uumee" + ``` + +## Joining the network + +Before joining the mainnet you should join a testnet! + +### Testnet + +1. Make sure your are able to run `umeed` and price feeder locally. +2. Join the [Discord server](https://discord.gg/4ZJAFvg9). Make sure you are in the Testnet group. +3. Follow the state sync [canon-4 instructions](https://mzonder.notion.site/UMEE-Start-from-STATE-SYNC-canon-4-f485563a089a436d9d1fe98f54af8737). Make sure you use the [latest](https://github.com/umee-network/umee/releases/) version. +4. You can use the following peers in your `config.toml`: + + ```toml + persistent_peers = "ee7d691781717cbd1bf6f965dc45aad19c7af05f@canon-4.network.umee.cc:10000,dfd1d83b668ff2e59dc1d601a4990d1bd95044ba@canon-4.network.umee.cc:10001" + ``` + +5. Using discord, ping one of the UX Team members to send you testnet `uumee`. +6. Once your validator is setup (and you did self delegation), ping again UX Team members and send your validator address. We will do a delegation. +7. Make sure your Price Feeder is running correctly. If your [testnet window misses](https://canon.price-feeder.com/) are above 50% then something is wrong. Look for a help on Discord. + +Here are our testnet public endpoints: + +- [Explorer](https://explorer.network.umee.cc/canon-4) +- [Web GRPC](https://canon-4.api.network.umee.cc) +- [RPC](https://canon-4.rpc.network.umee.cc) + +### Mainnet + +1. Make sure you firstly tested your setup on Testnet. +2. Use one of the community [snapshots & instructions](https://github.com/obajay/StateSync-snapshots/tree/main/Projects/Umee). +3. Buy `uumee` to self delegate. +4. Make sure your Price Feeder is running correctly. If your [mainnet window misses](https://price-feeder.com/) are above 50% then something is wrong. Look for a help on Discord. + +We recommend to use [Cosmovisor](./README.md#cosmovisor) for mainnet nodes. diff --git a/go.mod b/go.mod index 2b59391669..2b3c58703f 100644 --- a/go.mod +++ b/go.mod @@ -10,7 +10,7 @@ require ( github.com/CosmWasm/wasmd v0.43.0 github.com/CosmWasm/wasmvm v1.5.2 github.com/cometbft/cometbft v0.37.4 - github.com/cometbft/cometbft-db v0.9.1 + github.com/cometbft/cometbft-db v0.10.0 github.com/cosmos/cosmos-proto v1.0.0-beta.2 // NOTE: v1.0.0-beta.2+ is not compatible with sdk v0.47 github.com/cosmos/cosmos-sdk v0.47.8 github.com/cosmos/go-bip39 v1.0.0 @@ -63,6 +63,7 @@ require ( github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 // indirect github.com/BurntSushi/toml v1.3.2 // indirect github.com/ChainSafe/go-schnorrkel v1.0.0 // indirect + github.com/DataDog/zstd v1.5.0 // indirect github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 // indirect github.com/GaijinEntertainment/go-exhaustruct/v3 v3.1.0 // indirect github.com/Masterminds/semver v1.5.0 // indirect @@ -99,6 +100,7 @@ require ( github.com/cockroachdb/apd/v2 v2.0.2 // indirect github.com/cockroachdb/errors v1.10.0 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect + github.com/cockroachdb/pebble v1.0.0 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/coinbase/rosetta-sdk-go v0.7.9 // indirect github.com/confio/ics23/go v0.9.0 // indirect @@ -224,7 +226,7 @@ require ( github.com/leonklingele/grouper v1.1.1 // indirect github.com/lib/pq v1.10.9 // indirect github.com/libp2p/go-buffer-pool v0.1.0 // indirect - github.com/linxGnu/grocksdb v1.8.6 // indirect + github.com/linxGnu/grocksdb v1.8.11 // indirect github.com/lufeee/execinquery v1.2.1 // indirect github.com/macabu/inamedparam v0.1.2 // indirect github.com/magiconair/properties v1.8.7 // indirect diff --git a/go.sum b/go.sum index 54f5e98b71..40947e856e 100644 --- a/go.sum +++ b/go.sum @@ -241,6 +241,7 @@ github.com/CosmWasm/wasmvm v1.5.2 h1:+pKB1Mz9GZVt1vadxB+EDdD1FOz3dMNjIKq/58/lrag github.com/CosmWasm/wasmvm v1.5.2/go.mod h1:Q0bSEtlktzh7W2hhEaifrFp1Erx11ckQZmjq8FLCyys= github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= +github.com/DataDog/zstd v1.5.0 h1:+K/VEwIAaPcHiMtQvpLD4lqW7f0Gk3xdYZmI1hD+CXo= github.com/DataDog/zstd v1.5.0/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 h1:sHglBQTwgx+rWPdisA5ynNEsoARbiCBOyGcJM4/OzsM= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24/go.mod h1:4UJr5HIiMZrwgkSPdsjy2uOQExX/WEILpIrO9UPGuXs= @@ -429,10 +430,14 @@ github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWH github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E= github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOGr0B9pvN3Gw= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= +github.com/cockroachdb/datadriven v1.0.3-0.20230801171734-e384cf455877 h1:1MLK4YpFtIEo3ZtMA5C795Wtv5VuUnrXX7mQG+aHg6o= +github.com/cockroachdb/datadriven v1.0.3-0.20230801171734-e384cf455877/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/errors v1.10.0 h1:lfxS8zZz1+OjtV4MtNWgboi/W5tyLEB6VQZBXN+0VUU= github.com/cockroachdb/errors v1.10.0/go.mod h1:lknhIsEVQ9Ss/qKDBQS/UqFSvPQjOwNq2qyKAxtHRqE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/pebble v1.0.0 h1:WZWlV/s78glZbY2ylUITDOWSVBD3cLjcWPLRPFbHNYg= +github.com/cockroachdb/pebble v1.0.0/go.mod h1:bynZ3gvVyhlvjLI7PT6dmZ7g76xzJ7HpxfjgkzCGz6s= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= @@ -441,8 +446,8 @@ github.com/coinbase/rosetta-sdk-go v0.7.9 h1:lqllBjMnazTjIqYrOGv8h8jxjg9+hJazIGZ github.com/coinbase/rosetta-sdk-go v0.7.9/go.mod h1:0/knutI7XGVqXmmH4OQD8OckFrbQ8yMsUZTG7FXCR2M= github.com/cometbft/cometbft v0.37.4 h1:xyvvEqlyfK8MgNIIKVJaMsuIp03wxOcFmVkT26+Ikpg= github.com/cometbft/cometbft v0.37.4/go.mod h1:Cmg5Hp4sNpapm7j+x0xRyt2g0juQfmB752ous+pA0G8= -github.com/cometbft/cometbft-db v0.9.1 h1:MIhVX5ja5bXNHF8EYrThkG9F7r9kSfv8BX4LWaxWJ4M= -github.com/cometbft/cometbft-db v0.9.1/go.mod h1:iliyWaoV0mRwBJoizElCwwRA9Tf7jZJOURcRZF9m60U= +github.com/cometbft/cometbft-db v0.10.0 h1:VMBQh88zXn64jXVvj39tlu/IgsGR84T7ImjS523DCiU= +github.com/cometbft/cometbft-db v0.10.0/go.mod h1:7RR7NRv99j7keWJ5IkE9iZibUTKYdtepXTp7Ra0FxKk= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= github.com/consensys/bavard v0.1.8-0.20210406032232-f3452dc9b572/go.mod h1:Bpd0/3mZuaj6Sj+PqrmIquiOKy397AKGThQPaGzNXAQ= @@ -1081,8 +1086,8 @@ github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6 github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= -github.com/linxGnu/grocksdb v1.8.6 h1:O7I6SIGPrypf3f/gmrrLUBQDKfO8uOoYdWf4gLS06tc= -github.com/linxGnu/grocksdb v1.8.6/go.mod h1:xZCIb5Muw+nhbDK4Y5UJuOrin5MceOuiXkVUR7vp4WY= +github.com/linxGnu/grocksdb v1.8.11 h1:BGol9e5gB1BrsTvOxloC88pe70TCqgrfLNwkyWW0kD8= +github.com/linxGnu/grocksdb v1.8.11/go.mod h1:xZCIb5Muw+nhbDK4Y5UJuOrin5MceOuiXkVUR7vp4WY= github.com/lucasjones/reggen v0.0.0-20180717132126-cdb49ff09d77/go.mod h1:5ELEyG+X8f+meRWHuqUOewBOhvHkl7M76pdGEansxW4= github.com/lufeee/execinquery v1.2.1 h1:hf0Ems4SHcUGBxpGN7Jz78z1ppVkP/837ZlETPCEtOM= github.com/lufeee/execinquery v1.2.1/go.mod h1:EC7DrEKView09ocscGHC+apXMIaorh4xqSxS/dy8SbM=