Skip to content

Commit

Permalink
fix: autopeering - use localtunnel
Browse files Browse the repository at this point in the history
  • Loading branch information
sabineschaller committed Apr 4, 2024
1 parent 0b526f2 commit 30cdafa
Show file tree
Hide file tree
Showing 5 changed files with 81 additions and 233 deletions.
2 changes: 2 additions & 0 deletions localenv/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,8 @@ To use the Bruno collection examples follow the steps:
3. copy the url of one of the wallet addresses
4. set the url as `senderWalletAddress` variable in the Bruno `Autopeering` environment

Note that you have to go through an additional "login" step by providing you IPv4 address as tunnel password before being able to visit the consent screen for the outgoing payment grant request. You can find out your current IPv4 address by e.g. visiting https://www.whatismyip.com/.

After stopping the script it is necessary to clear the environment using the command described in [Shutting down](#Shutting-down). This is necessary as on a new run of the scripts (with autopeering or not) the wallet address url will differ.

### Shutting down
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
"sanity": "pnpm -r build && pnpm -r test",
"localenv:compose:autopeer": "run-p tunnel:start wait-tunnel:localenv:compose",
"localenv:compose:psql:autopeer": "run-p tunnel:start wait-tunnel:localenv:compose:psql",
"wait-tunnel:localenv:compose": "pnpm wait-on:env && pnpm localenv:compose up -d",
"wait-tunnel:localenv:compose:psql": "pnpm wait-on:env && pnpm localenv:compose:psql up -d",
"wait-tunnel:localenv:compose": "pnpm wait-on:env && pnpm localenv:compose --env-file ./localenv/cloud-nine-wallet/.env up -d",
"wait-tunnel:localenv:compose:psql": "pnpm wait-on:env && pnpm localenv:compose:psql --env-file ./localenv/cloud-nine-wallet/.env up -d",
"wait-on:env": "npx wait-on -d 1000 ./localenv/cloud-nine-wallet/.env",
"tunnel:start": "node ./scripts/localenv-tunnel-setup.js"
},
Expand All @@ -39,9 +39,9 @@
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
"jest": "^29.7.0",
"localtunnel": "^2.0.2",
"npm-run-all2": "^6.1.2",
"prettier": "^3.2.5",
"tunnelmole": "^2.2.14",
"typescript": "^5.4.3",
"uuid": "^9.0.1"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ To use the [Bruno API examples](/playground/overview/#bruno--open-payments-apis)
3. copy the url of one of the wallet addresses
4. set the url as `senderWalletAddress` variable in the Bruno `Autopeering` environment

Note that you have to go through an additional "login" step by providing you IPv4 address as tunnel password before being able to visit the consent screen for the outgoing payment grant request. You can find out your current IPv4 address by e.g. visiting https://www.whatismyip.com/.

To shut down the connection and to clear the environment, run

```
Expand Down
Loading

0 comments on commit 30cdafa

Please sign in to comment.