crops / poky-container

A container image that is able to run bitbake/poky. It has helpers to create users and groups within the container. This is so that the output generated in the container will be readable by the user on the host.
GNU General Public License v2.0
209 stars 95 forks source link

Need a way to get .ssh/config and .ssh/known_hosts to work well with the poky container #77

Open gschmottlach-xse opened 2 years ago

gschmottlach-xse commented 2 years ago

The closed issue #29 is biting me as well. Currently there does not seem to be a viable way to share the host's .ssh/config and/or .ssh/known_hosts with the poky container since it appears the pokyuser account is created on-the-fly when the container is run based on the uid/gid of the workdir. I desparately need a mechanism to share this in order for my container to build my Yocto image correctly. Do you have any suggestions. It was mentioned in Issue #29 that this remained an outstanding issue that needs to be addressed. I'm hoping a solution has been discovered but just not documented.

AI0867 commented 2 years ago

I personally dump all the things from the host that I need in the container in a subdirectory of the workdir, and then use a single bash-script that sets up aliases, copies files, and sources the relevant environment file.

patrick-dojofive commented 1 year ago

I'm running into the same issue and the final answer in #29 does not work for me.

mtetreault commented 1 year ago

I usually mount the known_hosts in /etc/ssh/known_hosts which solves the issue for me.

-v ~/.ssh/known_hosts:/etc/ssh/known_hosts