Browse Source

Merge pull request #311 from mnaamani/rome-testnet-endpoint

set new rome rpc endpoint and update stored acropolis endpoint
Martin 5 years ago
parent
commit
4964616fe4

+ 1 - 1
packages/apps/src/SideBar/index.tsx

@@ -176,7 +176,7 @@ function SideBar ({ className, collapse, handleResize, isCollapsed, toggleMenu,
                 )
             ))}
             <Menu.Divider hidden />
-            <OuterLink url='https://testnet.joystream.org/faucet' title='Free Tokens' />
+            <OuterLink url='https://faucet.joystream.org/' title='Free Tokens' />
             <OuterLink url='https://blog.joystream.org/acropolis-incentives/' title='Earn Monero' />
             <Menu.Divider hidden />
             {

+ 3 - 3
packages/joy-pages/src/md/Privacy.md

@@ -1,7 +1,7 @@
 # Privacy and Cookies
 **Last updated on the 17th of April 2019**
 
-Jsgenesis values your privacy. 
+Jsgenesis values your privacy.
 
 This Privacy Policy ("Privacy Policy") and Cookie Policy ("Cookie Policy") explains how Jsgenesis AS ("Jsgenesis", "Company", "We", "Us", "Our") collect and use data and information when you ("User) use on or any of the Joystream products, developed in the GitHub organization [Joystream](https://github.com/JoyStream). These products (collectively "Software") include, but are not limited to, [all pages under the joystream.org domain](https://www.joystream.org/) ("Website"), the [Joyful node](https://github.com/Joystream/substrate-node-joystream) ("Full Node"), the [Colossus Storage Node](https://github.com/Joystream/storage-node-joystream) ("Storage node"), and the Pioneer User Interface, either [self hosted](https://github.com/Joystream/apps) or [hosted by Us](http://testnet.joystream.org/) ("App").
 
@@ -14,7 +14,7 @@ Relevant to the Privacy Policy and Cookie Policy are the following terms:
 
 
 # Privacy Policy
-**Last updated on the 17th of April 2019**
+**Last updated on the 17th of March 2020**
 
 ## 1. Agreement to the Policy
 By using any of Our Software, the User are accepting this Privacy Policy. If you are acting on behalf of another company or an employer, you must have the rights to act on their behalf. The Privacy Policy is not extended to any of our newsletters, where Users are bound by the [privacy policy](https://mailchimp.com/legal/privacy/) of [Mailchimp](https://mailchimp.com/).
@@ -28,7 +28,7 @@ This Privacy Policy may be changed at the sole discretion of Company. If any mat
 All data written to the Blockchain, is implicitly collected not only by Company, but also anyone else in the world that is running the Full Node locally, or accessed via the App or a third party.
 This includes, but is not limited to, Content hashes, Membership profile, Memo field, and any other way a User can record data on the Blockchain.
 
-When using the [faucet](https://testnet.joystream.org/faucet) ("Faucet") subpage of the Website, Company will record the IP address behind every new request for tokens. This data will be deleted every 14 days.
+When using the [faucet](https://faucet.joystream.org/) ("Faucet") subpage of the Website, Company will record the IP address behind every new request for tokens. This data will be deleted every 14 days.
 
 Company uses [Google Analytics](https://marketingplatform.google.com/about/analytics/), with IP anonymization, to collect statistics on Website and the version of App hosted by us. All customizable data sharing settings are turned off to improve the privacy of Users.
 

+ 8 - 1
packages/joy-settings/src/Settings.ts

@@ -38,7 +38,14 @@ export class Settings implements SettingsStruct {
 
     this._emitter = new EventEmitter();
 
-    this._apiUrl = settings.apiUrl || process.env.WS_URL || ENDPOINT_DEFAULT;
+    // Transition from acropolis - since visitors are coming to the same domain they most likely
+    // have the endpoint url saved in local storage. Replace it with new rome default endpoint.
+    if (settings.apiUrl == 'wss://testnet.joystream.org/acropolis/rpc/') {
+      this._apiUrl = process.env.WS_URL || ENDPOINT_DEFAULT || 'wss://rome-rpc-endpoint.joystream.org:9944/';
+    } else {
+      this._apiUrl = settings.apiUrl || process.env.WS_URL || ENDPOINT_DEFAULT;
+    }
+
     this._ledgerConn = settings.ledgerConn || LEDGER_CONN_DEFAULT;
     this._i18nLang = settings.i18nLang || LANGUAGE_DEFAULT;
     this._icon = settings.icon || ICON_DEFAULT;

+ 6 - 12
packages/joy-settings/src/defaults/endpoints.ts

@@ -5,7 +5,7 @@
 import { Option } from '../types';
 
 // type ChainName = 'alexander' | 'edgeware' | 'edgewareTest' | 'flamingFir' | 'kusama';
-type ChainName = 'joystream_rome_experimental' | 'joystream_rome_final_staging';
+type ChainName = 'rome';
 
 interface ChainData {
   chainDisplay: string;
@@ -22,23 +22,18 @@ interface PoviderData {
 }
 
 // we use this to give an ordering to the chains available
-const ORDER_CHAINS: ChainName[] = ['joystream_rome_experimental', 'joystream_rome_final_staging'];
+const ORDER_CHAINS: ChainName[] = ['rome'];
 
 // we use this to order the providers inside the chains
 const ORDER_PROVIDERS: ProviderName[] = ['joystream_org'];
 
 // some suplementary info on a per-chain basis
 const CHAIN_INFO: Record<ChainName, ChainData> = {
-  joystream_rome_experimental: {
+  rome: {
     chainDisplay: 'Joystream',
     logo: 'joystream',
-    type: 'Rome Reckless Testnet'
+    type: 'Rome Testnet'
   },
-  joystream_rome_final_staging: {
-    chainDisplay: 'Joystream',
-    logo: 'joystream',
-    type: 'Rome Final Staging Testnet'
-  }
 };
 
 // the actual providers with all  the nodes they provide
@@ -46,13 +41,12 @@ const PROVIDERS: Record<ProviderName, PoviderData> = {
   'joystream_org': {
     providerDisplay: 'Joystream.org',
     nodes: {
-      'joystream_rome_experimental': 'wss://rome-staging-2.joystream.org/staging/rpc/',
-      'joystream_rome_final_staging': 'wss://rome-staging-4.joystream.org/rpc/',
+      'rome' : 'wss://rome-rpc-endpoint.joystream.org:9944/'
     }
   }
 };
 
-export const ENDPOINT_DEFAULT = PROVIDERS.joystream_org.nodes.joystream_rome_final_staging;
+export const ENDPOINT_DEFAULT = PROVIDERS.joystream_org.nodes.rome;
 
 export const ENDPOINTS: Option[] = ORDER_CHAINS.reduce((endpoints: Option[], chainName): Option[] => {
   const { chainDisplay, logo, type } = CHAIN_INFO[chainName];