Skip to content

Commit

Permalink
Fabo/voyager web (#1804)
Browse files Browse the repository at this point in the history
* removed several electron references
* basic sign in working
* added scripts for backend
* fixed missing tmdataloading on tabparameters
* update to latest tendermint lib
* added ssl cert creation readme
* correct wait for connection on app start
* updated webpack dev server 
* import genesis at build time
* fixed tmfield
* added networks to dev server
* fixed pageview
* fixed bug on LiProposal
* increased timeout for waiting for blocks to proof connection
* refactor keystore
* made analytics not global
* cleanup package scripts and deps
* fixes signin feedback
* enable transactions in prod mode
* removed config.toml
* removed browserified dependencies
* tests refactored
* remove build test
* override write to clipboard in test
* override copy to clipboard in test for btncopy
* fixed app menu test
* add gos genesis
* added proxy
* removed network config folder getter script
* added tests for keystore and wallet
* added salt
* remove e2e tests for now
* removed dependency ref
* reenable console error safe guard
* fixed snapshots
* fixed session import
* switched proxy
* add new generate_only logic
* better start scripts
* added skip rebuild
* fixed send snapshot
* moved to latest SDK
* make not creating the nodes the default
* working gen and post
* remove mnemonic from wallet
* stripped console log
* fixed lcdClient + tests
* fixed send tests
* added send tests
* remove caddy binary
* reenable error handlers
* removed navigator mock
* fix session sign up
* refactored waiting for node
* made default gas a config value
* fixed gas config
* catch wrong password
* fixed tmformmsg
* added coverage for getKey
* ignore some lines from coverage
* increase coverage user.js
* refactored request postprocessors
* ignore coverage for network.js
* added test for main
* ignore coverage in google analytics script
* disable e2e tests for now
* fixed gas for proposal generation
* Switch to photinos
* fix outputs and add verbose mode
* removed display of secondary accounts
  • Loading branch information
faboweb authored and sabau committed Jan 16, 2019
1 parent e9a5858 commit 0e11960
Show file tree
Hide file tree
Showing 131 changed files with 5,495 additions and 12,959 deletions.
14 changes: 7 additions & 7 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -181,19 +181,19 @@ workflows:
branches:
ignore: release

- testE2e:
requires:
- buildGaia
filters:
branches:
ignore: release
# - testE2e:
# requires:
# - buildGaia
# filters:
# branches:
# ignore: release

- publish:
requires:
- changelogUpdated
- buildGaia
- testUnit
- testE2e
# - testE2e
filters:
branches:
only: develop
Expand Down
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ testArtifacts/*
app/networks/local-testnet/*
docs/cosmos-voyager
.idea/*
server_dev.key
server_dev.crt
*.crt
*.key
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- [\#1660](https://github.com/cosmos/voyager/issues/1660) Add parameters and pool to store @fedekunze
- [\#1739](https://github.com/cosmos/voyager/issues/1739) Init jsDoc into project @sabau
- [\#1674](https://github.com/cosmos/voyager/issues/1674) Add PageProfile component with shared styles for validator and proposal profiles @jbibla
- [\#1804](https://github.com/cosmos/voyager/issues/1804) Moved Voyager to the web @faboweb

### Changed

Expand Down
13 changes: 13 additions & 0 deletions Caddyfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
localhost:8080 {
cors

header / {
Access-Control-Allow-Origin "*"
Access-Control-Allow-Methods "OPTIONS, HEAD, GET, POST, PUT, DELETE"
Access-Control-Allow-Headers "*"
}

proxy / https://localhost:9070/ {
insecure_skip_verify
}
}
45 changes: 40 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ cd voyager
yarn install
```

---

## Voyager Development

### Gaia (Cosmos SDK)

Since Voyager runs on top of the Cosmos Hub blockchain, we also need to install Gaia (the Cosmos Hub application) and download the supported testnets.
Expand All @@ -63,7 +67,13 @@ To connect to a testnet, Voyager needs the configuration files of those networks
yarn build:testnets
```

## Voyager Development
### Caddy Proxy

Currently we need a proxy to enable easy local development. We use [Caddy](https://caddyserver.com). To download run:

```bash
curl https://getcaddy.com | bash -s personal http.cors
```

### Active testnets

Expand All @@ -73,15 +83,40 @@ To run Voyager on the default testnet (if active):
yarn start
```

To run Voyager on a specific testnet you can use the following command. Click [here](https://github.com/cosmos/testnets) for a complete list of the supported official and community testnets.
## Local testnet

Sometimes you may want to run a local node, i.e. in the case there is no available network. To do so first [Build Gaia](#gaia-cosmos-sdk), then use our automatic script or the manual process to set up your node.

### Generate SSL certificates

If you want to have a predictable environment for Voyager please generate some ssl certificates:

```bash
yarn start <network_name>
openssl req -x509 -nodes -days 365 -newkey rsa:2048 \
-keyout server_dev.key -out server_dev.crt \
-subj "/C=US/ST=CA/L=Irvine/O=Acme Inc./CN=localhost" \
-reqexts v3_req -reqexts SAN -extensions SAN \
-config \
<(echo -e '
[req]\n
distinguished_name=req_distinguished_name\n
[req_distinguished_name]\n
[SAN]\n
subjectKeyIdentifier=hash\n
authorityKeyIdentifier=keyid:always,issuer:always\n
basicConstraints=CA:TRUE\n
subjectAltName=@alt_names
[alt_names]
DNS.1 = localhost
')
```

## Local testnet
Afterwards you can use:

Sometimes you may want to run a local node, i.e. in the case there is no available network. To do so first [Build Gaia](#gaia-cosmos-sdk), then use our automatic script or the manual process to set up your node.
```bash
yarn backend:fixed-https
yarn frontend:fixed-https
```

### Build

Expand Down
21 changes: 0 additions & 21 deletions app/config.toml

This file was deleted.

5 changes: 1 addition & 4 deletions app/index.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,10 @@
<meta charset="utf-8">
<title>Cosmos Voyager</title>
<% if (htmlWebpackPlugin.options.appModules) { %>
<!-- Add `app/node_modules` to global paths so `require` works properly in development -->
<script>
require('module').globalPaths.push('<%= htmlWebpackPlugin.options.appModules.replace(/\\/g, '\\\\') %>')
</script>
<% } %>

<body style="background: #15182d">
<script async src='https://www.google-analytics.com/analytics.js'></script>
<div id="app" style="background: #15182d"></div>
</body>

Expand Down
11 changes: 0 additions & 11 deletions app/src/config.js

This file was deleted.

11 changes: 11 additions & 0 deletions app/src/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"name": "Cosmos Voyager",
"default_network": "game_of_stakes_3",
"node_lcd": "http://localhost:8080",
"node_rpc": "http://localhost:26657",
"google_analytics_uid": "UA-51029217-3",
"sentry_dsn": "https://4dee9f70a7d94cc0959a265c45902d84:cbf160384aab4cdeafbe9a08dee3b961@sentry.io/288169",
"node_halted_timeout": 120000,
"block_timeout": 10000,
"default_gas": 500000
}
171 changes: 0 additions & 171 deletions app/src/main/addressbook.js

This file was deleted.

29 changes: 0 additions & 29 deletions app/src/main/index.dev.js

This file was deleted.

Loading

0 comments on commit 0e11960

Please sign in to comment.