Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

vedoj's avatar
Level 1

Is Docker the preferred way if you don't want to use Forge?

Right now I would like to use Digital Ocean droplet directly without Forge.

Are there any gotchas when using Docker on Ubuntu 22.04 for Laravel deployment? Anything I should be aware of when not using Forge?

0 likes
4 replies
Sinnbeck's avatar

Any reason you want to use docker? Just installing nginx + php + mysql is fine in 90% of cases. Docker just makes it more complicated and forces the next dev to learn docker

Personally I use ploi.io, but I have just set up my own servers from scratch in the past on droplets

vedoj's avatar
Level 1

@sinnbeck

yeah, your solution is nice that you don't need to touch the db and even nginx, except the config file and you work only with the /var/www/example_com directory and files inside.

Can I ask what your steps were?

Did you, on your production server, create a

  1. new directory with a new version or date name e.g. 20221224_15_50_example_com and rsync there the current production version of your locally developed website + change the .env and config stuff
  2. and then in nginx.conf you change the root from /var/www/20221105_23_37_example_com to 20221224_15_50_example_com and do a graceful restart.

Or you did it diffferently? Perhaps to setup somehwat git and use it to upload changes to the production server?

Is there perhaps some tutorial how to do that as easy as possible?

I mean, I will eventually create my own notes of steps what to do to achieve those things with as least amount of steps possible, but it would be nice to read/watch somebody other's notes how to do it.

vedoj's avatar
Level 1

@Sinnbeck Interesting, thanks.

it looks complicated but I see the clear cache and views etc. stuff so there is probably everything I will ever need. And I just need to decipher all the stuff and change it to my project's needs. Thanks, again for the link.

Please or to participate in this conversation.