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

Create docker-compose and remove customer git fallback #99

Merged
merged 3 commits into from
May 19, 2020
Merged

Conversation

srueg
Copy link
Contributor

@srueg srueg commented May 18, 2020

Simplify the user and SSH setup to make local usage easier.

By default the user's .ssh/ directory with all keys gets mounted into the container. An SSH agent is started and the keys are added with ssh-add in the entrypoint. To skip the SSH agent setup, one can set the SSH_AUTH_SOCK env var to a path which is available in the container (mounted) to reuse an existing agent.

This will require some changes to the commodore job runner, MR is in progress.

Also, remove the customer git fallback.

@srueg srueg requested a review from simu May 18, 2020 12:32
@srueg srueg force-pushed the docker-compose branch from 76baf02 to 0b9aba0 Compare May 18, 2020 12:33
@srueg srueg changed the title Create docker-compose Setup Create docker-compose and remove customer git fallback May 18, 2020
@srueg srueg force-pushed the docker-compose branch from 0b9aba0 to ae012df Compare May 18, 2020 13:44
@srueg srueg requested a review from corvus-ch May 18, 2020 14:00
@corvus-ch
Copy link
Contributor

When running docker-compose run commodore compile $CLUSTER_ID, the only thing I get is something along the line of Agent pid 9. I can not see whether or not commodore got executed and if there was a failure what it was.

@srueg
Copy link
Contributor Author

srueg commented May 18, 2020

That might be because you're using a hardware token?

It executes ssh-add. In my case I get asked for the key password...

@srueg srueg mentioned this pull request May 18, 2020
3 tasks
@srueg srueg force-pushed the docker-compose branch 3 times, most recently from b03301b to ddfbe73 Compare May 18, 2020 15:56
@srueg
Copy link
Contributor Author

srueg commented May 19, 2020

When running docker-compose run commodore compile $CLUSTER_ID, the only thing I get is something along the line of Agent pid 9. I can not see whether or not commodore got executed and if there was a failure what it was.

The issue was that the private key had a non-standard name (e.g. not id_rsa). We solved this by also adding non-standard keys in the entrypoint script and some error log for the case no keys were found.

@srueg srueg force-pushed the docker-compose branch 2 times, most recently from 31c224a to cec8f53 Compare May 19, 2020 06:59
Copy link
Member

@simu simu left a comment

Choose a reason for hiding this comment

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

LGTM overall.

Dockerfile Outdated Show resolved Hide resolved
srueg added 3 commits May 19, 2020 09:10
Simplify the user and SSH setup to make local usage easier.

Signed-off-by: Simon Rüegg <simon@rueggs.ch>
The customer repo URL is required from the API, remove the fallback to
the env var.

Signed-off-by: Simon Rüegg <simon@rueggs.ch>
Validate and compile docs.

Signed-off-by: Simon Rüegg <simon@rueggs.ch>
@srueg srueg force-pushed the docker-compose branch from cec8f53 to 2b86d43 Compare May 19, 2020 07:10
@srueg srueg requested a review from simu May 19, 2020 07:11
@srueg srueg merged commit c1cc53a into master May 19, 2020
@srueg srueg deleted the docker-compose branch May 19, 2020 07:46
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