Open progrium opened 9 years ago
Just putting my two cents here, but I like the idea of /root
being common to all environments. I have my dotfiles, common scripts, etc in there and it "just works" when switching to new environments. Not the end of the world if I have to source my /home/jgallen23/.bashrc
though. Or maybe the default /root/.bashrc
checks to see if your current user's home directory has a .bashrc and sources? That might be the best way to go
Yeah we can do that default.
One other thing to think about is that with a shared /root
, I only have to generate an sshkey once, add that to github and then I can clone from any environment without having to mess around with new keys.
I don't totally follow. You're generating a private key to use from an envy environment? And you'd rather that be for the root user than your own user.
I'm generating ssh key from my jgallen23 envy env so I can clone private repos in all my other envy environments. Is there a better way to handle this?
And that ssh key gets stored in /root/.ssh/id_rsa, so if root isn't shared, then the ssh keys won't be the same across envy environments.
Yeah. That could be desired but also not impossible to achieve when root isn't shared. But it's a good point from a convenience point of view.
Would love to hear more perspectives on this.
I still haven't moved /env
to /root/env
, however, I did set up a new RC / startup script system that would relatively easily allow you to resolve the SSH key issue.
https://github.com/progrium/envy/commit/88f3ef62caafc4f829884b5bb2e97901c35186e6
one other thing to think about is other dotfiles. .gitconfig, .vimrc, .jshintrc, .aws, .npm, etc. I would think all environments for that user should share those things. Are you envisioning those would be manually symlinked with the envyrc too?
is /root being unique to each env still the plan for 0.1.0? Looks like with the GO version, it's still shared
Yeah, still shared. I'm back and forth about it.
Right now,
/home/<username>
and/root
are both persisted as volumes across all environments for a user. Root because that lets us customize the profile scripts for the root/default user, and the home directory in case you want to use your own user and have profile scripts there.However, root script loading will change depending on the distribution of the environment. It might make sense to create a root volume for each environment instead of each user. If there are scripts a user wants sourced across all environments, they can put them in their home directory and source from root.
When thinking about where to store this per env root in the admin directory tree, it starts to make sense that maybe each environment is its root directory with it's env definition inside it.
/env
becomes/root/env
inside an environment. This sort of makes sense.