GithubHelp home page GithubHelp logo

dovidgef / docker-compose-laravel Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 3 KB

A docker-compose based template which makes it easy to develop a Laravel app on your local system.

Dockerfile 100.00%
docker docker-compose laravel

docker-compose-laravel's Introduction

docker-compose-laravel

A docker-compose workflow that sets up a LEMP network of containers for local Laravel development.

Usage

To get started, make sure you have Docker installed on your system, and then clone this repository.

Containers created and their ports (if used) are as follows:

  • nginx - :8080
  • mysql - :3306
  • php -
  • phpmyadmin - :9000
  • npm

Create new Laravel project using Composer docker-compose exec php composer create-project --prefer-dist laravel/laravel src

Alternatively you can clone your existing Laravel application

# Switch into php/ directory then run:
git clone [email protected]:username/laravel-project.git src

Update Laravel .env file to match docker-compose configuration

APP_URL=http://localhost:8080
DB_HOST=db
DB_DATABASE=homestead
DB_USERNAME=homestead
DB_PASSWORD=secret

Run Artisan commands docker-compose exec php php src/artisan migrate

Run npm commands without installing locally

  • docker-compose run npm run dev

docker-compose-laravel's People

Contributors

dovidgef avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.