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

Add socks5 proxy via dante #8145

Merged
merged 3 commits into from
Oct 22, 2024

Conversation

Fraggle
Copy link
Contributor

@Fraggle Fraggle commented Oct 22, 2024

Description

This PR adds a SOCKS5 proxy using Dante. The changes include:

  1. Adding a new Dante Dockerfile and configuration
  2. Creating a new GitHub Actions workflow for deploying Dante
  3. Updating Kubernetes configurations to include the SOCKS proxy
  4. Minor adjustments to existing configurations

Usage:
Use the SOCKS_PROXY_HOST and SOCKS_PROXY_PORT env variables in core or connectors (already available).

Risk

None

Deploy Plan

Apply infra

@Fraggle Fraggle requested a review from fontanierh October 22, 2024 05:46
@spolu
Copy link
Contributor

spolu commented Oct 22, 2024

I'm a bit lost between nginx and dante and who uses what when and where. Do we have a design doc that describes the latest state?

@@ -0,0 +1,24 @@
FROM alpine:3.20
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is special about our image? Ideally if we coule use a stock one we wouldn't need a github workflow etc...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The one i used before was also very old and the creator was using « ash » (making it different from our others images, breaking k8s_ssh for example)

I’m not a fan of the extra workflow either but we shouldn’t have to run it often.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok if there's no official image then LGTM 👍


EXPOSE 1080

ENTRYPOINT ["dumb-init"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does it do?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid the container to immediately shutdown.

@Fraggle
Copy link
Contributor Author

Fraggle commented Oct 22, 2024

Nginx = http proxy
Dante = socks proxy

Norhing uses dante yet.

The design doc is not up to date, i’ll update (btw i understood than design doc were only a point in time and they were not kept updated, is that incorrect ?)

Copy link
Contributor

@fontanierh fontanierh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@spolu
Copy link
Contributor

spolu commented Oct 22, 2024

The design doc is not up to date, i’ll update (btw i understood than design doc were only a point in time and they were not kept updated, is that incorrect ?)

Well if the project is still ongoing it's good hygiene to have an up to date version so that it can be used to track progress and review to better understand PRs such as here.

re nginx vs dante: I though it was possible to do with nginx? is it? Right now snowflake uses nginx then? what's the plan for dante?

@Fraggle
Copy link
Contributor Author

Fraggle commented Oct 22, 2024

The design doc is not up to date, i’ll update (btw i understood than design doc were only a point in time and they were not kept updated, is that incorrect ?)

Well if the project is still ongoing it's good hygiene to have an up to date version so that it can be used to track progress and review to better understand PRs such as here.

No problemo, will do

re nginx vs dante: I though it was possible to do with nginx? is it?

It is but turned out more hacky than i was expecting (running a client in front of nginx).
After discussing quickly live with @fontanierh we decided that it was simpler to use dante.

Right now snowflake uses nginx then?

Yes

What's the plan for dante?

Immediately, nothing. Mostly about readiness for other db engines in « 48h » (such as postgres)

Base automatically changed from 1426-remote-databases-add-socks5-proxy-support-to-nginx to main October 22, 2024 07:48
@spolu
Copy link
Contributor

spolu commented Oct 22, 2024

ack thanks

@Fraggle Fraggle merged commit ecff49e into main Oct 22, 2024
8 checks passed
@Fraggle Fraggle deleted the 1426-remote-databases-add-socks5-proxy-via-dante branch October 22, 2024 08:54
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.

3 participants