gitpod-io / gitpod

The developer platform for on-demand cloud development environments to create software faster and more securely.
https://www.gitpod.io
GNU Affero General Public License v3.0
12.79k stars 1.23k forks source link

extend gp-cli with possibility to save and restore folders #9284

Open konne opened 2 years ago

konne commented 2 years ago

In ticket #340 is clearly written the need to persist the home directory of a user. Like you answered this can have many side effects.

We store at the moment as a workaround some config directories like gcloud, 1password-cli,... folder via a simple generate targz -> base64 encode without word wrap -> store in gitpod ENV and in the startup of the workspace just vice versa.

This works for small files quite well but is not very nice and not handy for larger files.

Please introduce the methods

gp store [ENV VAR Name] [FILE/FOLDER] gp restore [ENV VAR Name] [FILE/FOLDER]

AND add in the sections for the management in the user settings like the environment variables, so that you can see and delete stored FILES/FOLDERS

loujaybee commented 2 years ago

Thanks for raising @konne, this almost feels like a lightweight version / way to mount volumes, issue below (but with the more explicit intention of using for secrets / password management)

And as you say, more of a lightweight / alternative version of:

loujaybee commented 2 years ago

Relates to (but not duplicated by):

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

axonasif commented 1 year ago

Bad bot. This is a must have feature.

loujaybee commented 1 year ago

Another use case, that I've seen which is similar to this is for creating database dumps, downloading them locally (is the current workaround), and then restoring them in future workspaces, for a similar purpose. If this were a way to share that database dump or file as shared state between workspaces, this could help.

axonasif commented 1 year ago

Wanted to share a related thing that could be used with Gitpod in combination with dotfiles feature of Gitpod:

For example, here's how I'm currently using it through my dotfiles:

I'm using google-drive as the persistent storage for rclone, there are more efficient providers on rclone but google-drive gets the job done for me, and it's free+fast 😛 .