-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(rust): automated deployment to fly.io #91
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
This is ready from my PoV. In the current state, the rust-peer is a general bootnode and not directly tied to any of our deployments. It does have a default to connect to our deployment but users can override that. In my opinion, this is a nice middlegroup between having this work out of the box but also being general enough to teach others how to bootstrap their own network. |
cmd = ["/bin/sh", "-c", "set -ex; LISTEN_ADDRESS=$(getent hosts fly-global-services | cut -d' ' -f1) && rust-libp2p-webrtc-peer"] | ||
|
||
[env] | ||
EXTERNAL_ADDRESS="149.248.215.31" # TODO: Remove this in favor of an AutoNAT setup. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would AutoNAT even work when deployed to Fly.io? In my experience running Kubo on fly.io, their overlay network messes with AutoNAT and results in the wrong IP, but it's been a while since I actually tried it and I didn't dive too deep.
# | ||
|
||
app = "universal-connectivity-rust-peer" | ||
primary_region = "syd" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any thoughts on moving this to Europe/US, where most users will likely be connecting from?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happy to, this is just the default 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
I also created a token and added it to the repo (available in GH Actions)
Weird! It does work locally but for some reason, can't connect to the deployed one on fly.io. cc @libp2p/js-libp2p-dev |
I'd like to deploy an instance of the Rust peer to a fly.io worker everytime we merge to master. I tested this and it does work although unfortunately only for IPv4. It is a start though and perhaps fly.io will at some point support UDP + IPv6. See https://fly.io/docs/app-guides/udp-and-tcp/#udp-wont-work-over-ipv6 for details.
Currently, this is running on the free-tier and thus does not incur any costs.