Skip to content
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

proxy: pick up a random port and bind to the correct port #107

Merged
merged 1 commit into from
Mar 2, 2021

Conversation

fatih
Copy link
Member

@fatih fatih commented Mar 2, 2021

This PR changes the address to bind locally. Instead of binding to a hardcoded port, we now let the OS pick up a random port for us. We had to introduce a new method to the sql-proxy repo (planetscale/sql-proxy#52) to make this work.

Both pscale shell and pscale connect now automatically bind to a random port.

closes https://github.com/planetscale/project-big-bang/issues/111

This PR changes the address to bind locally. Instead of binding to an
hardcoded port, we now let the OS pick up a random port for us. In order
to make this work, we had to introduce a new method to the `sql-proxy`
repo (planetscale/sql-proxy#52).

Both `pscale shell` and `pscale connect` now automatically binds to a
random port.

closes planetscale/surfaces#111
@fatih fatih requested a review from a team as a code owner March 2, 2021 11:15
@fatih fatih requested review from mscoutermarsh and nickvanw March 2, 2021 11:15
@fatih fatih merged commit f5024ee into main Mar 2, 2021
@fatih fatih deleted the fatih/fix-port-bind branch March 2, 2021 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants