Skip to content

Commit

Permalink
Update readme (#476)
Browse files Browse the repository at this point in the history
* Update README symlink

* Update README
  • Loading branch information
shanev authored Jul 7, 2021
1 parent d1684b4 commit 62de222
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 87 deletions.
2 changes: 1 addition & 1 deletion README.md
101 changes: 15 additions & 86 deletions cygnusx-1/README.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,10 @@
# Stargaze Cygnus X-1 Testnet Instructions

## TLDR

Block explorer: [https://explorer.cygnusx-1.publicawesome.dev/](https://explorer.cygnusx-1.publicawesome.dev/)

Binaries: [v0.6.0](https://github.com/public-awesome/stargaze/releases/tag/v0.6.0)

Genesis file: [genesis.json](https://github.com/public-awesome/networks/releases/download/cygnusx-1/genesis.json)

Seeds: `c36b75183e4047fb788dcc526e751439a6fda1f0@seed.cygnusx-1.publicawesome.dev:36656`

Peers: [peers](https://www.notion.so/Stargaze-Bellatrix-Testnet-Seeds-Peers-3f0cd9e7c76e49c0859778690f514d5c)

## Challenges

- [Phase-1 Challenge 1](https://github.com/public-awesome/networks/blob/master/cygnusx-1/challenge-1/README.md)

## Minimum hardware requirements

- 2GB RAM
- 25GB of disk space
- 1.4 GHz CPU
- 2x CPUs
- 4GB RAM
- 50GB+ of disk space

## Software requirements

Expand Down Expand Up @@ -57,7 +41,6 @@ Requires [Go version v1.15+](https://golang.org/doc/install).
> git clone https://github.com/public-awesome/stargaze && cd stargaze
> git fetch origin --tags
> git checkout v0.6.0
> FAUCET_ENABLED=true make install
```

#### Verify installation
Expand All @@ -68,7 +51,7 @@ To verify if the installation was successful, execute the following command:
> starsd version --long
```

It will display the version of starsd currently installed:
It will display the version of `starsd` currently installed:

```sh
name: stargaze
Expand All @@ -79,13 +62,9 @@ build_tags: netgo,faucet
go: go version go1.15.8 linux/amd64
```

NOTE: Make sure `build_tags` includes "faucet", which is required for testnet.

## Setup validator node

If you are looking to join the testnet post genesis time (_MAR 23 2021 1600 UTC_), skip to [Create Testnet Validator](#create-testnet-validator)

Below are the instructions to generate & submit your genesis transaction
Below are the instructions to generate and submit your genesis transaction.

### Generate genesis transaction (gentx)

Expand All @@ -103,16 +82,16 @@ Below are the instructions to generate & submit your genesis transaction
```

3. Add your account to your local genesis file with a given amount and the key you
just created. Use only `100000000ustarx`, other amounts will be ignored. STARX is testnet STAR.
just created. Use only `1000000000000ustarx`, other amounts will be ignored.

```sh
> starsd add-genesis-account $(starsd keys show <key-name> -a) 100000000ustarx
> starsd add-genesis-account $(starsd keys show <key-name> -a) 1000000000000ustarx
```

4. Create the gentx

```sh
> starsd gentx <key-name> 90000000ustarx --chain-id=cygnusx-1
> starsd gentx <key-name> 500000000000ustarx --chain-id=cygnusx-1
```

If all goes well, you will see a message similar to the following:
Expand All @@ -123,12 +102,6 @@ Below are the instructions to generate & submit your genesis transaction

### Submit genesis transaction

> NOTE: To prevent malicious validators, and to ensure a fair and decentralized launch, the following rules will be enforced:
>
> 1. Github accounts must be at least 6 months old and have history; accounts with little activity may not be accepted.
> 2. Only one gentx per Github account is allowed
> 3. We reserve the right to exercise our best judgement to protect the network against Sybil attacks. Preference will be given to validators with a proven track record of validating for other networks.
Submit your gentx in a PR [here](https://github.com/public-awesome/networks)

- Fork [the networks repo](https://github.com/public-awesome/networks) into your Github account
Expand All @@ -149,10 +122,6 @@ Submit your gentx in a PR [here](https://github.com/public-awesome/networks)
- Commit and push to your repo
- Create a PR onto https://github.com/public-awesome/networks

### Start your validator node

Once after the genesis is released (_MAR 22 2021 1600 UTC_), follow the instructions below to start your validator node.

#### Genesis & seeds

Fetch `genesis.json` into `starsd`'s `config` directory.
Expand All @@ -177,8 +146,8 @@ Add seed nodes in `config.toml`.
Find the following section and add the seed nodes.

```sh
# Comma separated list of seed nodes to connect to
seeds = "c36b75183e4047fb788dcc526e751439a6fda1f0@seed.cygnusx-1.publicawesome.dev:36656"
# [TBD] Comma separated list of seed nodes to connect to
seeds = ""
```

```sh
Expand All @@ -188,14 +157,14 @@ persistent_peers = ""

#### Set validator gas fees

You can set the minimum gas prices for transactions to be accepted into your node's mempool. This sets a lower bound on gas prices, preventing spam. Stargaze can accept gas in _any_ currency. To accept both ATOM and STARX for example, set `minimum-gas-prices` in `app.toml`.
You can set the minimum gas prices for transactions to be accepted into your node's mempool. This sets a lower bound on gas prices, preventing spam. Stargaze will launch accepting 0 gas fees to bootstrap the network.

```sh
> vi $HOME/.starsd/config/app.toml
```

```sh
minimum-gas-prices = "0.025ustarx"
minimum-gas-prices = ""
```

#### Start node automatically (Linux only)
Expand All @@ -206,16 +175,16 @@ Create a `systemd` service
> sudo vi /etc/systemd/system/starsd.service
```

Copy and paste the following and update `<your_username>` and `<go_workspace>`:
Copy and paste the following and update `<user>` and `<GO_PATH>`:

```sh
[Unit]
Description=starsd
After=network-online.target

[Service]
User=<your_username>
ExecStart=/home/<your_username>/<go_workspace>/bin/starsd start
User=<user>
ExecStart=<GO_PATH>/bin/starsd start
Restart=always
RestartSec=3
LimitNOFILE=4096
Expand All @@ -224,8 +193,6 @@ LimitNOFILE=4096
WantedBy=multi-user.target
```

**This assumes `$HOME/go_workspace` to be your Go workspace. Your actual workspace directory may vary.**

```sh
> sudo systemctl enable starsd
> sudo systemctl start starsd
Expand All @@ -242,41 +209,3 @@ Check logs
```sh
> journalctl -u starsd -f
```

## Create testnet validator

This section applies to those who are looking to join the testnet post genesis.

1. Init Chain and start your node

```sh
> starsd init <moniker-name> --chain-id=cygnusx-1 --stake-denom=ustarx
```

After that, please follow all the instructions from [Start your validator node](#start-your-validator-node)

2. Create a local key pair

```sh
> starsd keys add <key-name>
> starsd keys show <key-name> -a
```

3. Create validator

```sh
$ starsd tx staking create-validator \
--amount 250000000000ustarx \
--commission-max-change-rate "0.1" \
--commission-max-rate "0.20" \
--commission-rate "0.1" \
--min-self-delegation "1" \
--details "validators write bios too" \
--pubkey=$(starsd tendermint show-validator) \
--moniker <your_moniker> \
--chain-id cygnusx-1 \
--gas-prices 0.025ustarx \
--from <key-name>
```

4. Request tokens from the [Stargaze Discord #validator channel](https://discord.gg/QeJWCrE) if you need more.

0 comments on commit 62de222

Please sign in to comment.