celo-org / celo-monorepo

Official repository for core projects comprising the Celo platform
https://celo.org
Apache License 2.0
699 stars 369 forks source link

Relay servers for Wallet Connect #7422

Closed carterqw2 closed 3 years ago

carterqw2 commented 3 years ago

Description These are the servers that facilitate communication between a wallet (ie. Valora) and a dApp. In the future these servers will only handle the handshake between walletdapp before upgrading to peer-to-peer WebRTC.

WalletConnect represents the premium wallet experience for our end users and we don't want to be relying on a third party to facilitate that connection.

The actual server we need to run is built in typescript and can be autoscaled as long as it's backed by a Redis cluster. We only need to run two instances, staging and production, because WC is independent of the blockchain network used.

The code is here: https://github.com/WalletConnect-Labs/walletconnect-v2-monorepo/tree/master/servers/relay

Acceptance Criteria

  1. There is a pre-built image of the relay server distributed by the WalletConnect team or our custom built image.
  2. There is a new command in celotool that allows deploying a new instance of the relay server.
  3. The command also creates a Redis (memorystore) instance (see blockscout cloudsql example).
  4. Relay server is being deployed with a horizontal pod autoscaler enabled with the max of desired replicas set to 1.
yourbuddyconner commented 3 years ago

This seems pretty straightforward, wrap the service in a helm chart and add the deployment to celotool