Make web3 provider URL configurable; default to infura #9
Reference in New Issue
Block a user
Delete Branch "configurable-provider"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This uses infura (kovan network) as the default web3 provider URL.
We're using our own dev chain now, so using a 3rd party node by default doesn't make much sense to me.
@@ -41,0 +39,4 @@if (process.env.KREDITS_CONTRACT_ADDR) {ENV.contractMetadata['Kredits'] = { address: process.env.KREDITS_CONTRACT_ADDR };}if (process.env.TOKEN_CONTRACT_ADDR) {We use config files in Ember, so it's clear what is being built. Otherwise you end up with a build that completely hides where its config comes from.
Edit: loldidntread. Anyway, we shouldn't add even more env vars and use normal config options for all of them (as well as the addresses from the contracts module).
@@ -41,0 +39,4 @@if (process.env.KREDITS_CONTRACT_ADDR) {ENV.contractMetadata['Kredits'] = { address: process.env.KREDITS_CONTRACT_ADDR };}if (process.env.TOKEN_CONTRACT_ADDR) {I see. what is the best option to set local dev configuration options? (like for example here the contract addresses?)
@@ -41,0 +39,4 @@if (process.env.KREDITS_CONTRACT_ADDR) {ENV.contractMetadata['Kredits'] = { address: process.env.KREDITS_CONTRACT_ADDR };}if (process.env.TOKEN_CONTRACT_ADDR) {I guess this works for now. Would be nice to use environment-specific configs soon.
@@ -41,0 +39,4 @@if (process.env.KREDITS_CONTRACT_ADDR) {ENV.contractMetadata['Kredits'] = { address: process.env.KREDITS_CONTRACT_ADDR };}if (process.env.TOKEN_CONTRACT_ADDR) {yep. I only see those used for configs that must not be in the repo / only for the current machine.
so defaulting to parity.kosmos.org:8545 and this PR is ok?
@@ -41,0 +39,4 @@if (process.env.KREDITS_CONTRACT_ADDR) {ENV.contractMetadata['Kredits'] = { address: process.env.KREDITS_CONTRACT_ADDR };}if (process.env.TOKEN_CONTRACT_ADDR) {Yer.
rethought this PR. actually I'd like to have it configurable per session.
Does it make sense to check localstorage before using the global config?