PLATFORM
  • Tails

    Create websites with TailwindCSS

  • Blocks

    Design blocks for your website

  • Wave

    Start building the next great SAAS

  • Pines

    Alpine & Tailwind UI Library

  • Auth

    Plug'n Play Authentication for Laravel

  • Designer comingsoon

    Create website designs with AI

  • DevBlog comingsoon

    Blog platform for developers

  • Static

    Build a simple static website

  • SaaS Adventure

    21-day program to build a SAAS

Question By
Unsolved

Cloned Laravel Repo on Digital Ocean Droplets

stevefanegaii

Dec 12th, 2022 10:43 AM

Hi, Digital Ocean's team suggested I asked this community for help with their Droplet Marketplace Image of Laravel.

Is there a guide on replacing the Laravel App inside the Laravel Image with my own Git Repo? I know there are guides on how to create a Laravel App using Droplet from scratch, but I rather be able to just replace the folder inside the /var/www/laravel.

I made sure my folders had the same permission and owner as the default laravel folder, made sure that the site is enabled in the nginx folders, and restarted nginx as well.

Any help is appreciated.

bobbyiliev

Dec 12th, 2022 10:54 AM

Hi there,

Welcome to the DevDojo community!

Yes absolutely, you can just delete the contents of the laravel folder and then deploy your own project there.

Then as normal, run composer install update your database details in your .env file and run your database migrations.

Then to sort out the permissions run the following commands:

sudo chown -R larasail:www-data ${rootPath}/storage
sudo chown -R larasail:www-data ${rootPath}/bootstrap/cache

That way the Nginx service will have access to write to the storage and cache directories.

Hope that this helps.

Best,

Bobby