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

[Test-Proxy] Within Codespaces, Volume is not mapping appropriately #1938

Closed
scbedd opened this issue Aug 26, 2021 · 3 comments
Closed

[Test-Proxy] Within Codespaces, Volume is not mapping appropriately #1938

scbedd opened this issue Aug 26, 2021 · 3 comments
Assignees
Labels
Central-EngSys This issue is owned by the Engineering System team.

Comments

@scbedd
Copy link
Member

scbedd commented Aug 26, 2021

Repro Branch
Commit at time of issue creation
In Main now!

If spun up within codespaces, we are still forced to docker cp out of the instance.

I'm very concerned that due to the fact that this is docker running within docker, there won't be a valid way to map the volume. We will see though.

@scbedd scbedd added the Central-EngSys This issue is owned by the Engineering System team. label Aug 26, 2021
@scbedd scbedd self-assigned this Aug 26, 2021
@scbedd
Copy link
Member Author

scbedd commented Aug 27, 2021

This comment sheds some light as to what we can do here. This should work, I just need to figure out how to bind to the host volume from within the DOOD (docker on outer docker) instance.

@scbedd
Copy link
Member Author

scbedd commented Sep 7, 2021

Ok. So here's the dealio.

codespaces environments are actually containers. We can get access to the containing host-instance of docker through the bind-mounted unix socket at /var/run/docker-host.sock. We can call into it like curl --unix-socket /var/run/docker-host.sock -X GET http://localhost/containers/json and see other containers on the same host.

The issue with the above, is that there is no way for the sibling containers to talk to each other.

So, if we want to continue with the leveraging the docker sock, we need some way to resolve the networking.

Other than utilizing the already bound docker socket, I can see two other alternatives.

  1. Start consuming docker-in-docker within our codespaces file.
    • The issue with this? This could be a single transfer of a command, or it could be a nightmare to configure. 🤷‍♂️
  2. Run the test-proxy via the command, and not docker, while running on docker.
    • Means that the startup script will need a "if run using test-proxy instead of the docker command"

Ideally, we are able to magic the environment to get it to the point where there is simply 0 thought, and we can stand up the instance the same way in codespaces that we do locally. For that to work, the dind approach is the way to go.

@scbedd
Copy link
Member Author

scbedd commented Sep 8, 2021

Calling this g2g.

mount_working

@scbedd scbedd closed this as completed Sep 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Central-EngSys This issue is owned by the Engineering System team.
Projects
None yet
Development

No branches or pull requests

1 participant