Compare commits
25 Commits
Author | SHA1 | Date | |
---|---|---|---|
721e04370f | |||
b569765f82 | |||
1c9596dd80 | |||
c59dea3745 | |||
460b24f7ee | |||
2fc3919598 | |||
978dd425b9 | |||
1b8726458f | |||
3557f508d0 | |||
1ce802f2cc | |||
f0eda43906 | |||
343a950adc | |||
0218ef6b9f | |||
33e8e91e49 | |||
e78b3ff799 | |||
13bdfa119d | |||
0eea7a639a | |||
f2db21f339 | |||
b10108a9b5 | |||
dd3e88fba9 | |||
860af556e2 | |||
586a21086f | |||
d76f9e7722 | |||
79ce978527 | |||
944639b248 |
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,4 +1,3 @@
|
|||||||
.idea
|
.idea
|
||||||
/logs
|
/logs
|
||||||
/data
|
/data
|
||||||
.env
|
|
||||||
|
@ -469,7 +469,7 @@ composer create-project laravel/laravel my-cool-app "5.2.*"
|
|||||||
系统默认LaraDock假定Laravel应用在LaraDock的父级目录中
|
系统默认LaraDock假定Laravel应用在LaraDock的父级目录中
|
||||||
By default LaraDock assumes the Laravel application is living in the parent directory of the laradock folder.
|
By default LaraDock assumes the Laravel application is living in the parent directory of the laradock folder.
|
||||||
|
|
||||||
自新Laravel应用在 `my-cool-app` 目录中, 我们需要用 `../my-cool-app/:/var/www`替换 `../:/var/www` , 如下:
|
更新Laravel应用在 `my-cool-app` 目录中, 我们需要用 `../my-cool-app/:/var/www`替换 `../:/var/www` , 如下:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
application:
|
application:
|
||||||
|
485
README.md
485
README.md
@ -6,9 +6,26 @@
|
|||||||
|
|
||||||
Laradock is a Docker PHP development environment. It facilitate running **PHP** Apps on **Docker**.
|
Laradock is a Docker PHP development environment. It facilitate running **PHP** Apps on **Docker**.
|
||||||
|
|
||||||
|
>Use Docker first and learn about it later.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<a name="Intro"></a>
|
||||||
|
## Intro
|
||||||
|
|
||||||
|
Laradock strives to make the PHP development experience easier and faster.
|
||||||
|
|
||||||
|
It contains pre-packaged Docker Images that provides you a wonderful *development* environment without requiring you to install PHP, NGINX, MySQL, REDIS, and any other software on your machines.
|
||||||
|
|
||||||
Laradock is configured to run Laravel Apps by default, and it can be modified to run all kinds of PHP Apps (Symfony, CodeIgniter, Wordpress, Drupal...).
|
Laradock is configured to run Laravel Apps by default, and it can be modified to run all kinds of PHP Apps (Symfony, CodeIgniter, Wordpress, Drupal...).
|
||||||
|
|
||||||
>Use Docker first and learn about it later.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## Contents
|
## Contents
|
||||||
|
|
||||||
@ -50,9 +67,12 @@ Laradock is configured to run Laravel Apps by default, and it can be modified to
|
|||||||
- [Run Artisan Commands](#Run-Artisan-Commands)
|
- [Run Artisan Commands](#Run-Artisan-Commands)
|
||||||
- [Use Redis](#Use-Redis)
|
- [Use Redis](#Use-Redis)
|
||||||
- [Use Mongo](#Use-Mongo)
|
- [Use Mongo](#Use-Mongo)
|
||||||
- [Use phpMyAdmin](#Use-phpMyAdmin)
|
- [Use PhpMyAdmin](#Use-phpMyAdmin)
|
||||||
- [Use pgAdmin](#Use-pgAdmin)
|
- [Use PgAdmin](#Use-pgAdmin)
|
||||||
|
- [Use Beanstalkd](#Use-Beanstalkd)
|
||||||
- [Use ElasticSearch](#Use-ElasticSearch)
|
- [Use ElasticSearch](#Use-ElasticSearch)
|
||||||
|
- [Use Selenium](#Use-Selenium)
|
||||||
|
- [Use RethinkDB](#Use-RethinkDB)
|
||||||
- [CodeIgniter](#CodeIgniter):
|
- [CodeIgniter](#CodeIgniter):
|
||||||
- [Install CodeIgniter](#Install-CodeIgniter)
|
- [Install CodeIgniter](#Install-CodeIgniter)
|
||||||
- [Misc](#Misc)
|
- [Misc](#Misc)
|
||||||
@ -74,26 +94,40 @@ Laradock is configured to run Laravel Apps by default, and it can be modified to
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Intro"></a>
|
|
||||||
## Intro
|
|
||||||
|
|
||||||
Laradock strives to make the PHP development experience easier and faster.
|
|
||||||
|
|
||||||
It contains pre-packaged Docker Images that provides you a wonderful *development* environment without requiring you to install PHP, NGINX, MySQL, REDIS, and any other software on your machines.
|
|
||||||
|
|
||||||
|
|
||||||
**Usage Overview:**
|
|
||||||
|
|
||||||
Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL` and `Redis`. Then run `Laravel`.
|
### Quick Overview:
|
||||||
|
|
||||||
|
Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL`, `Redis` and `Beanstalkd`:
|
||||||
|
|
||||||
|
1 - Clone Laradock inside your PHP project:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
git clone https://github.com/Laradock/laradock.git
|
||||||
|
```
|
||||||
|
|
||||||
|
2 - Enter the laradock folder and run this command:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
docker-compose up -d nginx mysql redis beanstalkd
|
||||||
|
```
|
||||||
|
|
||||||
|
3 - Open your `.env` file and set the following:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
DB_HOST=mysql
|
||||||
|
REDIS_HOST=redis
|
||||||
|
QUEUE_HOST=beanstalkd
|
||||||
|
```
|
||||||
|
|
||||||
|
4 - Open your browser and visi localhost: `http://localhost`.
|
||||||
|
|
||||||
|
```shell
|
||||||
|
That's it! enjoy :)
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
1. Get LaraDock inside your Laravel project:
|
|
||||||
<br>
|
|
||||||
`git clone https://github.com/LaraDock/laradock.git`.
|
|
||||||
2. Enter the laradock folder and run only these Containers:
|
|
||||||
<br>
|
|
||||||
`docker-compose up -d nginx mysql redis`
|
|
||||||
3. Open your `.env` file and set `DB_HOST` to `mysql` and `REDIS_HOST` to `redis`.
|
|
||||||
4. Open your browser and visit the localhost: `http://localdock`
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -115,6 +149,10 @@ Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL` and `Red
|
|||||||
- More to come every week..
|
- More to come every week..
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Supported-Containers"></a>
|
<a name="Supported-Containers"></a>
|
||||||
### Supported Software (Containers)
|
### Supported Software (Containers)
|
||||||
|
|
||||||
@ -124,6 +162,7 @@ Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL` and `Red
|
|||||||
- MariaDB
|
- MariaDB
|
||||||
- MongoDB
|
- MongoDB
|
||||||
- Neo4j
|
- Neo4j
|
||||||
|
- RethinkDB
|
||||||
- **Cache Engines:**
|
- **Cache Engines:**
|
||||||
- Redis
|
- Redis
|
||||||
- Memcached
|
- Memcached
|
||||||
@ -136,14 +175,26 @@ Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL` and `Red
|
|||||||
- PHP-FPM
|
- PHP-FPM
|
||||||
- HHVM
|
- HHVM
|
||||||
- **Message Queueing Systems:**
|
- **Message Queueing Systems:**
|
||||||
- Beanstalkd (+ Beanstalkd Console)
|
- Beanstalkd
|
||||||
- RabbitMQ (+ RabbitMQ Console)
|
- Beanstalkd Console
|
||||||
|
- RabbitMQ
|
||||||
|
- RabbitMQ Console
|
||||||
- **Tools:**
|
- **Tools:**
|
||||||
- Workspace (PHP7-CLI, Composer, Git, Node, Gulp, SQLite, xDebug, Vim...)
|
|
||||||
- PhpMyAdmin
|
- PhpMyAdmin
|
||||||
- PgAdmin
|
- PgAdmin
|
||||||
- ElasticSearch
|
- ElasticSearch
|
||||||
|
- Selenium
|
||||||
|
- Workspace
|
||||||
|
- PHP7-CLI
|
||||||
|
- Composer
|
||||||
|
- Git
|
||||||
|
- Node
|
||||||
|
- Gulp
|
||||||
|
- SQLite
|
||||||
|
- xDebug
|
||||||
|
- Envoy
|
||||||
|
- Vim
|
||||||
|
- ... Many other supported tools are not documented. (Will be updated soon)
|
||||||
|
|
||||||
>If you can't find your Software, build it yourself and add it to this list. Contributions are welcomed :)
|
>If you can't find your Software, build it yourself and add it to this list. Contributions are welcomed :)
|
||||||
|
|
||||||
@ -151,12 +202,17 @@ Let's see how easy it is to install `NGINX`, `PHP`, `Composer`, `MySQL` and `Red
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="what-is-docker"></a>
|
<a name="what-is-docker"></a>
|
||||||
### What is Docker?
|
### What is Docker?
|
||||||
|
|
||||||
[Docker](https://www.docker.com) is an open-source project that automates the deployment of applications inside software containers, by providing an additional layer of abstraction and automation of [operating-system-level virtualization](https://en.wikipedia.org/wiki/Operating-system-level_virtualization) on Linux, Mac OS and Windows.
|
[Docker](https://www.docker.com) is an open-source project that automates the deployment of applications inside software containers, by providing an additional layer of abstraction and automation of [operating-system-level virtualization](https://en.wikipedia.org/wiki/Operating-system-level_virtualization) on Linux, Mac OS and Windows.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="why-docker-not-vagrant"></a>
|
<a name="why-docker-not-vagrant"></a>
|
||||||
### Why Docker not Vagrant!?
|
### Why Docker not Vagrant!?
|
||||||
|
|
||||||
@ -169,6 +225,10 @@ In addition to the speed, Docker gives tons of features that cannot be achieved
|
|||||||
Most importantly Docker can run on Development and on Production (same environment everywhere). While Vagrant is designed for Development only, (so you have to re-provision your server on Production every time).
|
Most importantly Docker can run on Development and on Production (same environment everywhere). While Vagrant is designed for Development only, (so you have to re-provision your server on Production every time).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="laradock-vs-homestead"></a>
|
<a name="laradock-vs-homestead"></a>
|
||||||
### Laradock VS Homestead (For Laravel Developers)
|
### Laradock VS Homestead (For Laravel Developers)
|
||||||
|
|
||||||
@ -186,6 +246,7 @@ Running a virtual Container is much faster than running a full virtual Machine.
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Demo"></a>
|
<a name="Demo"></a>
|
||||||
## Demo Video
|
## Demo Video
|
||||||
|
|
||||||
@ -198,6 +259,9 @@ What's better than a **Demo Video**:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Requirements"></a>
|
<a name="Requirements"></a>
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
@ -206,6 +270,9 @@ What's better than a **Demo Video**:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Installation"></a>
|
<a name="Installation"></a>
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@ -301,10 +368,10 @@ Do the same for each project `project2.conf`, `project3.conf`,...
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Usage"></a>
|
<a name="Usage"></a>
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
|
||||||
**Read Before starting:**
|
**Read Before starting:**
|
||||||
|
|
||||||
If you are using **Docker Toolbox** (VM), do one of the following:
|
If you are using **Docker Toolbox** (VM), do one of the following:
|
||||||
@ -333,9 +400,7 @@ docker-compose up -d nginx mysql
|
|||||||
|
|
||||||
You can select your own combination of Containers form the list below:
|
You can select your own combination of Containers form the list below:
|
||||||
|
|
||||||
`nginx`, `hhvm`, `php-fpm`, `mysql`, `redis`, `postgres`, `mariadb`, `neo4j`, `mongo`, `apache2`, `caddy`, `memcached`, `beanstalkd`, `beanstalkd-console`, `rabbitmq`, `workspace`, `phpmyadmin`, `aerospike`, `pgadmin`, `elasticsearch`.
|
`nginx`, `hhvm`, `php-fpm`, `mysql`, `redis`, `postgres`, `mariadb`, `neo4j`, `mongo`, `apache2`, `caddy`, `memcached`, `beanstalkd`, `beanstalkd-console`, `rabbitmq`, `workspace`, `phpmyadmin`, `aerospike`, `pgadmin`, `elasticsearch`, `rethinkdb`.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
@ -352,8 +417,6 @@ docker exec -it {workspace-container-id} bash
|
|||||||
|
|
||||||
**Note:** You can add `--user=laradock` (example `docker-compose exec --user=laradock workspace bash`) to have files created as your host's user. (you can change the PUID (User id) and PGID (group id) variables from the `docker-compose.yml`).
|
**Note:** You can add `--user=laradock` (example `docker-compose exec --user=laradock workspace bash`) to have files created as your host's user. (you can change the PUID (User id) and PGID (group id) variables from the `docker-compose.yml`).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
3 - Edit your project configurations.
|
3 - Edit your project configurations.
|
||||||
|
|
||||||
@ -365,30 +428,35 @@ DB_HOST=mysql
|
|||||||
|
|
||||||
*If you want to use Laravel and you don't have it installed yet, see [How to Install Laravel in a Docker Container](#Install-Laravel).*
|
*If you want to use Laravel and you don't have it installed yet, see [How to Install Laravel in a Docker Container](#Install-Laravel).*
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
4 - Open your browser and visit your localhost address (`http://localhost/`).
|
4 - Open your browser and visit your localhost address (`http://localhost/`).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
**Debugging**: if you are facing any problem here check the [Debugging](#debugging) section.
|
**Debugging**: if you are facing any problem here check the [Debugging](#debugging) section.
|
||||||
|
|
||||||
If you need a special support. Contact me, more details in the [Help & Questions](#Help) section.
|
If you need a special support. Contact me, more details in the [Help & Questions](#Help) section.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Documentation"></a>
|
<a name="Documentation"></a>
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Docker"></a>
|
<a name="Docker"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="List-current-running-Containers"></a>
|
<a name="List-current-running-Containers"></a>
|
||||||
### List current running Containers
|
### List current running Containers
|
||||||
```bash
|
```bash
|
||||||
@ -404,6 +472,7 @@ docker-compose ps
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Close-all-running-Containers"></a>
|
<a name="Close-all-running-Containers"></a>
|
||||||
### Close all running Containers
|
### Close all running Containers
|
||||||
@ -434,7 +503,6 @@ docker-compose down
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Enter-Container"></a>
|
<a name="Enter-Container"></a>
|
||||||
### Enter a Container (run commands in a running Container)
|
### Enter a Container (run commands in a running Container)
|
||||||
@ -460,7 +528,6 @@ docker-compose exec mysql bash
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Edit-Container"></a>
|
<a name="Edit-Container"></a>
|
||||||
### Edit default container configuration
|
### Edit default container configuration
|
||||||
@ -489,8 +556,6 @@ Change Redis defaut port to 1111:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Edit-a-Docker-Image"></a>
|
<a name="Edit-a-Docker-Image"></a>
|
||||||
### Edit a Docker Image
|
### Edit a Docker Image
|
||||||
@ -513,8 +578,6 @@ More info on Containers rebuilding [here](#Build-Re-build-Containers).
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Build-Re-build-Containers"></a>
|
<a name="Build-Re-build-Containers"></a>
|
||||||
### Build/Re-build Containers
|
### Build/Re-build Containers
|
||||||
@ -536,6 +599,7 @@ You might use the `--no-cache` option if you want full rebuilding (`docker-compo
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Add-Docker-Images"></a>
|
<a name="Add-Docker-Images"></a>
|
||||||
### Add more Software (Docker Images)
|
### Add more Software (Docker Images)
|
||||||
@ -547,9 +611,6 @@ To add an image (software), just edit the `docker-compose.yml` and add your cont
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="View-the-Log-files"></a>
|
<a name="View-the-Log-files"></a>
|
||||||
### View the Log files
|
### View the Log files
|
||||||
@ -566,8 +627,6 @@ docker logs {container-name}
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="PHP"></a>
|
<a name="PHP"></a>
|
||||||
|
|
||||||
@ -590,9 +649,6 @@ The PHP-CLI extensions should be installed in `workspace/Dockerfile`.
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Change-the-PHP-FPM-Version"></a>
|
<a name="Change-the-PHP-FPM-Version"></a>
|
||||||
### Change the (PHP-FPM) Version
|
### Change the (PHP-FPM) Version
|
||||||
@ -600,6 +656,7 @@ By default **PHP-FPM 7.0** is running.
|
|||||||
|
|
||||||
>The PHP-FPM is responsible of serving your application code, you don't have to change the PHP-CLI version if you are planning to run your application on different PHP-FPM version.
|
>The PHP-FPM is responsible of serving your application code, you don't have to change the PHP-CLI version if you are planning to run your application on different PHP-FPM version.
|
||||||
|
|
||||||
|
|
||||||
#### A) Switch from PHP `7.0` to PHP `5.6`
|
#### A) Switch from PHP `7.0` to PHP `5.6`
|
||||||
|
|
||||||
1 - Open the `docker-compose.yml`.
|
1 - Open the `docker-compose.yml`.
|
||||||
@ -619,7 +676,7 @@ By default **PHP-FPM 7.0** is running.
|
|||||||
4 - Finally rebuild the container
|
4 - Finally rebuild the container
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker-compose build php
|
docker-compose build php-fpm
|
||||||
```
|
```
|
||||||
|
|
||||||
> For more details about the PHP base image, visit the [official PHP docker images](https://hub.docker.com/_/php/).
|
> For more details about the PHP base image, visit the [official PHP docker images](https://hub.docker.com/_/php/).
|
||||||
@ -646,12 +703,6 @@ We do not natively support PHP 5.5 anymore, but you can get it in few steps:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Change-the-PHP-CLI-Version"></a>
|
<a name="Change-the-PHP-CLI-Version"></a>
|
||||||
### Change the PHP-CLI Version
|
### Change the PHP-CLI Version
|
||||||
@ -666,6 +717,8 @@ Right now you have to manually edit the `Dockerfile` or create a new one like it
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Install-xDebug"></a>
|
<a name="Install-xDebug"></a>
|
||||||
### Install xDebug
|
### Install xDebug
|
||||||
@ -712,6 +765,10 @@ xdebug.remote_connect_back=1
|
|||||||
For information on how to configure xDebug with your IDE and work it out, check this [Repository](https://github.com/LarryEitel/laravel-laradock-phpstorm).
|
For information on how to configure xDebug with your IDE and work it out, check this [Repository](https://github.com/LarryEitel/laravel-laradock-phpstorm).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Control-xDebug"></a>
|
<a name="Control-xDebug"></a>
|
||||||
### Start/Stop xDebug:
|
### Start/Stop xDebug:
|
||||||
@ -728,12 +785,15 @@ To control the behavior of xDebug (in the `php-fpm` Container), you can run the
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Production"></a>
|
<a name="Production"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="LaraDock-for-Production"></a>
|
<a name="LaraDock-for-Production"></a>
|
||||||
### Prepare LaraDock for Production
|
### Prepare LaraDock for Production
|
||||||
@ -765,19 +825,14 @@ To learn more about how Docker publishes ports, please read [this excellent post
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Laravel"></a>
|
<a name="Laravel"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Install-Laravel"></a>
|
<a name="Install-Laravel"></a>
|
||||||
### Install Laravel from a Docker Container
|
### Install Laravel from a Docker Container
|
||||||
|
|
||||||
@ -819,6 +874,9 @@ cd my-cool-app
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Run-Artisan-Commands"></a>
|
<a name="Run-Artisan-Commands"></a>
|
||||||
### Run Artisan Commands
|
### Run Artisan Commands
|
||||||
@ -858,6 +916,11 @@ Composer update
|
|||||||
phpunit
|
phpunit
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Use-Redis"></a>
|
<a name="Use-Redis"></a>
|
||||||
### Use Redis
|
### Use Redis
|
||||||
@ -910,6 +973,7 @@ composer require predis/predis:^1.0
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Use-Mongo"></a>
|
<a name="Use-Mongo"></a>
|
||||||
### Use Mongo
|
### Use Mongo
|
||||||
@ -1003,7 +1067,7 @@ More details about this [here](https://github.com/jenssegers/laravel-mongodb#ins
|
|||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Use-phpMyAdmin"></a>
|
<a name="Use-phpMyAdmin"></a>
|
||||||
### Use phpMyAdmin
|
### Use PhpMyAdmin
|
||||||
|
|
||||||
1 - Run the phpMyAdmin Container (`phpmyadmin`) with the `docker-compose up` command. Example:
|
1 - Run the phpMyAdmin Container (`phpmyadmin`) with the `docker-compose up` command. Example:
|
||||||
|
|
||||||
@ -1018,9 +1082,13 @@ docker-compose up -d mariadb phpmyadmin
|
|||||||
2 - Open your browser and visit the localhost on port **8080**: `http://localhost:8080`
|
2 - Open your browser and visit the localhost on port **8080**: `http://localhost:8080`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Use-pgAdmin"></a>
|
<a name="Use-pgAdmin"></a>
|
||||||
### Use pgAdmin
|
### Use PgAdmin
|
||||||
|
|
||||||
1 - Run the pgAdmin Container (`pgadmin`) with the `docker-compose up` command. Example:
|
1 - Run the pgAdmin Container (`pgadmin`) with the `docker-compose up` command. Example:
|
||||||
|
|
||||||
@ -1031,11 +1099,57 @@ docker-compose up -d postgres pgadmin
|
|||||||
2 - Open your browser and visit the localhost on port **5050**: `http://localhost:5050`
|
2 - Open your browser and visit the localhost on port **5050**: `http://localhost:5050`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<a name="Use-Beanstalkd"></a>
|
||||||
|
### Use Beanstalkd
|
||||||
|
|
||||||
|
1 - Run the Beanstalkd Container:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose up -d beanstalkd
|
||||||
|
```
|
||||||
|
|
||||||
|
2 - Configure Laravel to connect to that container by editing the `config/queue.php` config file.
|
||||||
|
|
||||||
|
a. first set `beanstalkd` as default queue driver
|
||||||
|
b. set the queue host to beanstalkd : `QUEUE_HOST=beanstalkd`
|
||||||
|
|
||||||
|
*beanstalkd is now available on default port `11300`.*
|
||||||
|
|
||||||
|
3 - Require the dependecy package [pda/pheanstalk](https://github.com/pda/pheanstalk) using composer.
|
||||||
|
|
||||||
|
|
||||||
|
Optionally you can use the Beanstalkd Console Container to manage your Queues from a web interface.
|
||||||
|
|
||||||
|
1 - Run the Beanstalkd Console Container:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose up -d beanstalkd-console
|
||||||
|
```
|
||||||
|
|
||||||
|
2 - Open your browser and visit `http://localhost:2080/`
|
||||||
|
|
||||||
|
3 - Add the server
|
||||||
|
|
||||||
|
- Host: beanstalkd
|
||||||
|
- Port: 11300
|
||||||
|
|
||||||
|
4 - Done.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Use-ElasticSearch"></a>
|
<a name="Use-ElasticSearch"></a>
|
||||||
### Use ElasticSearch
|
### Use ElasticSearch
|
||||||
|
|
||||||
1 - Run the ElasticSearch Container (`elasticsearch`) with the `docker-compose up` command. Example:
|
1 - Run the ElasticSearch Container (`elasticsearch`) with the `docker-compose up` command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker-compose up -d elasticsearch
|
docker-compose up -d elasticsearch
|
||||||
@ -1043,7 +1157,8 @@ docker-compose up -d elasticsearch
|
|||||||
|
|
||||||
2 - Open your browser and visit the localhost on port **9200**: `http://localhost:9200`
|
2 - Open your browser and visit the localhost on port **9200**: `http://localhost:9200`
|
||||||
|
|
||||||
### Install ElasticSearch Plugin
|
|
||||||
|
#### Install ElasticSearch Plugin
|
||||||
|
|
||||||
1 - Install the ElasticSearch plugin like [delete-by-query](https://www.elastic.co/guide/en/elasticsearch/plugins/current/plugins-delete-by-query.html).
|
1 - Install the ElasticSearch plugin like [delete-by-query](https://www.elastic.co/guide/en/elasticsearch/plugins/current/plugins-delete-by-query.html).
|
||||||
|
|
||||||
@ -1062,15 +1177,77 @@ docker restart {container-name}
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<a name="Use-Selenium"></a>
|
||||||
|
### Use Selenium
|
||||||
|
|
||||||
|
1 - Run the Selenium Container (`selenium`) with the `docker-compose up` command. Example:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose up -d selenium
|
||||||
|
```
|
||||||
|
|
||||||
|
2 - Open your browser and visit the localhost on port **4444** at the following URL: `http://localhost:4444/wd/hub`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<a name="Use-RethinkDB"></a>
|
||||||
|
### Use RethinkDB
|
||||||
|
|
||||||
|
The RethinkDB is an open-source Database for Real-time Web ([RethinkDB](https://rethinkdb.com/)).
|
||||||
|
A package ([Laravel RethinkDB](https://github.com/duxet/laravel-rethinkdb)) is being developed and was released a version for Laravel 5.2 (experimental).
|
||||||
|
|
||||||
|
1 - Run the RethinkDB Container (`rethinkdb`) with the `docker-compose up` command.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose up -d rethinkdb
|
||||||
|
```
|
||||||
|
|
||||||
|
2 - Access the RethinkDB Administration Console [http://localhost:8090/#tables](http://localhost:8090/#tables) for create a database called `database`.
|
||||||
|
|
||||||
|
3 - Add the RethinkDB configurations to the `config/database.php` configuration file:
|
||||||
|
|
||||||
|
```php
|
||||||
|
'connections' => [
|
||||||
|
|
||||||
|
'rethinkdb' => [
|
||||||
|
'name' => 'rethinkdb',
|
||||||
|
'driver' => 'rethinkdb',
|
||||||
|
'host' => env('DB_HOST', 'rethinkdb'),
|
||||||
|
'port' => env('DB_PORT', 28015),
|
||||||
|
'database' => env('DB_DATABASE', 'test'),
|
||||||
|
]
|
||||||
|
|
||||||
|
// ...
|
||||||
|
|
||||||
|
],
|
||||||
|
```
|
||||||
|
|
||||||
|
4 - Open your Laravel's `.env` file and update the following variables:
|
||||||
|
|
||||||
|
- set the `DB_CONNECTION` to your `rethinkdb`.
|
||||||
|
- set the `DB_HOST` to `rethinkdb`.
|
||||||
|
- set the `DB_PORT` to `28015`.
|
||||||
|
- set the `DB_DATABASE` to `database`.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="CodeIgniter"></a>
|
<a name="CodeIgniter"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="Install-CodeIgniter"></a>
|
<a name="Install-CodeIgniter"></a>
|
||||||
### Install CodeIgniter
|
### Install CodeIgniter
|
||||||
|
|
||||||
@ -1094,8 +1271,8 @@ To install CodeIgniter 3 on Laradock all you have to do is the following simple
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="Change-the-timezone"></a>
|
<a name="Change-the-timezone"></a>
|
||||||
### Change the timezone
|
### Change the timezone
|
||||||
|
|
||||||
@ -1114,6 +1291,12 @@ For example, if I want the timezone to be `New York`:
|
|||||||
|
|
||||||
We also recommend [setting the timezone in Laravel](http://www.camroncade.com/managing-timezones-with-laravel/).
|
We also recommend [setting the timezone in Laravel](http://www.camroncade.com/managing-timezones-with-laravel/).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="CronJobs"></a>
|
<a name="CronJobs"></a>
|
||||||
### Adding cron jobs
|
### Adding cron jobs
|
||||||
|
|
||||||
@ -1128,6 +1311,12 @@ You can add your cron jobs to `workspace/crontab/root` after the `php artisan` l
|
|||||||
|
|
||||||
Make sure you [change the timezone](#Change-the-timezone) if you don't want to use the default (UTC).
|
Make sure you [change the timezone](#Change-the-timezone) if you don't want to use the default (UTC).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="Workspace-ssh"></a>
|
<a name="Workspace-ssh"></a>
|
||||||
### Access workspace via ssh
|
### Access workspace via ssh
|
||||||
|
|
||||||
@ -1142,6 +1331,12 @@ To change the default forwarded port for ssh:
|
|||||||
...
|
...
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="MySQL-access-from-host"></a>
|
<a name="MySQL-access-from-host"></a>
|
||||||
### MySQL access from host
|
### MySQL access from host
|
||||||
|
|
||||||
@ -1152,6 +1347,12 @@ ports:
|
|||||||
- "3306:3306"
|
- "3306:3306"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="MySQL-root-access"></a>
|
<a name="MySQL-root-access"></a>
|
||||||
### MySQL root access
|
### MySQL root access
|
||||||
|
|
||||||
@ -1166,6 +1367,11 @@ The default username and password for the root mysql user are `root` and `root `
|
|||||||
4 - Run any commands `show databases`, `show tables`, `select * from.....`.
|
4 - Run any commands `show databases`, `show tables`, `select * from.....`.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="Change-MySQL-port"></a>
|
<a name="Change-MySQL-port"></a>
|
||||||
### Change MySQL port
|
### Change MySQL port
|
||||||
|
|
||||||
@ -1178,6 +1384,12 @@ port=1234
|
|||||||
|
|
||||||
If you need <a href="#MySQL-access-from-host">MySQL access from your host</a>, do not forget to change the internal port number (`"3306:3306"` -> `"3306:1234"`) in the docker-compose configuration file.
|
If you need <a href="#MySQL-access-from-host">MySQL access from your host</a>, do not forget to change the internal port number (`"3306:3306"` -> `"3306:1234"`) in the docker-compose configuration file.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
<a name="Use-custom-Domain"></a>
|
<a name="Use-custom-Domain"></a>
|
||||||
### Use custom Domain (instead of the Docker IP)
|
### Use custom Domain (instead of the Docker IP)
|
||||||
|
|
||||||
@ -1200,6 +1412,9 @@ server_name laravel.dev;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Enable-Global-Composer-Build-Install"></a>
|
<a name="Enable-Global-Composer-Build-Install"></a>
|
||||||
### Enable Global Composer Build Install
|
### Enable Global Composer Build Install
|
||||||
@ -1227,6 +1442,8 @@ It should be like this:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Install-Prestissimo"></a>
|
<a name="Install-Prestissimo"></a>
|
||||||
### Install Prestissimo
|
### Install Prestissimo
|
||||||
@ -1248,6 +1465,8 @@ c - Re-build the Workspace Container `docker-compose build workspace`
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Install-Node"></a>
|
<a name="Install-Node"></a>
|
||||||
### Install Node + NVM
|
### Install Node + NVM
|
||||||
@ -1271,6 +1490,11 @@ It should be like this:
|
|||||||
|
|
||||||
3 - Re-build the container `docker-compose build workspace`
|
3 - Re-build the container `docker-compose build workspace`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Install-Yarn"></a>
|
<a name="Install-Yarn"></a>
|
||||||
### Install Node + YARN
|
### Install Node + YARN
|
||||||
@ -1295,6 +1519,11 @@ It should be like this:
|
|||||||
|
|
||||||
3 - Re-build the container `docker-compose build workspace`
|
3 - Re-build the container `docker-compose build workspace`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Install-Aerospike-Extension"></a>
|
<a name="Install-Aerospike-Extension"></a>
|
||||||
### Install Aerospike extension
|
### Install Aerospike extension
|
||||||
@ -1330,9 +1559,50 @@ It should be like this:
|
|||||||
|
|
||||||
2 - Re-build the containers `docker-compose build workspace php-fpm`
|
2 - Re-build the containers `docker-compose build workspace php-fpm`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<a name="Install-Laravel-Envoy"></a>
|
||||||
|
### Install Laravel Envoy (Envoy Task Runner)
|
||||||
|
|
||||||
|
1 - Open the `docker-compose.yml` file
|
||||||
|
<br>
|
||||||
|
2 - Search for the `INSTALL_LARAVEL_ENVOY` argument under the Workspace Container
|
||||||
|
<br>
|
||||||
|
3 - Set it to `true`
|
||||||
|
<br>
|
||||||
|
|
||||||
|
It should be like this:
|
||||||
|
|
||||||
|
```yml
|
||||||
|
workspace:
|
||||||
|
build:
|
||||||
|
context: ./workspace
|
||||||
|
args:
|
||||||
|
- INSTALL_LARAVEL_ENVOY=true
|
||||||
|
...
|
||||||
|
```
|
||||||
|
|
||||||
|
4 - Re-build the containers `docker-compose build workspace`
|
||||||
|
|
||||||
|
####[Laravel Envoy Documentation Here](https://laravel.com/docs/5.3/envoy)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="debugging"></a>
|
<a name="debugging"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### PHPStorm
|
### PHPStorm
|
||||||
Remote debug Laravel web and phpunit tests.
|
Remote debug Laravel web and phpunit tests.
|
||||||
|
|
||||||
@ -1342,13 +1612,20 @@ Remote debug Laravel web and phpunit tests.
|
|||||||
<br>
|
<br>
|
||||||
<a name="Misc"></a>
|
<a name="Misc"></a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Miscellaneous
|
### Miscellaneous
|
||||||
|
|
||||||
|
|
||||||
*Here's a list of the common problems you might face, and the possible solutions.*
|
*Here's a list of the common problems you might face, and the possible solutions.*
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### I see a blank (white) page instead of the Laravel 'Welcome' page!
|
#### I see a blank (white) page instead of the Laravel 'Welcome' page!
|
||||||
|
|
||||||
Run the following command from the Laravel root directory:
|
Run the following command from the Laravel root directory:
|
||||||
@ -1358,18 +1635,28 @@ sudo chmod -R 777 storage bootstrap/cache
|
|||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### I see "Welcome to nginx" instead of the Laravel App!
|
#### I see "Welcome to nginx" instead of the Laravel App!
|
||||||
|
|
||||||
Use `http://127.0.0.1` instead of `http://localhost` in your browser.
|
Use `http://127.0.0.1` instead of `http://localhost` in your browser.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### I see an error message containing `address already in use` or `port is already allocated`
|
#### I see an error message containing `address already in use` or `port is already allocated`
|
||||||
|
|
||||||
Make sure the ports for the services that you are trying to run (22, 80, 443, 3306, etc.) are not being used already by other programs on the host, such as a built in `apache`/`httpd` service or other development tools you have installed.
|
Make sure the ports for the services that you are trying to run (22, 80, 443, 3306, etc.) are not being used already by other programs on the host, such as a built in `apache`/`httpd` service or other development tools you have installed.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### I get Nginx error 404 Not Found on Windows.
|
#### I get Nginx error 404 Not Found on Windows.
|
||||||
|
|
||||||
1. Go to docker Settings on your Windows machine.
|
1. Go to docker Settings on your Windows machine.
|
||||||
@ -1377,6 +1664,11 @@ Make sure the ports for the services that you are trying to run (22, 80, 443, 33
|
|||||||
3. Enter your windows username and password.
|
3. Enter your windows username and password.
|
||||||
4. Go to the `reset` tab and click restart docker.
|
4. Go to the `reset` tab and click restart docker.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#### I get Mysql connection refused
|
#### I get Mysql connection refused
|
||||||
|
|
||||||
This error sometimes happens because your Laravel application isn't running on the container localhost IP (Which is 127.0.0.1). Steps to fix it:
|
This error sometimes happens because your Laravel application isn't running on the container localhost IP (Which is 127.0.0.1). Steps to fix it:
|
||||||
@ -1390,11 +1682,12 @@ This error sometimes happens because your Laravel application isn't running on t
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="upgrading-laradock"></a>
|
<a name="upgrading-laradock"></a>
|
||||||
### Upgrading LaraDock
|
### Upgrading LaraDock
|
||||||
|
|
||||||
|
|
||||||
Moving from Docker Toolbox (VirtualBox) to Docker Native (for Mac/Windows). Requires upgrading LaraDock from v3.* to v4.*:
|
Moving from Docker Toolbox (VirtualBox) to Docker Native (for Mac/Windows). Requires upgrading LaraDock from v3.* to v4.*:
|
||||||
|
|
||||||
1. Stop the docker vm `docker-machine stop {default}`
|
1. Stop the docker vm `docker-machine stop {default}`
|
||||||
@ -1411,7 +1704,6 @@ Moving from Docker Toolbox (VirtualBox) to Docker Native (for Mac/Windows). Requ
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
@ -1419,6 +1711,11 @@ This little project was built by one man who has a full time job and many respon
|
|||||||
|
|
||||||
#### Read the [Contribution Guidelines](https://github.com/LaraDock/laradock/blob/master/CONTRIBUTING.md).
|
#### Read the [Contribution Guidelines](https://github.com/LaraDock/laradock/blob/master/CONTRIBUTING.md).
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="related-projects"></a>
|
<a name="related-projects"></a>
|
||||||
## Related Projects
|
## Related Projects
|
||||||
@ -1436,6 +1733,11 @@ These Docker Compose projects have piqued our interest:
|
|||||||
|
|
||||||
If you want your project listed here, please open an issue.
|
If you want your project listed here, please open an issue.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<a name="Help"></a>
|
<a name="Help"></a>
|
||||||
## Help & Questions
|
## Help & Questions
|
||||||
@ -1449,40 +1751,25 @@ For special help with Docker and/or Laravel, you can schedule a live call with t
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## Credits
|
## Credits
|
||||||
|
|
||||||
**Creator:**
|
**Super Admins:**
|
||||||
|
|
||||||
- [Mahmoud Zalt](https://github.com/Mahmoudz) [ [Twitter](https://twitter.com/Mahmoud_Zalt) | [Personal Site](http://zalt.me) | [Linkedin](https://www.linkedin.com/in/mahmoudzalt) ]
|
|
||||||
|
|
||||||
**Admins:**
|
|
||||||
|
|
||||||
|
- [Mahmoud Zalt](https://github.com/Mahmoudz) (mahmoudz) [ [Twitter](https://twitter.com/Mahmoud_Zalt) | [Personal Site](http://zalt.me) | [Linkedin](https://www.linkedin.com/in/mahmoudzalt) ]
|
||||||
- [Bo-Yi Wu](https://github.com/appleboy) (appleboy)
|
- [Bo-Yi Wu](https://github.com/appleboy) (appleboy)
|
||||||
- [Philippe Trépanier](https://github.com/philtrep) (philtrep)
|
- [Philippe Trépanier](https://github.com/philtrep) (philtrep)
|
||||||
|
- YOU?! Join Us.
|
||||||
|
|
||||||
**Main Contributors:**
|
**Amazing Contributors:**
|
||||||
|
|
||||||
- [Francis Lavoie](https://github.com/francislavoie) (francislavoie)
|
|
||||||
- [luciano-jr](https://github.com/luciano-jr)
|
|
||||||
- [Zhqagp](https://github.com/zhqagp)
|
|
||||||
- [Tim B.](https://github.com/tjb328) (tjb328)
|
|
||||||
- [MidasCodeBreaker](https://github.com/midascodebreaker)
|
|
||||||
- [Larry Eitel](https://github.com/LarryEitel)
|
|
||||||
- [Suteepat](https://github.com/tianissimo) (tianissimo)
|
|
||||||
- [David](https://github.com/davidavz) (davidavz)
|
|
||||||
- [Lialosiu](https://github.com/lialosiu)
|
|
||||||
- [Eric Pfeiffer](https://github.com/computerfr33k) (computerfr33k)
|
|
||||||
- [Orette](https://github.com/orette)
|
|
||||||
- [Jack Fletcher](https://github.com/Kauhat) (Kauhat)
|
|
||||||
- [Amin Mkh](https://github.com/AminMkh)
|
|
||||||
- [Matthew Tonkin Dunn](https://github.com/mattythebatty) (mattythebatty)
|
|
||||||
- [Zhivitsa Kirill](https://github.com/zhikiri) (zhikiri)
|
|
||||||
- [Benmag](https://github.com/benmag)
|
|
||||||
|
|
||||||
**Other Contributors & Supporters:**
|
|
||||||
|
|
||||||
- [Contributors](https://github.com/LaraDock/laradock/graphs/contributors)
|
- [Contributors](https://github.com/LaraDock/laradock/graphs/contributors)
|
||||||
- [Supporters](https://github.com/LaraDock/laradock/issues?utf8=%E2%9C%93&q=)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
|
@ -25,6 +25,7 @@ services:
|
|||||||
- INSTALL_V8JS_EXTENSION=false
|
- INSTALL_V8JS_EXTENSION=false
|
||||||
- COMPOSER_GLOBAL_INSTALL=false
|
- COMPOSER_GLOBAL_INSTALL=false
|
||||||
- INSTALL_WORKSPACE_SSH=false
|
- INSTALL_WORKSPACE_SSH=false
|
||||||
|
- INSTALL_LARAVEL_ENVOY=false
|
||||||
- PUID=1000
|
- PUID=1000
|
||||||
- PGID=1000
|
- PGID=1000
|
||||||
- NODE_VERSION=stable
|
- NODE_VERSION=stable
|
||||||
@ -49,6 +50,7 @@ services:
|
|||||||
- INSTALL_SOAP=false
|
- INSTALL_SOAP=false
|
||||||
- INSTALL_MONGO=false
|
- INSTALL_MONGO=false
|
||||||
- INSTALL_ZIP_ARCHIVE=false
|
- INSTALL_ZIP_ARCHIVE=false
|
||||||
|
- INSTALL_BCMATH=false
|
||||||
- INSTALL_MEMCACHED=false
|
- INSTALL_MEMCACHED=false
|
||||||
- INSTALL_OPCACHE=false
|
- INSTALL_OPCACHE=false
|
||||||
- INSTALL_AEROSPIKE_EXTENSION=false
|
- INSTALL_AEROSPIKE_EXTENSION=false
|
||||||
@ -189,6 +191,15 @@ services:
|
|||||||
volumes:
|
volumes:
|
||||||
- mongo:/data/db
|
- mongo:/data/db
|
||||||
|
|
||||||
|
### RethinkDB Container #######################################
|
||||||
|
|
||||||
|
rethinkdb:
|
||||||
|
build: ./rethinkdb
|
||||||
|
ports:
|
||||||
|
- "8090:8080"
|
||||||
|
volumes:
|
||||||
|
- rethinkdb:/data/rethinkdb_data
|
||||||
|
|
||||||
### Redis Container #########################################
|
### Redis Container #########################################
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
@ -306,13 +317,20 @@ services:
|
|||||||
build: ./elasticsearch
|
build: ./elasticsearch
|
||||||
volumes:
|
volumes:
|
||||||
- elasticsearch-data:/usr/share/elasticsearch/data
|
- elasticsearch-data:/usr/share/elasticsearch/data
|
||||||
- elasticsearch-pkugins:/usr/share/elasticsearch/data
|
- elasticsearch-plugins:/usr/share/elasticsearch/data
|
||||||
ports:
|
ports:
|
||||||
- "9200:9200"
|
- "9200:9200"
|
||||||
- "9300:9300"
|
- "9300:9300"
|
||||||
links:
|
links:
|
||||||
- php-fpm
|
- php-fpm
|
||||||
|
|
||||||
|
### Selenium Container #########################################
|
||||||
|
|
||||||
|
selenium:
|
||||||
|
build: ./selenium
|
||||||
|
ports:
|
||||||
|
- "4444:4444"
|
||||||
|
|
||||||
### Volumes Setup ###########################################
|
### Volumes Setup ###########################################
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
@ -330,6 +348,8 @@ volumes:
|
|||||||
driver: "local"
|
driver: "local"
|
||||||
mongo:
|
mongo:
|
||||||
driver: "local"
|
driver: "local"
|
||||||
|
rethinkdb:
|
||||||
|
driver: "local"
|
||||||
phpmyadmin:
|
phpmyadmin:
|
||||||
driver: "local"
|
driver: "local"
|
||||||
aerospike:
|
aerospike:
|
||||||
@ -338,7 +358,7 @@ volumes:
|
|||||||
driver: "local"
|
driver: "local"
|
||||||
elasticsearch-data:
|
elasticsearch-data:
|
||||||
driver: "local"
|
driver: "local"
|
||||||
elasticsearch-pkugins:
|
elasticsearch-plugins:
|
||||||
driver: "local"
|
driver: "local"
|
||||||
sessions: ## nothing is connected to this (- ./data/sessions:/sessions)
|
sessions: ## nothing is connected to this (- ./data/sessions:/sessions)
|
||||||
driver: "local"
|
driver: "local"
|
||||||
|
@ -84,6 +84,16 @@ RUN if [ ${INSTALL_ZIP_ARCHIVE} = true ]; then \
|
|||||||
docker-php-ext-enable zip \
|
docker-php-ext-enable zip \
|
||||||
;fi
|
;fi
|
||||||
|
|
||||||
|
#####################################
|
||||||
|
# bcmath:
|
||||||
|
#####################################
|
||||||
|
|
||||||
|
ARG INSTALL_BCMATH=false
|
||||||
|
RUN if [ ${INSTALL_BCMATH} = true ]; then \
|
||||||
|
# Install the bcmath extension
|
||||||
|
docker-php-ext-install bcmath \
|
||||||
|
;fi
|
||||||
|
|
||||||
#####################################
|
#####################################
|
||||||
# PHP Memcached:
|
# PHP Memcached:
|
||||||
#####################################
|
#####################################
|
||||||
|
@ -85,6 +85,16 @@ RUN if [ ${INSTALL_ZIP_ARCHIVE} = true ]; then \
|
|||||||
docker-php-ext-enable zip \
|
docker-php-ext-enable zip \
|
||||||
;fi
|
;fi
|
||||||
|
|
||||||
|
#####################################
|
||||||
|
# bcmath:
|
||||||
|
#####################################
|
||||||
|
|
||||||
|
ARG INSTALL_BCMATH=false
|
||||||
|
RUN if [ ${INSTALL_BCMATH} = true ]; then \
|
||||||
|
# Install the bcmath extension
|
||||||
|
docker-php-ext-install bcmath \
|
||||||
|
;fi
|
||||||
|
|
||||||
#####################################
|
#####################################
|
||||||
# PHP Memcached:
|
# PHP Memcached:
|
||||||
#####################################
|
#####################################
|
||||||
|
11
rethinkdb/Dockerfile
Normal file
11
rethinkdb/Dockerfile
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
FROM rethinkdb:latest
|
||||||
|
|
||||||
|
MAINTAINER Cristian Mello <cristianc.mello@gmail.com>
|
||||||
|
|
||||||
|
VOLUME /data/rethinkdb_data
|
||||||
|
|
||||||
|
RUN cp /etc/rethinkdb/default.conf.sample /etc/rethinkdb/instances.d/instance1.conf
|
||||||
|
|
||||||
|
CMD ["rethinkdb", "--bind", "all"]
|
||||||
|
|
||||||
|
EXPOSE 8080
|
5
selenium/Dockerfile
Normal file
5
selenium/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
FROM selenium/standalone-chrome
|
||||||
|
|
||||||
|
MAINTAINER Edmund Luong <edmundvmluong@gmail.com>
|
||||||
|
|
||||||
|
EXPOSE 4444
|
@ -10,7 +10,7 @@
|
|||||||
# https://hub.docker.com/r/laradock/workspace/tags/
|
# https://hub.docker.com/r/laradock/workspace/tags/
|
||||||
#
|
#
|
||||||
|
|
||||||
FROM laradock/workspace:1.2
|
FROM laradock/workspace:1.3
|
||||||
|
|
||||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||||
|
|
||||||
@ -79,7 +79,7 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
|
|||||||
#####################################
|
#####################################
|
||||||
USER root
|
USER root
|
||||||
|
|
||||||
COPY ./crontab /var/spool/cron/crontabs
|
COPY ./crontab /etc/cron.d
|
||||||
|
|
||||||
#####################################
|
#####################################
|
||||||
# xDebug:
|
# xDebug:
|
||||||
@ -268,6 +268,29 @@ USER laradock
|
|||||||
RUN echo "" >> ~/.bashrc && \
|
RUN echo "" >> ~/.bashrc && \
|
||||||
echo 'export PATH="/var/www/vendor/bin:$PATH"' >> ~/.bashrc
|
echo 'export PATH="/var/www/vendor/bin:$PATH"' >> ~/.bashrc
|
||||||
|
|
||||||
|
#####################################
|
||||||
|
# Laravel Artisan Alias
|
||||||
|
#####################################
|
||||||
|
USER root
|
||||||
|
|
||||||
|
RUN echo "" >> ~/.bashrc && \
|
||||||
|
echo 'alias art="php artisan"' >> ~/.bashrc
|
||||||
|
|
||||||
|
#####################################
|
||||||
|
# Laravel Envoy:
|
||||||
|
#####################################
|
||||||
|
USER laradock
|
||||||
|
|
||||||
|
ARG INSTALL_LARAVEL_ENVOY=true
|
||||||
|
ENV INSTALL_LARAVEL_ENVOY ${INSTALL_LARAVEL_ENVOY}
|
||||||
|
|
||||||
|
RUN if [ ${INSTALL_LARAVEL_ENVOY} = true ]; then \
|
||||||
|
# Install the Laravel Envoy
|
||||||
|
echo "" >> ~/.bashrc && \
|
||||||
|
echo 'export PATH="~/.composer/vendor/bin:$PATH"' >> ~/.bashrc \
|
||||||
|
&& composer global require "laravel/envoy=~1.0" \
|
||||||
|
;fi
|
||||||
|
|
||||||
#
|
#
|
||||||
#--------------------------------------------------------------------------
|
#--------------------------------------------------------------------------
|
||||||
# Final Touch
|
# Final Touch
|
||||||
|
1
workspace/crontab/laradock
Normal file
1
workspace/crontab/laradock
Normal file
@ -0,0 +1 @@
|
|||||||
|
* * * * * laradock php /var/www/artisan schedule:run >> /dev/null 2>&1
|
@ -1 +0,0 @@
|
|||||||
* * * * * php /var/www/artisan schedule:run >> /dev/null 2>&1
|
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
|
|
||||||
# Grab full name of php-fpm container
|
# Grab full name of php-fpm container
|
||||||
PHP_FPM_CONTAINER=$(docker-compose ps | grep php-fpm | cut -d" " -f 1)
|
PHP_FPM_CONTAINER=$(docker-compose ps | grep php-fpm | cut -d " " -f 1)
|
||||||
|
|
||||||
|
|
||||||
# Grab OS type
|
# Grab OS type
|
||||||
|
Reference in New Issue
Block a user