Skip to content
Open
Show file tree
Hide file tree
Changes from 23 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
57f4af2
feat: implement multihop static routing
sanducb Jul 18, 2025
91fbc86
fix: localenv docker compose, filter route by incoming peer id
sanducb Jul 30, 2025
1ba31da
fix: route filtering and cleanup
sanducb Jul 31, 2025
d17711f
fix: tests
sanducb Jul 31, 2025
4194adf
chore(masl): fix seed script
mkurapov Aug 1, 2025
0628730
chore(localenv): add back in the EUR asset for c9 wallet
mkurapov Aug 1, 2025
7d0f715
Merge branch 'main' into multihop-static-routing-v1
sanducb Aug 6, 2025
73ff3d7
chore(backend): add incoming peer filtering test for the base case
sanducb Aug 7, 2025
7b8f9e1
chore(backend): merge branch 'multihop-static-routing-v1' of https://…
sanducb Aug 7, 2025
dfea873
chore: branch 'main' of https://github.com/interledger/rafiki into mu…
sanducb Aug 8, 2025
d55be32
chore: have only 3 Rafiki instances in localenv
sanducb Aug 8, 2025
86cb686
fix(backend): generate grapqhl types
sanducb Aug 8, 2025
609ae88
fix(backend): fix peer service test
sanducb Aug 8, 2025
dd50bac
chore: merge branch 'main' of https://github.com/interledger/rafiki i…
sanducb Aug 18, 2025
84bd2ff
chore(backend): update liquidity in seed files
sanducb Aug 19, 2025
a55a34a
chore(backend): update seed and compose files
sanducb Aug 19, 2025
5585027
chore(backend): update liquidity for global-bank and happy-life
sanducb Aug 21, 2025
8ff9839
chore(backend): remove unused routing logic
sanducb Aug 22, 2025
96db48f
chore: add max packet amount to seed, delete unused instances in loca…
sanducb Aug 22, 2025
4343315
chore: make max packet amount optional in seed
sanducb Aug 22, 2025
d2a92e2
chore(backend): ensure previous routes were cleared before syncing ne…
sanducb Aug 28, 2025
9470026
feat(backend): simplify localenv and seeding logic to accommodate mul…
sanducb Sep 21, 2025
ac0989f
chore(mock-ase): format
sanducb Sep 22, 2025
127bb76
chore(mock-ase): simplify localenv and seed for multihop
sanducb Sep 22, 2025
a3fabfd
chore(backend): remove peer liquidity logging functions
sanducb Sep 23, 2025
60c60dc
chore(backend): load routes from database before admin server is started
sanducb Sep 23, 2025
8fc4b9a
chore: merge branch 'main' of https://github.com/interledger/rafiki i…
sanducb Oct 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions localenv/admin-auth/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,10 @@ services:
args:
PATH_TO_KRATOS_CONFIG: ./localenv/admin-auth/cloud-nine-kratos.yml
depends_on:
- shared-database
- mailslurper
shared-database:
condition: service_healthy
mailslurper:
condition: service_started
environment:
DEV_MODE: true
ports:
Expand All @@ -43,8 +45,10 @@ services:
args:
PATH_TO_KRATOS_CONFIG: ./localenv/admin-auth/happy-life-kratos.yml
depends_on:
- shared-database
- mailslurper
shared-database:
condition: service_healthy
mailslurper:
condition: service_started
environment:
DEV_MODE: true
ports:
Expand Down
8 changes: 8 additions & 0 deletions localenv/cloud-nine-wallet/dbinit.sql
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,11 @@ ALTER DATABASE happy_life_bank_backend OWNER TO happy_life_bank_backend;
CREATE USER happy_life_bank_auth WITH PASSWORD 'happy_life_bank_auth';
CREATE DATABASE happy_life_bank_auth;
ALTER DATABASE happy_life_bank_auth OWNER TO happy_life_bank_auth;

CREATE USER global_bank_backend WITH PASSWORD 'global_bank_backend';
CREATE DATABASE global_bank_backend;
ALTER DATABASE global_bank_backend OWNER TO global_bank_backend;

