How to move databases or other files between dev machines?

I have a main desktop for my work, and sometimes I use laptop too.
but sometimes it is hard to copy my dev database to laptop and also .env filㄷ.
How do you guys handle this?

I’m on my laptop 100% of the time. I use full screen apps (MacOS) on a 13" screen. I love how they fill in all the space. I don’t use external monitors, so I’m fully mobile and I don’t have to tweak my setup if I move to a different room or place. Extra screen is useful when doing web apps, but I don’t mind the lack of it that much.

1 Like

I think he’s rather asking how to share the database between his desktop computer and his laptop. Title is misleading :sweat_smile:

1 Like

Well, my solution is to not have that problem altoghether.

At one job everybody was getting a workstation and a laptop. For most of the people it was a waste, since people didn’t bother to set up a replica of the dev environment and mostly used the laptop to run presentations. Which was a shame, since the laptops were pretty beefy.

1 Like

Isn’t stuff like Vagrant exactly for this purpose? I know we used it in the past on some Rails projects mainly to share the same environment between different developers on that project. It was a few years back though, don’t some people use Docker for the same use case these days?

Other than that, I also use just 15" macbook and stay mobile :slight_smile: When I need additional screen, I connect my 12" iPad Pro next to it, that’s actually a very nice setup.

1 Like

I simply don’t share actual data between systems.

Code is in repository, structure of data is defined in the migrations.

Dev environment is defined via nix expressions.

The database content isn’t shared at all.

Maybe rsync the files between the two computers, perhaps via rsync.net if the two computers aren’t always online at the same time?

Or mutagen?

You might need to dump the DB to a file on one computer and restore on the other rather than syncing the raw data files around.

I have a desktop and a laptop too. I am on my laptop 100% of the time but I always ssh into my desktop for everything except the browser. Basically, I use my desktop as a beefy VPS.