CREATE USER global_bank_auth WITH PASSWORD 'global_bank_auth';
CREATE DATABASE global_bank_auth;
ALTER DATABASE global_bank_auth OWNER TO global_bank_auth;
21 changes: 17 additions & 4 deletions localenv/cloud-nine-wallet/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ services:
depends_on:
cloud-nine-backend:
condition: service_healthy
shared-database:
condition: service_healthy
cloud-nine-backend:
hostname: cloud-nine-wallet-backend
image: rafiki-backend
Expand Down Expand Up @@ -80,11 +82,14 @@ services:
WALLET_ADDRESS_URL: ${CLOUD_NINE_WALLET_ADDRESS_URL:-https://cloud-nine-wallet-backend/.well-known/pay}
ILP_CONNECTOR_URL: ${CLOUD_NINE_CONNECTOR_URL:-http://cloud-nine-wallet-backend:3002}
ENABLE_TELEMETRY: true
ENABLE_ILP_TIMING: true
KEY_ID: 7097F83B-CB84-469E-96C6-2141C72E22C0
OPERATOR_TENANT_ID: 438fa74a-fa7d-4317-9ced-dde32ece1787
depends_on:
- shared-database
- shared-redis
shared-database:
condition: service_healthy
shared-redis:
condition: service_started
healthcheck:
test: ["CMD", "wget", "--spider", "http://localhost:3001/healthz"]
start_period: 60s
Expand Down Expand Up @@ -125,8 +130,10 @@ services:
OPERATOR_TENANT_ID: 438fa74a-fa7d-4317-9ced-dde32ece1787
SERVICE_API_PORT: 3011
depends_on:
- shared-database
- shared-redis
shared-database:
condition: service_healthy
shared-redis:
condition: service_started
shared-database:
image: 'postgres:15' # use latest official postgres version
restart: unless-stopped
Expand All @@ -140,6 +147,12 @@ services:
environment:
POSTGRES_PASSWORD: password
POSTGRES_USER: postgres
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d postgres"]
interval: 10s
timeout: 5s
retries: 5
start_period: 30s
shared-redis:
image: 'redis:7'
restart: unless-stopped
Expand Down
31 changes: 18 additions & 13 deletions localenv/cloud-nine-wallet/seed.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,35 @@
assets:
- code: USD
scale: 2
liquidity: 100000000
liquidity: 10000000
liquidityThreshold: 10000000
- code: EUR
scale: 2
liquidity: 100000000
liquidity: 10000000
liquidityThreshold: 10000000
- code: MXN
scale: 2
liquidity: 100000000
liquidityThreshold: 10000000
- code: JPY
scale: 0
liquidity: 1000000
liquidityThreshold: 100000
peeringAsset: 'USD'
peers:
- initialLiquidity: '10000000'
peerUrl: http://global-bank-backend:3002
peerIlpAddress: test.global-bank
liquidityThreshold: 1000000
tokens:
incoming:
- global-to-cloud-nine
outgoing: cloud-nine-to-global
routes:
# This route MUST remain unchanged when NOT in multihop mode so that happy-life packets aren't routed through global-bank
- "test"
- initialLiquidity: '10000000'
peerUrl: http://happy-life-bank-backend:3002
peerIlpAddress: test.happy-life-bank
liquidityThreshold: 1000000
tokens:
incoming:
- test-USD-happy-life-bank-cloud-nine-wallet
outgoing: test-USD-cloud-nine-wallet-happy-life-bank
- happy-to-cloud-nine
outgoing: cloud-nine-to-happy
routes:
- "test.happy-life-bank"
accounts:
- name: 'Grace Franklin'
path: accounts/gfranklin
Expand Down Expand Up @@ -89,4 +94,4 @@ fees:
- fixed: 1
basisPoints: 200
asset: JPY
scale: 0
scale: 0
8 changes: 5 additions & 3 deletions localenv/cloud-ten-wallet/seed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,11 @@ peers:
peerIlpAddress: test.happy-life-bank
liquidityThreshold: 1000000
tokens:
incoming:
- test-USD-happy-life-bank-cloud-ten-wallet
outgoing: test-USD-cloud-ten-wallet-happy-life-bank
incoming:
- happy-to-cloud-ten
outgoing: cloud-ten-to-happy
routes:
- "test.happy-life-bank"
accounts:
- name: 'Frace Granklin'
path: accounts/fgranklin
Expand Down
149 changes: 149 additions & 0 deletions localenv/global-bank/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,149 @@
name: gb
services:
global-bank-mock-ase:
hostname: global-bank
image: rafiki-mock-ase
pull_policy: never
restart: always
networks:
- rafiki
ports:
- '3032:80'
environment:
LOG_LEVEL: debug
PORT: 80
SEED_FILE_LOCATION: /workspace/seed.yml
KEY_FILE: /workspace/private-key.pem
OPEN_PAYMENTS_URL: ${GLOBAL_BANK_OPEN_PAYMENTS_URL:-https://global-bank-backend}
GRAPHQL_URL: http://global-bank-backend:3001/graphql
SIGNATURE_VERSION: 1
SIGNATURE_SECRET: iyIgCprjb9uL8wFckR+pLEkJWMB7FJhgkvqhTQR/964=
IDP_SECRET: 2pEcn2kkCclbOHQiGNEwhJ0rucATZhrA807HTm2rNXE=
DISPLAY_NAME: Global Bank
DISPLAY_ICON: bank-icon.svg
OPERATOR_TENANT_ID: 53f2d913-e98a-40b9-b270-372d0547f23e
FRONTEND_PORT: 5010
volumes:
- ../global-bank/seed.yml:/workspace/seed.yml
- ../global-bank/private-key.pem:/workspace/private-key.pem
depends_on:
global-bank-backend:
condition: service_healthy
shared-database:
condition: service_healthy
global-bank-backend:
hostname: global-bank-backend
image: rafiki-backend
pull_policy: never
volumes:
- type: bind
source: ../../packages/backend/src
target: /home/rafiki/packages/backend/src
read_only: true
restart: always
privileged: true
ports:
- "5000:80"
- "5001:3001"
- "5002:3002"
- '9233:9229'
networks:
- rafiki
environment:
NODE_ENV: development
INSTANCE_NAME: GLOBAL-BANK
LOG_LEVEL: debug
ADMIN_PORT: 3001
CONNECTOR_PORT: 3002
OPEN_PAYMENTS_PORT: 80
DATABASE_URL: postgresql://global_bank_backend:global_bank_backend@shared-database/global_bank_backend
USE_TIGERBEETLE: false
AUTH_SERVER_GRANT_URL: ${GLOBAL_BANK_AUTH_SERVER_DOMAIN:-http://global-bank-auth:3006}
AUTH_SERVER_INTROSPECTION_URL: http://global-bank-auth:3007
AUTH_ADMIN_API_URL: 'http://global-bank-auth:5003/graphql'
AUTH_ADMIN_API_SECRET: 'rPoZpe9tVyBNCigm05QDco7WLcYa0xMao7lO5KG1XG4='
AUTH_SERVICE_API_URL: 'http://global-bank-auth:5011'
ILP_ADDRESS: test.global-bank
ILP_CONNECTOR_URL: http://global-bank-backend:5002
STREAM_SECRET: BjPXtnd00G2mRQwP/8ZpwyZASOch5sUXT5o0iR5b5wU=
API_SECRET: iyIgCprjb9uL8wFckR+pLEkJWMB7FJhgkvqhTQR/964=
WEBHOOK_URL: http://global-bank/webhooks
OPEN_PAYMENTS_URL: ${GLOBAL_BANK_OPEN_PAYMENTS_URL:-https://global-bank-backend}
EXCHANGE_RATES_URL: http://global-bank/rates
REDIS_URL: redis://shared-redis:6379/4
WALLET_ADDRESS_URL: ${GLOBAL_BANK_WALLET_ADDRESS_URL:-https://global-bank-backend/.well-known/pay}
ENABLE_TELEMETRY: true
ENABLE_ILP_TIMING: true
KEY_ID: 53f2d913-e98a-40b9-b270-372d0547f23e
OPERATOR_TENANT_ID: 53f2d913-e98a-40b9-b270-372d0547f23e
depends_on:
shared-database:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "--spider", "http://localhost:3001/healthz"]
start_period: 60s
start_interval: 5s
interval: 30s
retries: 1
timeout: 3s
global-bank-auth:
hostname: global-bank-auth
image: rafiki-auth
pull_policy: never
restart: always
volumes:
- type: bind
source: ../../packages/auth/src
target: /home/rafiki/packages/auth/src
read_only: true
networks:
- rafiki
ports:
- '5003:3003'
- '5006:3006'
- '9234:9229'
- '5009:3009'
- '5011:5011'
environment:
NODE_ENV: development
AUTH_DATABASE_URL: postgresql://global_bank_auth:global_bank_auth@shared-database/global_bank_auth
AUTH_SERVER_URL: ${GLOBAL_BANK_AUTH_SERVER_DOMAIN:-http://localhost:5006}
REDIS_URL: redis://shared-redis:6379/5
IDENTITY_SERVER_URL: http://localhost:3032/mock-idp/
IDENTITY_SERVER_SECRET: 2pEcn2kkCclbOHQiGNEwhJ0rucATZhrA807HTm2rNXE=
COOKIE_KEY: 42397d1f371dd4b8b7d0308a689a57c882effd4ea909d792302542af47e2cd37
ADMIN_API_SECRET: rPoZpe9tVyBNCigm05QDco7WLcYa0xMao7lO5KG1XG4=
OPERATOR_TENANT_ID: 53f2d913-e98a-40b9-b270-372d0547f23e
SERVICE_API_PORT: 5011
depends_on:
shared-database:
condition: service_healthy
happy-life-auth:
condition: service_started
global-bank-admin:
hostname: global-bank-admin
image: rafiki-frontend
pull_policy: never
volumes:
- type: bind
source: ../../packages/frontend/app
target: /home/rafiki/packages/frontend/app
read_only: true
restart: always
networks:
- rafiki
ports:
- '5010:5010'
environment:
PORT: 5010
LOG_LEVEL: debug
NODE_ENV: development
GRAPHQL_URL: http://global-bank-backend:3001/graphql
OPEN_PAYMENTS_URL: https://global-bank-backend/
ENABLE_INSECURE_MESSAGE_COOKIE: true
AUTH_ENABLED: false
SIGNATURE_VERSION: 1
SIGNATURE_SECRET: iyIgCprjb9uL8wFckR+pLEkJWMB7FJhgkvqhTQR/964=
depends_on:
- happy-life-admin
- global-bank-backend
3 changes: 3 additions & 0 deletions localenv/global-bank/private-key.pem
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-----BEGIN PRIVATE KEY-----
MC4CAQAwBQYDK2VwBCIEIEqezmcPhOE8bkwN+jQrppfRYzGIdFTVWQGTHJIKpz88
-----END PRIVATE KEY-----
58 changes: 58 additions & 0 deletions localenv/global-bank/seed.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
assets:
- code: USD
scale: 2
liquidity: 10000000000
liquidityThreshold: 10000000
peeringAsset: 'USD'
peers:
- initialLiquidity: '100000000000000'
peerUrl: http://cloud-nine-wallet-backend:3002
peerIlpAddress: test.cloud-nine-wallet
liquidityThreshold: 1000000
maxPacketAmount: 10000
tokens:
incoming:
- cloud-nine-to-global
outgoing: global-to-cloud-nine
routes:
- "test.cloud-nine-wallet"
- initialLiquidity: '100000000000000'
peerUrl: http://happy-life-bank-backend:3002
peerIlpAddress: test.happy-life-bank
liquidityThreshold: 1000000
maxPacketAmount: 10000
tokens:
incoming:
- happy-to-global
outgoing: global-to-happy
routes:
- "test.happy-life-bank"
accounts:
- name: 'John Doe'
path: accounts/jdoe
id: 77a3a431-8ee1-48fc-ac85-70e2f5eba8e6
initialBalance: 1000000
brunoEnvVar: jdoeWalletAddress
assetCode: USD
- name: 'Global Corp'
id: 4455cc54-b583-455b-836a-e5275c5c05b8
initialBalance: 5000000
path: accounts/gcorp
brunoEnvVar: gcorpWalletAddress
assetCode: USD
- name: 'Jane Smith'
path: accounts/jsmith
id: 447ac10b-58cc-4372-a567-0e02b2c3d480
initialBalance: 2000000
brunoEnvVar: jsmithWalletAddress
assetCode: USD
rates:
USD:
MXN: 17.07
EUR: 0.91
JPY: 147.71
fees:
- fixed: 100
basisPoints: 200
asset: USD
scale: 2
1 change: 1 addition & 0 deletions localenv/happy-life-bank/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ services:
REDIS_URL: redis://shared-redis:6379/2
WALLET_ADDRESS_URL: ${HAPPY_LIFE_BANK_WALLET_ADDRESS_URL:-https://happy-life-bank-backend/.well-known/pay}
ENABLE_TELEMETRY: true
ENABLE_ILP_TIMING: true
KEY_ID: 53f2d913-e98a-40b9-b270-372d0547f23d
OPERATOR_TENANT_ID: cf5fd7d3-1eb1-4041-8e43-ba45747e9e5d
depends_on:
Expand Down
Loading
Loading