Compare commits
462 Commits
v0.1.0-Bet
...
v4.8.0
Author | SHA1 | Date | |
---|---|---|---|
6ee790c26d | |||
a1ade52cd6 | |||
05f4f371fe | |||
33e99ca9cf | |||
e913fd941e | |||
5286fd654a | |||
499342ea39 | |||
17442db357 | |||
4f7b0ec0c3 | |||
a0981aa836 | |||
6a3137fc27 | |||
4d5e3e5e4a | |||
aa7c52c42e | |||
6eed8199df | |||
c02f17417f | |||
91bae76527 | |||
891911ddc3 | |||
89fac4bdbe | |||
22a3bbc0b0 | |||
89a21ccf1b | |||
15892dba51 | |||
1fa1dc9a1c | |||
c4cd3ed2ac | |||
ffe45fed50 | |||
bd1f6ebd8a | |||
f35e5501db | |||
8d1ba2e802 | |||
c9415b12c0 | |||
8544de7ea1 | |||
62e0f0443c | |||
a2847316c4 | |||
9d212afc8c | |||
89a77bee24 | |||
fb26035e5c | |||
c7a76dd683 | |||
781f5ff972 | |||
5c0e55204e | |||
dd3ab5ade1 | |||
2e5d2a743c | |||
5635b47c6f | |||
56f422ade0 | |||
58d6d8e745 | |||
7ecb712e76 | |||
3abb6152c8 | |||
5221544b98 | |||
2396b4799c | |||
08fa1bc95c | |||
2415566230 | |||
5fea003ffe | |||
e9af2a4fb3 | |||
d0dea21cc5 | |||
942d1cfbed | |||
57ec81ed52 | |||
8d62070773 | |||
8933b827b3 | |||
6f435584a9 | |||
a1fd2aabcd | |||
3e2b413094 | |||
ec3ebb9701 | |||
cfc48b3791 | |||
3725ad4c46 | |||
a0b75bac46 | |||
489740848f | |||
b2aa38877b | |||
51703f00fc | |||
f1716a2767 | |||
5640bd963d | |||
8bb69beb84 | |||
76afeedc33 | |||
16b6223ba9 | |||
1b88c2c9d8 | |||
b254d4a9c9 | |||
2ed475f1ef | |||
3a5100097a | |||
15b3fe65c1 | |||
da6face95e | |||
a31cef6eb1 | |||
a005281f4f | |||
907c694834 | |||
8c392e94f2 | |||
d538274a0f | |||
beeea8dc0e | |||
53b0507eb2 | |||
a1a5b3d49f | |||
4f5dfbcb13 | |||
f275f88396 | |||
6cc58de67e | |||
b2da8aeb3f | |||
1345164ac3 | |||
a9ecdd0008 | |||
1dab0c48d8 | |||
91f1d4347c | |||
4013553dbb | |||
07e4bd174e | |||
7999399e9a | |||
d684cb4742 | |||
3c27c14b99 | |||
3473b788cf | |||
1a5c7a7b3f | |||
616e9c7d92 | |||
a3039958e3 | |||
b01bae59fc | |||
92dc3be3b1 | |||
650f6a89c6 | |||
041d134f69 | |||
79ff092105 | |||
ffce0f93d5 | |||
a2d154c30a | |||
59a22aedac | |||
b42ad1ae7e | |||
07d6ec85ca | |||
adfb559521 | |||
05e0e9c817 | |||
ab53db1897 | |||
6dcb174012 | |||
38eeae8791 | |||
de914d106f | |||
6c71d6d84f | |||
7b2ff6dab8 | |||
1e5d604470 | |||
314e43bb79 | |||
ea047e2587 | |||
d441427852 | |||
227c8da17c | |||
14b97caa57 | |||
6ba76da709 | |||
294fe31a80 | |||
78be0b577e | |||
5a980b1c97 | |||
3ad474a2d9 | |||
0ad1e58bf0 | |||
0cf12c7383 | |||
4e0af7e0cb | |||
d6b091df96 | |||
506fe598cd | |||
b252558560 | |||
29d714a849 | |||
f9fd391879 | |||
740b4647a3 | |||
f8d3c58d6a | |||
509cb9ac2e | |||
f2aea63d64 | |||
9aa8813a3d | |||
58af86a582 | |||
12ba6bbbae | |||
9fb50b2c6b | |||
df1a019f75 | |||
c68f70d2a7 | |||
002b147b23 | |||
314034255a | |||
3c8861d1d2 | |||
2d51548879 | |||
4aa3902f32 | |||
1afad7f14c | |||
00d48fff51 | |||
9bd70aadc8 | |||
fb049ef300 | |||
e75da747a9 | |||
dd48592d8b | |||
d57a0c3888 | |||
7a13e4a343 | |||
4e7e003e87 | |||
208b2e7c0a | |||
9611fdb58f | |||
9a77c8e276 | |||
080cc2a88a | |||
b648f1ca58 | |||
cfc81fca64 | |||
928451ae88 | |||
95ef5e1e70 | |||
c324114b7a | |||
5ee1fdd71b | |||
7680e29bc5 | |||
b42f24c50d | |||
1c22c009e7 | |||
380c7bd1ec | |||
e8562272b0 | |||
1614f0fb2d | |||
5232d6a84f | |||
391602a811 | |||
b4760ac703 | |||
aabb0cded8 | |||
d3a6116a42 | |||
eb81dfc1be | |||
a6e04aa659 | |||
93504a714d | |||
d8a4537efb | |||
28b4077a49 | |||
651430c7a9 | |||
3be9dee1c7 | |||
8ef37a71fb | |||
5210ca7ccf | |||
a30bf83269 | |||
1fdf800988 | |||
82cbad75d4 | |||
6111ca5ff7 | |||
b393996d44 | |||
f12028576c | |||
27d3525469 | |||
8b6fdfed76 | |||
3c427d20c0 | |||
57c003722e | |||
ab4c44a434 | |||
0f7969c999 | |||
aa8f7c48a5 | |||
533925522c | |||
48a6c06ebb | |||
537f2c5033 | |||
f36f9ef6ec | |||
605c191717 | |||
f2615b9ff2 | |||
04174b476c | |||
afac432b2f | |||
2f156edafd | |||
42d551dead | |||
b7d38ef7dd | |||
c5ac8d1ada | |||
2f20216d8f | |||
5e0e120950 | |||
33b701afdc | |||
e0c18374df | |||
20adc9ca13 | |||
dd9855d411 | |||
17e252a436 | |||
dd06f1e1a0 | |||
2ba3060564 | |||
5612874b78 | |||
10af217349 | |||
e65f0dceba | |||
c792a780ee | |||
2d1c1586f5 | |||
5bb3d3b6a8 | |||
b1ec5b8d6f | |||
6e07061deb | |||
97057f259c | |||
e4f6cec536 | |||
e6cf30e7ba | |||
ed8e241007 | |||
c60cb9ab40 | |||
d58ef06907 | |||
462b5685eb | |||
11f7cfe729 | |||
d5ffc04034 | |||
062b7466f6 | |||
e1dbb972f1 | |||
419434020c | |||
2a02ed73e3 | |||
ca378ac734 | |||
67f92de4f0 | |||
c8d4461771 | |||
23b0906cd7 | |||
28a2d8e072 | |||
f97f0b0d11 | |||
05e1dd4c13 | |||
fc78ab7764 | |||
ef8579987f | |||
4dda3b969e | |||
4d2452101a | |||
233cfb5b07 | |||
63b9ec2bd8 | |||
d5a51d4de9 | |||
c7fae1a807 | |||
d6329c26b3 | |||
a96ee88692 | |||
2799a94a9f | |||
5bcbe0d291 | |||
9e7a669d5b | |||
9b084433c3 | |||
fc303dee08 | |||
d75a43c615 | |||
06337e6024 | |||
16b82d066e | |||
074deec781 | |||
2d382b683a | |||
68576f9022 | |||
2df00ecdad | |||
aeb5a6bb63 | |||
2bbf59ddda | |||
dca0545293 | |||
5f99478c76 | |||
48a53f1d24 | |||
11cdfd440b | |||
14cbe9f935 | |||
42d63236f1 | |||
d01d087431 | |||
11c65c4a00 | |||
1b9630e8a1 | |||
3a714339da | |||
65078505c1 | |||
e0b4734dab | |||
243392444f | |||
72a8fc049d | |||
de6db93da8 | |||
1af9dc5ac2 | |||
62878e7c49 | |||
3cd1f070e1 | |||
fb5ea7f42c | |||
aa8be6f95b | |||
aa0a726945 | |||
5ebb061b70 | |||
e5e04e4e18 | |||
44d8720400 | |||
f0200626ba | |||
69406db3e0 | |||
bcb749151a | |||
ca413edff4 | |||
f6d1d6f617 | |||
117382a050 | |||
2e930df2a7 | |||
4922c5fafd | |||
198c38f6cd | |||
8d216f83d5 | |||
05c5fcf216 | |||
fccee522c6 | |||
f3eb6a5fc4 | |||
685c34d12d | |||
ceba1af3ae | |||
c4100b5052 | |||
1148a3d051 | |||
bec1a32550 | |||
72cde8a8ea | |||
4f9cdb02c6 | |||
1673a80daf | |||
f130381cfe | |||
eda286ded2 | |||
a8b4b61e28 | |||
124a3553e6 | |||
3ff4aaca79 | |||
4c06a03ead | |||
1cb131ba36 | |||
99b54c5f7d | |||
8993cccc2c | |||
1090bb4db6 | |||
9c7054abe2 | |||
e7decdaaf7 | |||
18bf12bfde | |||
ad49981dd6 | |||
d829482a06 | |||
86c6389650 | |||
991e28046d | |||
ccbc73c6bc | |||
246c7366ba | |||
762e2ec07b | |||
adaaa25f47 | |||
11a13a0c33 | |||
c642560993 | |||
ea9f5c635f | |||
fd4253afb6 | |||
73310e45e8 | |||
7f91fc9798 | |||
a8a7685a40 | |||
06c4c19a6f | |||
8bff7656f6 | |||
5c9eb97db5 | |||
588819ab6d | |||
170b63a3ba | |||
19813e48c3 | |||
be7b8ee056 | |||
01a056dd25 | |||
70e1b0fe41 | |||
0959b25c05 | |||
1d8336a9e1 | |||
f0e2d83618 | |||
7f1deb0342 | |||
703887a2a6 | |||
84e6b2b6ff | |||
c3ff9e485b | |||
77f9183c83 | |||
378181044c | |||
01bdaae690 | |||
68aca9f8f9 | |||
6d0ecaecf4 | |||
a434588a66 | |||
5aa01b1757 | |||
3b2831bf1d | |||
7171996843 | |||
66f08a4f60 | |||
07a07ab3ac | |||
fb4fcdcb23 | |||
a69681b07c | |||
2c05c87400 | |||
16a1041ef5 | |||
5ef193d55b | |||
4d8a798224 | |||
1574231a80 | |||
6eb3a9bd5f | |||
377f24fe2b | |||
51b6d4f844 | |||
97500508f5 | |||
7dcf481d21 | |||
efd062fd88 | |||
504c9c59d5 | |||
4edf941872 | |||
36b49f5ae2 | |||
e49836ba90 | |||
84f766363d | |||
03c991c89d | |||
fdba7e7c09 | |||
405067d4af | |||
7f4e411d3d | |||
e135fbb970 | |||
e946573d75 | |||
470873acd2 | |||
88d5dd7806 | |||
295a0974da | |||
cf89670671 | |||
40899bc40f | |||
64bf3222af | |||
79009cc97e | |||
571bf64eb2 | |||
75b1705820 | |||
12587bc712 | |||
81f2602464 | |||
ecefee4d65 | |||
de8cbb0605 | |||
5190da831a | |||
fdaa983e77 | |||
e52f8f5613 | |||
f9c13090c6 | |||
bfa0d54b5a | |||
7f80888fc1 | |||
aa338d534e | |||
31793a3cc9 | |||
5d84c6481f | |||
26229e150d | |||
ab7f3d8fd9 | |||
2b98b0b82e | |||
457c5d4b1b | |||
cd97ac0aa6 | |||
22f11e03ee | |||
5d62ec1e67 | |||
daa5ed981f | |||
9ac7541dc9 | |||
05a83d383f | |||
12051834a3 | |||
e2593ab522 | |||
4f9271d565 | |||
c447eb86e4 | |||
530ffe7433 | |||
c8718e3746 | |||
feaff6fa72 | |||
d98cf4754b | |||
b335364591 | |||
105fce8965 | |||
0973aaf166 | |||
b5be47fb5e | |||
03e7eb622e | |||
d9f10f367c | |||
dac12296c6 | |||
62ec36d9dd | |||
5bc35214e6 | |||
d179226247 | |||
97ad0cdcfe | |||
bd88b95bb5 | |||
8e5aa26b99 | |||
45cc9908ad | |||
84e26f046b | |||
01b41a1245 | |||
9135e8aa1f | |||
e572b0b9e7 | |||
7e49f6708e | |||
1876594511 |
12
.editorconfig
Normal file
12
.editorconfig
Normal file
@ -0,0 +1,12 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
|
||||
[{Dockerfile,docker-compose.yml}]
|
||||
indent_style = space
|
||||
indent_size = 4
|
4
.gitignore
vendored
Normal file
4
.gitignore
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
.idea
|
||||
/logs
|
||||
/data
|
||||
.env
|
140
CONTRIBUTING.md
Normal file
140
CONTRIBUTING.md
Normal file
@ -0,0 +1,140 @@
|
||||
# Contributing to LaraDock
|
||||
|
||||
Your contribution is more than welcome. Let's keep LaraDock amazing.
|
||||
|
||||
|
||||
### Got a Question or Problem?
|
||||
|
||||
If you have questions about how to use LaraDock, please direct your questions to the discussion on [Gitter](https://gitter.im/LaraDock/laradock). If you beleave your question could help others, then consider opening an [Issue](https://github.com/laradock/laradock/issues) (it will be labeled as Question).
|
||||
|
||||
### Found an Issue?
|
||||
If you find a bug in the source code or a mistake in the documentation, you can help us by
|
||||
submitting an [Issue](https://github.com/laradock/laradock/issues). Even better you can submit a Pull Request with a fix.
|
||||
|
||||
### Want a Feature?
|
||||
You can request a new feature by submitting an [Issue](https://github.com/laradock/laradock/issues) (it will be labeled as Feature Suggestion). If you would like to implement a new feature then consider submitting a Pull Request.
|
||||
|
||||
|
||||
## Coding Guidelines
|
||||
|
||||
### Support new Software
|
||||
|
||||
* Create folder with the software name.
|
||||
|
||||
* Add a `Dockerfile`, write your code there.
|
||||
|
||||
* You may add additional files in the software folder.
|
||||
|
||||
* Add the software to the `docker-compose.yml` file.
|
||||
|
||||
* Make sure you follow our commenting style.
|
||||
|
||||
* Add the software in the `Readme`.
|
||||
|
||||
### Edit existing Software
|
||||
|
||||
* Open the software (container) folder.
|
||||
|
||||
* Edit the files you want to update.
|
||||
|
||||
* **Note:** If you want to edit the base image of the `Workspace` or the `php-fpm` Containers,
|
||||
you need to edit their Dockerfiles from their Github repositories. For more info read their Dockerfiles comment on the LaraDock repository.
|
||||
|
||||
* Make sure to update the `Readme` incase you made any changes.
|
||||
|
||||
## Issue/PR Submission Guidelines
|
||||
|
||||
### Submitting an Issue
|
||||
Before you submit your issue search the archive, maybe your question was already answered.
|
||||
|
||||
If your issue appears to be a bug, and hasn't been reported, open a new issue.
|
||||
Help us to maximize the effort we can spend fixing issues and adding new
|
||||
features, by not reporting duplicate issues.
|
||||
|
||||
|
||||
### Before Submitting a Pull Request (PR)
|
||||
|
||||
Always Test everything and make sure its working:
|
||||
|
||||
- Pull the latest updates (or fork of you don’t have permission)
|
||||
- Before editing anything:
|
||||
- Test building the container (docker-compose build --no-cache container-name) build with no cache first.
|
||||
- Test running the container with some other containers in real app and see of everything is working fine.
|
||||
- Now edit the container (edit section by section and test rebuilding the container after every edited section)
|
||||
- Testing building the container (docker-compose build container-name) with no errors.
|
||||
- Test it in real App.
|
||||
|
||||
|
||||
### Submitting a PR
|
||||
Consider the following guidelines:
|
||||
|
||||
* Search [GitHub](https://github.com/LaraDock/laradock/pulls) for an open or closed Pull Request that relates to your submission. You don't want to duplicate effort.
|
||||
|
||||
* Make your changes in a new git branch:
|
||||
|
||||
```shell
|
||||
git checkout -b my-fix-branch master
|
||||
```
|
||||
* Commit your changes using a descriptive commit message.
|
||||
|
||||
* Push your branch to GitHub:
|
||||
|
||||
```shell
|
||||
git push origin my-fix-branch
|
||||
```
|
||||
|
||||
* In GitHub, send a pull request to `laradock:master`.
|
||||
* If we suggest changes then:
|
||||
* Make the required updates.
|
||||
* Commit your changes to your branch (e.g. `my-fix-branch`).
|
||||
* Push the changes to your GitHub repository (this will update your Pull Request).
|
||||
|
||||
> If the PR gets too outdated we may ask you to rebase and force push to update the PR:
|
||||
|
||||
```shell
|
||||
git rebase master -i
|
||||
git push origin my-fix-branch -f
|
||||
```
|
||||
|
||||
*WARNING. Squashing or reverting commits and forced push thereafter may remove GitHub comments on code that were previously made by you and others in your commits.*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
### After your PR is merged
|
||||
|
||||
After your pull request is merged, you can safely delete your branch and pull the changes
|
||||
from the main (upstream) repository:
|
||||
|
||||
* Delete the remote branch on GitHub either through the GitHub web UI or your local shell as follows:
|
||||
|
||||
```shell
|
||||
git push origin --delete my-fix-branch
|
||||
```
|
||||
|
||||
* Check out the master branch:
|
||||
|
||||
```shell
|
||||
git checkout master -f
|
||||
```
|
||||
|
||||
* Delete the local branch:
|
||||
|
||||
```shell
|
||||
git branch -D my-fix-branch
|
||||
```
|
||||
|
||||
* Update your master with the latest upstream version:
|
||||
|
||||
```shell
|
||||
git pull --ff upstream master
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
### Happy Coding :)
|
10
LICENSE
10
LICENSE
@ -1,6 +1,6 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2015 Mahmoud Zalt
|
||||
Copyright 2016 <Mahmoud Zalt>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
@ -9,13 +9,13 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
968
README-zh.md
Normal file
968
README-zh.md
Normal file
@ -0,0 +1,968 @@
|
||||
# LaraDock
|
||||
|
||||
[](http://zalt.me)
|
||||
|
||||
[](https://gitter.im/LaraDock/laradock?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||
|
||||
LaraDock能够帮你在**Docker**上快速搭建**Laravel**应用。
|
||||
<br>
|
||||
就像Laravel Homestead一样,但是Docker替换了Vagrant。
|
||||
>先在Docker上使用LaraDock,然后再学习它们。
|
||||
|
||||

|
||||
|
||||
<br>
|
||||
## 目录
|
||||
|
||||
- [Intro](#Intro)
|
||||
- [Features](#features)
|
||||
- [Supported Software's](#Supported-Containers)
|
||||
- [What is Docker](#what-is-docker)
|
||||
- [What is Laravel](#what-is-laravel)
|
||||
- [Why Docker not Vagrant](#why-docker-not-vagrant)
|
||||
- [LaraDock VS Homestead](#laradock-vs-homestead)
|
||||
- [Demo Video](#Demo)
|
||||
- [Requirements](#Requirements)
|
||||
- [Installation](#Installation)
|
||||
- [Usage](#Usage)
|
||||
- [Documentation](#Documentation)
|
||||
- [Docker](#Docker)
|
||||
- [List current running Containers](#List-current-running-Containers)
|
||||
- [Close all running Containers](#Close-all-running-Containers)
|
||||
- [Delete all existing Containers](#Delete-all-existing-Containers)
|
||||
- [Enter a Container (SSH into a running Container)](#Enter-Container)
|
||||
- [Edit default container configuration](#Edit-Container)
|
||||
- [Edit a Docker Image](#Edit-a-Docker-Image)
|
||||
- [Build/Re-build Containers](#Build-Re-build-Containers)
|
||||
- [Add more Software's (Docker Images)](#Add-Docker-Images)
|
||||
- [View the Log files](#View-the-Log-files)
|
||||
- [Laravel](#Laravel):
|
||||
- [Install Laravel from a Docker Container](#Install-Laravel)
|
||||
- [Run Artisan Commands](#Run-Artisan-Commands)
|
||||
- [Use Redis](#Use-Redis)
|
||||
- [Use Mongo](#Use-Mongo)
|
||||
- [PHP](#PHP)
|
||||
- [Install PHP Extensions](#Install-PHP-Extensions)
|
||||
- [Change the PHP-FPM Version](#Change-the-PHP-FPM-Version)
|
||||
- [Change the PHP-CLI Version](#Change-the-PHP-CLI-Version)
|
||||
- [Install xDebug](#Install-xDebug)
|
||||
- [Misc](#Misc)
|
||||
- [Use custom Domain](#Use-custom-Domain)
|
||||
- [Enable Global Composer Build Install](#Enable-Global-Composer-Build-Install)
|
||||
- [Install Prestissimo](#Install-Prestissimo)
|
||||
- [Install Node + NVM](#Install-Node)
|
||||
- [Debugging](#debugging)
|
||||
- [Upgrading LaraDock](#upgrading-laradock)
|
||||
- [Help & Questions](#Help)
|
||||
|
||||
|
||||
|
||||
<a name="Intro"></a>
|
||||
## 介绍
|
||||
LaraDock努力简化创建开发环境过程。
|
||||
它包含预包装Docker镜像,提供你一个美妙的开发环境而不需要安装PHP,NGINX,MySQL和其他任何软件在你本地机器上。
|
||||
|
||||
**使用概览:**
|
||||
|
||||
|
||||
让我们了解使用它安装`NGINX`, `PHP`, `Composer`, `MySQL` 和 `Redis`,然后运行`Laravel`
|
||||
|
||||
1. 将LaraDock放到你的Laravel项目中:
|
||||
<br>
|
||||
`git clone https://github.com/LaraDock/laradock.git`.
|
||||
2. 进入LaraDock目录,然后运行这些容器。
|
||||
<br>
|
||||
`docker-compose up -d nginx mysql redis`
|
||||
3. 打开你的`.env`文件,然后设置`mysql`的`DB_HOST` 和 `redis`的`REDIS_HOST`。
|
||||
4. 打开浏览器,访问localhost:
|
||||
|
||||
|
||||
<a name="features"></a>
|
||||
### 特点
|
||||
|
||||
- 在PHP版本:7.0,5.6.5.5...之中可以简单切换。
|
||||
- 可选择你最喜欢的数据库引擎,比如:MySQL, Postgres, MariaDB...
|
||||
- 可运行自己的软件组合,比如:Memcached, HHVM, Beanstalkd...
|
||||
- 所有软件运行在不同的容器之中,比如:PHP-FPM, NGINX, PHP-CLI...
|
||||
- 通过简单的编写`dockerfile`容易定制任何容器。
|
||||
- 所有镜像继承自一个官方基础镜像(Trusted base Images)
|
||||
- 可预配置Laravel的Nginx环境
|
||||
- 容易应用容器中的配置
|
||||
- 干净的结构化的Docker配置文件(`dockerfile`)
|
||||
- 最新的Docker Compose 版本(`docker-compose`)
|
||||
- 所有的都是可视化和可编辑的
|
||||
- 快速的镜像构建
|
||||
- 每周都会有更新...
|
||||
|
||||
<a name="Supported-Containers"></a>
|
||||
### 支持的软件 (容器)
|
||||
|
||||
- **数据库引擎:**
|
||||
- MySQL
|
||||
- PostgreSQL
|
||||
- MariaDB
|
||||
- MongoDB
|
||||
- Neo4j
|
||||
- **缓存引擎:**
|
||||
- Redis
|
||||
- Memcached
|
||||
- **PHP 服务器:**
|
||||
- NGINX
|
||||
- Apache2
|
||||
- Caddy
|
||||
- **PHP 编译工具:**
|
||||
- PHP-FPM
|
||||
- HHVM
|
||||
- **消息队列系统:**
|
||||
- Beanstalkd (+ Beanstalkd Console)
|
||||
- **工具:**
|
||||
- Workspace (PHP7-CLI, Composer, Git, Node, Gulp, SQLite, Vim, Nano, cURL...)
|
||||
>如果你找不到你需要的软件,构建它然后把它添加到这个列表。你的贡献是受欢迎的。
|
||||
|
||||
<a name="what-is-docker"></a>
|
||||
### Docker是什么?
|
||||
|
||||
[Docker](https://www.docker.com) 是一个开源项目,自动化部署应用程序软件的容器,在Linux, Mac OS and Windows提供一个额外的抽象层和自动化的[操作系统级的虚拟化](https://en.wikipedia.org/wiki/Operating-system-level_virtualization)
|
||||
|
||||
<a name="what-is-laravel"></a>
|
||||
### Laravel是什么?
|
||||
|
||||
额,这很认真的!!!
|
||||
|
||||
|
||||
<a name="why-docker-not-vagrant"></a>
|
||||
### 为什么使用Docker而不是Vagrant!?
|
||||
|
||||
[Vagrant](https://www.vagrantup.com)构建虚拟机需要几分钟然而Docker构建虚拟容器只需要几秒钟。
|
||||
而不是提供一个完整的虚拟机,就像你用Vagrant,Docker为您提供**轻量级**虚拟容器,共享相同的内核和允许安全执行独立的进程。
|
||||
|
||||
除了速度,Docker提供大量的Vagrant无法实现的功能。
|
||||
|
||||
最重要的是Docker可以运行在开发和生产(相同环境无处不在)。Vagrant是专为开发,(所以在生产环境你必须每一次重建您的服务器)。
|
||||
|
||||
<a name="laradock-vs-homestead"></a>
|
||||
### LaraDock Homestead 对比
|
||||
|
||||
LaraDock and [Homestead](https://laravel.com/docs/master/homestead) 给你一个完整的虚拟开发环境。(不需要安装和配置软件在你自己的每一个操作系统)。
|
||||
|
||||
Homestead 是一个工具,为你控制虚拟机(使用Homestead特殊命令)。Vagrant可以管理你的管理虚容器。
|
||||
|
||||
运行一个虚拟容器比运行一整个虚拟机快多了**LaraDock 比 Homestead快多了**
|
||||
|
||||
|
||||
|
||||
<a name="Demo"></a>
|
||||
## 演示视频
|
||||
还有什么比**演示视频**好:
|
||||
|
||||
- LaraDock v4.0 (即将到来的...)
|
||||
- LaraDock [v2.2](https://www.youtube.com/watch?v=-DamFMczwDA)
|
||||
- LaraDock [v0.3](https://www.youtube.com/watch?v=jGkyO6Is_aI)
|
||||
- LaraDock [v0.1](https://www.youtube.com/watch?v=3YQsHe6oF80)
|
||||
|
||||
|
||||
|
||||
<a name="Requirements"></a>
|
||||
## 依赖
|
||||
|
||||
- [Git](https://git-scm.com/downloads)
|
||||
- [Docker](https://www.docker.com/products/docker/)
|
||||
|
||||
|
||||
|
||||
<a name="Installation"></a>
|
||||
## 安装
|
||||
|
||||
|
||||
1 - 克隆 `LaraDock` 仓库:
|
||||
|
||||
**A)** 如果你已经有一个Laravel项目,克隆这个仓库在到`Laravel`根目录
|
||||
|
||||
```bash
|
||||
git submodule add https://github.com/LaraDock/laradock.git
|
||||
```
|
||||
>如果你不是使用Git管理Laravel项目,您可以使用 `git clone` 而不是`git submodule`。
|
||||
|
||||
|
||||
**B)** 如果你没有一个Laravel项目,你想Docker安装Laravel,克隆这个源在您的机器任何地方上:
|
||||
|
||||
```bash
|
||||
git clone https://github.com/LaraDock/laradock.git
|
||||
```
|
||||
|
||||
|
||||
|
||||
<a name="Usage"></a>
|
||||
## 使用
|
||||
|
||||
|
||||
**请在开始之前阅读:**
|
||||
如果你正在使用**Docker Toolbox** (VM),选择以下任何一个方法:
|
||||
- 更新到Docker [Native](https://www.docker.com/products/docker) Mac/Windows版本 (建议). 查看 [Upgrading Laradock](#upgrading-laradock)
|
||||
- 使用 LaraDock v3.* (访问 `LaraDock-ToolBox` [分支](https://github.com/LaraDock/laradock/tree/LaraDock-ToolBox)).
|
||||
如果您使用的是**Docker Native**(Mac / Windows版本)甚至是Linux版本,通常可以继续阅读这个文档,LaraDock v4以上版本将仅支持**Docker Native**。
|
||||
|
||||
<br>
|
||||
<br>
|
||||
1 - 运行容器: *(在运行`docker-compose`命令之前,确认你在 `laradock` 目录中*
|
||||
|
||||
|
||||
|
||||
**例子:** 运行 NGINX 和 MySQL:
|
||||
|
||||
```bash
|
||||
docker-compose up -d nginx mysql
|
||||
```
|
||||
你可以从以下列表选择你自己的容器组合:
|
||||
|
||||
|
||||
`nginx`, `hhvm`, `php-fpm`, `mysql`, `redis`, `postgres`, `mariadb`, `neo4j`, `mongo`, `apache2`, `caddy`, `memcached`, `beanstalkd`, `beanstalkd-console`, `workspace`.
|
||||
|
||||
|
||||
**说明**: `workspace` 和 `php-fpm` 将运行在大部分实例中, 所以不需要在 `up` 命令中加上它们.
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
2 - 进入 Workspace 容器, 执行像 (Artisan, Composer, PHPUnit, Gulp, ...)等命令
|
||||
|
||||
```bash
|
||||
docker-compose exec workspace bash
|
||||
```
|
||||
<br />
|
||||
增加 `--user=laradock` (例如 `docker-compose exec --user=laradock workspace bash`) 作为您的主机的用户创建的文件. (你可以从 `docker-compose.yml`修改 PUID (User id) 和 PGID (group id) 值 ).
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
3 - 编辑 Laravel 的配置.
|
||||
|
||||
如果你还没有安装Laravel项目,请查看 [How to Install Laravel in a Docker Container](#Install-Laravel).
|
||||
|
||||
打开 Laravel的 `.env` 文件 然后 配置 你的`mysql`的`DB_HOST`:
|
||||
|
||||
```env
|
||||
DB_HOST=mysql
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
4 - 打开浏览器访问localhost (`http://localhost/`).
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
**调试**: 如果你碰到任何问题,请查看 [调试](#debugging) 章节
|
||||
如果你需要特别支持,请联系我,更多细节在[帮助 & 问题](#Help)章节
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Documentation"></a>
|
||||
## 文档
|
||||
|
||||
|
||||
<a name="Docker"></a>
|
||||
### [Docker]
|
||||
|
||||
|
||||
|
||||
<a name="List-current-running-Containers"></a>
|
||||
### 列出正在运行的容器
|
||||
```bash
|
||||
docker ps
|
||||
```
|
||||
你也可以使用以下命令查看某项目的容器
|
||||
|
||||
|
||||
```bash
|
||||
docker-compose ps
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Close-all-running-Containers"></a>
|
||||
### 关闭所有容器
|
||||
```bash
|
||||
docker-compose stop
|
||||
```
|
||||
|
||||
停止某个容器:
|
||||
|
||||
```bash
|
||||
docker-compose stop {容器名称}
|
||||
```
|
||||
|
||||
<br>
|
||||
<a name="Delete-all-existing-Containers"></a>
|
||||
### 删除所有容器
|
||||
```bash
|
||||
docker-compose down
|
||||
```
|
||||
|
||||
|
||||
小心这个命令,因为它也会删除你的数据容器。(如果你想保留你的数据你应该在上述命令后列出容器名称删除每个容器本身):*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Enter-Container"></a>
|
||||
### 进入容器 (通过SSH 进入一个运行中的容器)
|
||||
|
||||
1 - 首先使用 `docker ps`命令查看正在运行的容器
|
||||
|
||||
2 - 进入某个容器使用:
|
||||
|
||||
```bash
|
||||
docker-compose exec {container-name} bash
|
||||
```
|
||||
|
||||
*例如: 进入 MySQL 容器*
|
||||
|
||||
```bash
|
||||
docker-compose exec mysql bash
|
||||
```
|
||||
|
||||
3 - 退出容器, 键入 `exit`.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Edit-Container"></a>
|
||||
### 编辑默认容器配置
|
||||
打开 `docker-compose.yml` 然后 按照你想的修改.
|
||||
|
||||
例如:
|
||||
|
||||
修改 MySQL 数据库名称:
|
||||
|
||||
```yml
|
||||
environment:
|
||||
MYSQL_DATABASE: laradock
|
||||
```
|
||||
|
||||
修改 Redis 默认端口为 1111:
|
||||
|
||||
```yml
|
||||
ports:
|
||||
- "1111:6379"
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Edit-a-Docker-Image"></a>
|
||||
### 编辑Docker镜像
|
||||
|
||||
1 - 找到你想修改的镜像的 `dockerfile` ,
|
||||
<br>
|
||||
例如: `mysql` 在 `mysql/Dockerfile`.
|
||||
|
||||
2 - 按你所要的编辑文件.
|
||||
|
||||
3 - 重新构建容器:
|
||||
|
||||
```bash
|
||||
docker-compose build mysql
|
||||
```
|
||||
更多信息在容器重建中 [点击这里](#Build-Re-build-Containers).
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Build-Re-build-Containers"></a>
|
||||
### 建立/重建容器
|
||||
|
||||
|
||||
如果你做任何改变`dockerfile`确保你运行这个命令,可以让所有修改更改生效:
|
||||
|
||||
|
||||
```bash
|
||||
docker-compose build
|
||||
```
|
||||
选择你可以指定哪个容器重建(而不是重建所有的容器):
|
||||
|
||||
|
||||
```bash
|
||||
docker-compose build {container-name}
|
||||
```
|
||||
|
||||
如果你想重建整个容器,你可能需要使用 `--no-cache` 选项 (`docker-compose build --no-cache {container-name}`).
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Add-Docker-Images"></a>
|
||||
### 增加更多软件 (Docker 镜像)
|
||||
|
||||
为了增加镜像(软件), 编辑 `docker-compose.yml` 添加容器细节, 你需要熟悉 [docker compose 文件语法](https://docs.docker.com/compose/compose-file/).
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="View-the-Log-files"></a>
|
||||
### 查看日志文件
|
||||
Nginx的日志在 `logs/nginx` 目录
|
||||
|
||||
然后查看其它容器日志(MySQL, PHP-FPM,...) 你可以运行:
|
||||
|
||||
```bash
|
||||
docker logs {container-name}
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Laravel"></a>
|
||||
### [Laravel]
|
||||
|
||||
|
||||
|
||||
|
||||
<a name="Install-Laravel"></a>
|
||||
### 从Docker镜像安装Laravel
|
||||
1 - 首先你需要进入 Workspace 容器.
|
||||
|
||||
2 - 安装 Laravel.
|
||||
|
||||
例如 使用 Composer
|
||||
|
||||
```bash
|
||||
composer create-project laravel/laravel my-cool-app "5.2.*"
|
||||
```
|
||||
|
||||
> 我们建议使用 `composer create-project` 替换Laravel 安装器去安装Laravel.
|
||||
|
||||
关于更多Laravel安装内容请 [点击这儿](https://laravel.com/docs/master#installing-laravel).
|
||||
|
||||
|
||||
3 - 编辑 `docker-compose.yml` 映射新的应用目录:
|
||||
系统默认LaraDock假定Laravel应用在LaraDock的父级目录中
|
||||
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/laravel`替换 `../:/var/www/laravel` , 如下:
|
||||
|
||||
```yaml
|
||||
application:
|
||||
build: ./application
|
||||
volumes:
|
||||
- ../my-cool-app/:/var/www/laravel
|
||||
```
|
||||
4 - 进入目录下继续工作..
|
||||
|
||||
```bash
|
||||
cd my-cool-app
|
||||
```
|
||||
|
||||
5 - 回到LaraDock安装步骤,看看如何编辑`env`的文件。
|
||||
|
||||
<br>
|
||||
<a name="Run-Artisan-Commands"></a>
|
||||
### 运行 Artisan 命令
|
||||
你可以从Workspace容器运行artisan命令和其他终端命令
|
||||
|
||||
1 - 确认Workspace容器已经运行.
|
||||
|
||||
```bash
|
||||
docker-compose up -d workspace // ..and all your other containers
|
||||
```
|
||||
|
||||
2 - 找到Workspace容器名称:
|
||||
|
||||
```bash
|
||||
docker-compose ps
|
||||
```
|
||||
|
||||
3 - 进入Workspace容器:
|
||||
|
||||
```bash
|
||||
docker-compose exec workspace bash
|
||||
```
|
||||
|
||||
增加 `--user=laradock` (例如 `docker-compose exec --user=laradock workspace bash`) 作为您的主机的用户创建的文件.
|
||||
|
||||
|
||||
4 - 运行任何你想的 :)
|
||||
|
||||
```bash
|
||||
php artisan
|
||||
```
|
||||
```bash
|
||||
Composer update
|
||||
```
|
||||
```bash
|
||||
phpunit
|
||||
```
|
||||
|
||||
<br>
|
||||
<a name="Use-Redis"></a>
|
||||
### 使用 Redis
|
||||
1 - 首先务必用 `docker-compose up` 命令运行 (`redis`)容器.
|
||||
|
||||
|
||||
```bash
|
||||
docker-compose up -d redis
|
||||
```
|
||||
|
||||
2 - 打开你的Laravel的 `.env` 文件 然后 配置`redis`的`REDIS_HOST`
|
||||
|
||||
```env
|
||||
REDIS_HOST=redis
|
||||
```
|
||||
如果在你的`.env` 文件没有找到`REDIS_HOST`变量。打开数据库配置文件`config/database.php`然后用`redis`替换默认IP`127.0.0.1`,例如:
|
||||
|
||||
|
||||
```php
|
||||
'redis' => [
|
||||
'cluster' => false,
|
||||
'default' => [
|
||||
'host' => 'redis',
|
||||
'port' => 6379,
|
||||
'database' => 0,
|
||||
],
|
||||
],
|
||||
```
|
||||
|
||||
3 - 启用Redis缓存或者开启Session管理也在`.env`文件中用`redis`替换默认`file`设置`CACHE_DRIVER` 和 `SESSION_DRIVER`
|
||||
|
||||
```env
|
||||
CACHE_DRIVER=redis
|
||||
SESSION_DRIVER=redis
|
||||
```
|
||||
|
||||
4 - 最好务必通过Compose安装 `predis/predis` 包 `(~1.0)`:
|
||||
|
||||
```bash
|
||||
composer require predis/predis:^1.0
|
||||
```
|
||||
|
||||
5 - 你可以用以下代码在Laravel中手动测试:
|
||||
|
||||
```php
|
||||
\Cache::store('redis')->put('LaraDock', 'Awesome', 10);
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Mongo"></a>
|
||||
### 使用 Mongo
|
||||
|
||||
1 - 首先在Workspace和PHP-FPM容器中安装`mongo`:
|
||||
<br>
|
||||
a) 打开 `docker-compose.yml` 文件
|
||||
<br>
|
||||
b) 在Workspace容器中找到`INSTALL_MONGO`选项:
|
||||
|
||||
<br>
|
||||
c) 设置为 `true`
|
||||
<br>
|
||||
d) 在PHP-FPM容器中找到`INSTALL_MONGO` <br>
|
||||
e) 设置为 `true`
|
||||
|
||||
相关配置项如下:
|
||||
|
||||
```yml
|
||||
workspace:
|
||||
build:
|
||||
context: ./workspace
|
||||
args:
|
||||
- INSTALL_MONGO=true
|
||||
...
|
||||
php-fpm:
|
||||
build:
|
||||
context: ./php-fpm
|
||||
args:
|
||||
- INSTALL_MONGO=true
|
||||
...
|
||||
```
|
||||
|
||||
2 - 重建`Workspace、PHP-FPM`容器 `docker-compose build workspace php-fpm`
|
||||
|
||||
|
||||
|
||||
3 - 使用`docker-compose up` 命令运行MongoDB容器 (`mongo`)
|
||||
|
||||
```bash
|
||||
docker-compose up -d mongo
|
||||
```
|
||||
|
||||
|
||||
4 - 在`config/database.php` 文件添加MongoDB的配置项:
|
||||
|
||||
```php
|
||||
'connections' => [
|
||||
|
||||
'mongodb' => [
|
||||
'driver' => 'mongodb',
|
||||
'host' => env('DB_HOST', 'localhost'),
|
||||
'port' => env('DB_PORT', 27017),
|
||||
'database' => env('DB_DATABASE', 'database'),
|
||||
'username' => '',
|
||||
'password' => '',
|
||||
'options' => [
|
||||
'database' => '',
|
||||
]
|
||||
],
|
||||
|
||||
// ...
|
||||
|
||||
],
|
||||
```
|
||||
|
||||
5 - 打开Laravel的 `.env` 文件 然后 更新以下字段:
|
||||
|
||||
- 设置 `DB_HOST` 为 `mongo`的主机IP.
|
||||
- 设置 `DB_PORT` 为 `27017`.
|
||||
- 设置 `DB_DATABASE` 为 `database`.
|
||||
|
||||
|
||||
6 - 最后务必通过Composer安装`jenssegers/mongodb`包,添加服务提供者(Laravel Service Provider)
|
||||
|
||||
|
||||
```bash
|
||||
composer require jenssegers/mongodb
|
||||
```
|
||||
更多细节内容 [点击这儿](https://github.com/jenssegers/laravel-mongodb#installation).
|
||||
|
||||
7 - 测试:
|
||||
|
||||
- 首先让你的模型继承Mongo的Eloquent Model. 查看 [文档](https://github.com/jenssegers/laravel-mongodb#eloquent).
|
||||
- 进入Workspace容器.
|
||||
- 迁移数据库 `php artisan migrate`.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="PHP"></a>
|
||||
### [PHP]
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<a name="Install-PHP-Extensions"></a>
|
||||
### 安装PHP拓展
|
||||
安装PHP扩展之前,你必须决定你是否需要`FPM`或`CLI`,因为他们安装在不同的容器上,如果你需要两者,则必须编辑两个容器。
|
||||
|
||||
PHP-FPM拓展务必安装在 `php-fpm/Dockerfile-XX`. *(用你PHP版本号替换 XX)*.
|
||||
<br>
|
||||
PHP-CLI拓展应该安装到`workspace/Dockerfile`.
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Change-the-PHP-FPM-Version"></a>
|
||||
### 修改PHP-FPM版本
|
||||
默认运行**PHP-FPM 7.0**版本.
|
||||
|
||||
>PHP-FPM负责服务你的应用代码,如果你是计划运行您的应用程序在不同PHP-FPM版本上,则不需要更改PHP-CLI版本。
|
||||
|
||||
|
||||
#### A) 切换版本 PHP `7.0` 到 PHP `5.6`
|
||||
|
||||
1 - 打开 `docker-compose.yml`。
|
||||
|
||||
2 - 在PHP容器的 `Dockerfile-70`文件。
|
||||
|
||||
3 - 修改版本号, 用`Dockerfile-56`替换 `Dockerfile-70` , 例如:
|
||||
|
||||
```txt
|
||||
php-fpm:
|
||||
build:
|
||||
context: ./php-fpm
|
||||
dockerfile: Dockerfile-70
|
||||
```
|
||||
|
||||
4 - 最后重建PHP容器
|
||||
|
||||
```bash
|
||||
docker-compose build php
|
||||
```
|
||||
|
||||
> 更多关于PHP基础镜像, 请访问 [PHP Docker官方镜像](https://hub.docker.com/_/php/).
|
||||
|
||||
|
||||
#### B) 切换版本 PHP `7.0` 或 `5.6` 到 PHP `5.5`
|
||||
我们已不在本地支持PHP5.5,但是你按照以下步骤获取:
|
||||
|
||||
1 - 克隆 `https://github.com/LaraDock/php-fpm`.
|
||||
|
||||
3 - 重命名 `Dockerfile-56` 为 `Dockerfile-55`.
|
||||
|
||||
3 - 编辑文件 `FROM php:5.6-fpm` 为 `FROM php:5.5-fpm`.
|
||||
|
||||
4 - 从 `Dockerfile-55`构建镜像.
|
||||
|
||||
5 - 打开 `docker-compose.yml` 文件.
|
||||
|
||||
6 - 将 `php-fpm` 指向你的 `Dockerfile-55` 文件.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Change-the-PHP-CLI-Version"></a>
|
||||
### 修改 PHP-CLI 版本
|
||||
默认运行**PHP-CLI 7.0**版本
|
||||
|
||||
>说明: PHP-CLI只用于执行Artisan和Composer命令,不服务于你的应用代码,这是PHP-FPM的工作,所以编辑PHP-CLI的版本不是很重要。
|
||||
PHP-CLI安装在Workspace容器,改变PHP-CLI版本你需要编辑`workspace/Dockerfile`.
|
||||
现在你必须手动修改PHP-FPM的`Dockerfile`或者创建一个新的。 (可以考虑贡献功能).
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-xDebug"></a>
|
||||
### 安装 xDebug
|
||||
|
||||
1 - 首先在Workspace和PHP-FPM容器安装 `xDebug`:
|
||||
<br>
|
||||
a) 打开 `docker-compose.yml` 文件
|
||||
<br>
|
||||
b) 在Workspace容器中找到 `INSTALL_XDEBUG` 选项
|
||||
<br>
|
||||
c) 改为 `true`
|
||||
<br>
|
||||
d) 在PHP-FPM容器中找到 `INSTALL_XDEBUG ` 选项<br>
|
||||
e) 改为 `true`
|
||||
|
||||
例如:
|
||||
|
||||
```yml
|
||||
workspace:
|
||||
build:
|
||||
context: ./workspace
|
||||
args:
|
||||
- INSTALL_XDEBUG=true
|
||||
...
|
||||
php-fpm:
|
||||
build:
|
||||
context: ./php-fpm
|
||||
args:
|
||||
- INSTALL_XDEBUG=true
|
||||
...
|
||||
```
|
||||
|
||||
2 - 重建容器 `docker-compose build workspace php-fpm`
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Misc"></a>
|
||||
### [Misc]
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-custom-Domain"></a>
|
||||
### 使用自定义域名 (替换Docker的IP)
|
||||
|
||||
假定你的自定义域名是 `laravel.dev`
|
||||
|
||||
1 - 打开 `/etc/hosts` 文件 添加以下内容,映射你的localhost 地址 `127.0.0.1` 为 `laravel.dev` 域名
|
||||
```bash
|
||||
127.0.0.1 laravel.dev
|
||||
```
|
||||
|
||||
2 - 打开你的浏览器访问 `{http://laravel.dev}`
|
||||
|
||||
你可以在nginx配置文件自定义服务器名称,如下:
|
||||
|
||||
|
||||
```conf
|
||||
server_name laravel.dev;
|
||||
```
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Enable-Global-Composer-Build-Install"></a>
|
||||
### 安装全局Composer命令
|
||||
|
||||
为启用全局Composer Install在容器构建中允许你安装composer的依赖,然后构建完成后就是可用的。
|
||||
|
||||
1 - 打开 `docker-compose.yml` 文件
|
||||
|
||||
2 - 在Workspace容器找到 `COMPOSER_GLOBAL_INSTALL` 选项并设置为 `true`
|
||||
|
||||
例如:
|
||||
|
||||
```yml
|
||||
workspace:
|
||||
build:
|
||||
context: ./workspace
|
||||
args:
|
||||
- COMPOSER_GLOBAL_INSTALL=true
|
||||
...
|
||||
```
|
||||
3 - 现在特价你的依赖关系到 `workspace/composer.json`
|
||||
|
||||
4 - 重建Workspace容器 `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Prestissimo"></a>
|
||||
### 安装 Prestissimo
|
||||
|
||||
[Prestissimo](https://github.com/hirak/prestissimo) 是一个平行安装功能的composer插件。
|
||||
1 - 在安装期间,使全局Composer Install 正在运行:
|
||||
|
||||
点击这个 [启用全局Composer构建安装](#Enable-Global-Composer-Build-Install) 然后继续步骤1、2.
|
||||
|
||||
2 - 添加 prestissimo 依赖到 Composer:
|
||||
|
||||
a - 现在打开 `workspace/composer.json` 文件
|
||||
|
||||
b - 添加 `"hirak/prestissimo": "^0.3"` 依赖
|
||||
|
||||
c - 重建Workspace容器 `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Node"></a>
|
||||
### 安装 Node + NVM
|
||||
|
||||
在Workspace 容器安装 NVM 和 NodeJS
|
||||
1 - 打开 `docker-compose.yml` 文件
|
||||
|
||||
2 - 在Workspace容器找到 `INSTALL_NODE` 选项设为 `true`
|
||||
|
||||
例如:
|
||||
|
||||
```yml
|
||||
workspace:
|
||||
build:
|
||||
context: ./workspace
|
||||
args:
|
||||
- INSTALL_NODE=true
|
||||
...
|
||||
```
|
||||
|
||||
3 - 重建容器 `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="debugging"></a>
|
||||
### Debugging
|
||||
|
||||
*这里是你可能面临的常见问题列表,以及可能的解决方案.*
|
||||
|
||||
#### 看到空白页而不是Laravel的欢迎页面!
|
||||
|
||||
在Laravel根目录,运行下列命令:
|
||||
|
||||
```bash
|
||||
sudo chmod -R 777 storage bootstrap/cache
|
||||
```
|
||||
|
||||
#### 看到 "Welcome to nginx" 而不是 Laravel 应用!
|
||||
|
||||
在浏览器使用 `http://127.0.0.1` 替换 `http://localhost`.
|
||||
|
||||
#### 看到包含 `address already in use` 的错误
|
||||
|
||||
确保你想运行的服务端口(80, 3306, etc.)不是已经被其他程序使用,例如`apache`/`httpd`服务或其他安装的开发工具
|
||||
|
||||
|
||||
<br>
|
||||
<a name="upgrading-laradock"></a>
|
||||
### LaraDock 升级
|
||||
|
||||
|
||||
从Docker Toolbox (VirtualBox)移动到Docker Native (for Mac/Windows),需要从 LaraDock v3.* 升级到 v4.*:
|
||||
|
||||
1. 停止Docker虚拟机 `docker-machine stop {default}`
|
||||
2. 安装 Docker [Mac](https://docs.docker.com/docker-for-mac/) 或 [Windows](https://docs.docker.com/docker-for-windows/).
|
||||
3. 升级 LaraDock 到 `v4.*.*` (`git pull origin master`)
|
||||
4. 像之前一样使用LaraDock: `docker-compose up -d nginx mysql`.
|
||||
|
||||
**说明:** 如果你面临任何上面的问题的最后一步:重建你所有的容器
|
||||
`docker-compose build --no-cache`
|
||||
"警告:容器数据可能会丢失!"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
## 贡献
|
||||
这个小项目是由一个有一个全职工作和很多的职责的人建立的,所以如果你喜欢这个项目,并且发现它需要一个bug修复或支持或新软件或升级任何容器,或其他任何. . 你是非常欢迎,欢迎毫不不犹豫地贡献吧:)
|
||||
|
||||
#### 阅读我们的 [贡献说明](https://github.com/LaraDock/laradock/blob/master/CONTRIBUTING.md)
|
||||
|
||||
<a name="Help"></a>
|
||||
## 帮助 & 问题
|
||||
|
||||
从聊天室 [Gitter](https://gitter.im/LaraDock/laradock) 社区获取帮助和支持.
|
||||
|
||||
你也可以打开Github上的 [issue](https://github.com/laradock/laradock/issues) (将被贴上问题和答案) 或与大家讨论 [Gitter](https://gitter.im/LaraDock/laradock).
|
||||
|
||||
Docker或Laravel的特别帮助,你可以在[Codementor.io](https://www.codementor.io/mahmoudz)上直接和项目创始人在线沟通
|
||||
|
||||
## 关于作者
|
||||
|
||||
**创始人:**
|
||||
|
||||
- [Mahmoud Zalt](https://github.com/Mahmoudz) (Twitter [@Mahmoud_Zalt](https://twitter.com/Mahmoud_Zalt))
|
||||
|
||||
**优秀的人:**
|
||||
|
||||
- [Contributors](https://github.com/LaraDock/laradock/graphs/contributors)
|
||||
- [Supporters](https://github.com/LaraDock/laradock/issues?utf8=%E2%9C%93&q=)
|
||||
|
||||
|
||||
## 许可证
|
||||
|
||||
[MIT License](https://github.com/laradock/laradock/blob/master/LICENSE) (MIT)
|
213
_guides/digital_ocean.md
Normal file
213
_guides/digital_ocean.md
Normal file
@ -0,0 +1,213 @@
|
||||
#### Install Docker
|
||||
```
|
||||
Login Digital Ocean
|
||||
Add Droplet
|
||||
1 Click Install docker
|
||||
Choose Droplet
|
||||
reset ROOT password
|
||||
check email
|
||||
```
|
||||
|
||||
#### SSH to your Server
|
||||
|
||||
```
|
||||
ssh root@ipaddress
|
||||
```
|
||||
you will be prompt of that password.
|
||||
type the password you receive in your email
|
||||
|
||||
then it will ask to you to change a new password
|
||||
just change it to the custom root password you want
|
||||
|
||||
After SSH
|
||||
you can check that docker command is working by typing
|
||||
|
||||
```
|
||||
$root@midascode:~# docker
|
||||
```
|
||||
|
||||
#### Set Up Your Laravel Project
|
||||
|
||||
```
|
||||
$root@midascode:~# apt-get install git
|
||||
$root@midascode:~# git clone https://github.com/laravel/laravel
|
||||
$root@midascode:~# cd laravel
|
||||
$root@midascode:~/laravel/ git submodule add https://github.com/LaraDock/laradock.git
|
||||
$root@midascode:~/laravel/ cd laradock
|
||||
```
|
||||
|
||||
#### Install docker-compose command
|
||||
|
||||
```
|
||||
$root@midascode:~/laravel/laradock# curl -L https://github.com/docker/compose/releases/download/1.8.0/run.sh > /usr/local/bin/docker-compose
|
||||
$root@midascode:~/chmod +x /usr/local/bin/docker-compose
|
||||
```
|
||||
|
||||
#### Create Your LaraDock Containers
|
||||
|
||||
```
|
||||
$root@midascode:~/laravel/laradock# docker-compose up -d nginx mysql
|
||||
```
|
||||
|
||||
#### Go to Your Workspace
|
||||
|
||||
```
|
||||
docker-compose exec workspace bash
|
||||
```
|
||||
|
||||
#### Install laravel Dependencies, Add .env , generate Key and give proper permission certain folder
|
||||
|
||||
```
|
||||
$ root@0e77851d27d3:/var/www/laravel# composer install
|
||||
$ root@0e77851d27d3:/var/www/laravel# cp .env.example .env
|
||||
$ root@0e77851d27d3:/var/www/laravel# php artisan key:generate
|
||||
$ root@0e77851d27d3:/var/www/laravel# exit
|
||||
$root@midascode:~/laravel/laradock# cd ..
|
||||
$root@midascode:~/laravel# sudo chmod -R 777 storage bootstrap/cache
|
||||
```
|
||||
|
||||
you can then view your laravel site at your ipaddress
|
||||
for example
|
||||
```
|
||||
192.168.1.1
|
||||
```
|
||||
|
||||
You will see there Laravel Default Welcome Page
|
||||
|
||||
but if you need to view on your custom domain name
|
||||
which you would.
|
||||
|
||||
#### Using Your Own Domain Name
|
||||
login to your DNS provider
|
||||
Godaddy, Namecheap what ever...
|
||||
And Point the Custom Domain Name Server to
|
||||
|
||||
```
|
||||
ns1.digitalocean.com
|
||||
ns2.digitalocean.com
|
||||
ns3.digitalocean.com
|
||||
```
|
||||
In Your Digital Ocean Account go to
|
||||
```
|
||||
https://cloud.digitalocean.com/networking/domains
|
||||
```
|
||||
add your domain name and choose the server ip you provision earlier
|
||||
|
||||
#### Serve Site With NGINX (HTTP ONLY)
|
||||
Go back to command line
|
||||
```
|
||||
$root@midascode:~/laravel/laradock# cd nginx
|
||||
$root@midascode:~/laravel/laradock/nginx# vim laravel.conf
|
||||
```
|
||||
remove default_server
|
||||
```
|
||||
|
||||
listen 80 default_server;
|
||||
listen [::]:80 default_server ipv6only=on;
|
||||
|
||||
```
|
||||
and add server_name (your custom domain)
|
||||
```
|
||||
listen 80;
|
||||
listen [::]:80 ipv6only=on;
|
||||
server_name yourdomain.com;
|
||||
```
|
||||
|
||||
#### Rebuild Your Nginx
|
||||
```
|
||||
$root@midascode:~/laravel/laradock/nginx# docker-compose down
|
||||
$root@midascode:~/laravel/laradock/nginx# docker-compose build nginx
|
||||
```
|
||||
|
||||
#### Re Run Your Containers MYSQL and NGINX
|
||||
```
|
||||
$root@midascode:~/laravel/laradock/nginx# docker-compose up -d nginx mysql
|
||||
```
|
||||
|
||||
###### View Your Site with HTTP ONLY (http://yourdomain.com)
|
||||
|
||||
#### Run Site on SSL with Let's Encrypt Certificate
|
||||
|
||||
###### Note: You need to Use Caddy here Instead of Nginx
|
||||
|
||||
###### To go Caddy Folders and Edit CaddyFile
|
||||
|
||||
```
|
||||
$root@midascode:~/laravel/laradock# cd caddy
|
||||
$root@midascode:~/laravel/laradock/caddy# vim Caddyfile
|
||||
```
|
||||
|
||||
Remove 0.0.0.0:80
|
||||
|
||||
```
|
||||
0.0.0.0:80
|
||||
root /var/www/laravel/public
|
||||
```
|
||||
and replace with your https://yourdomain.com
|
||||
|
||||
```
|
||||
https://yourdomain.com
|
||||
root /var/www/laravel/public
|
||||
```
|
||||
uncomment tls
|
||||
|
||||
```
|
||||
#tls self-signed
|
||||
```
|
||||
and replace self-signed with your email address
|
||||
|
||||
```
|
||||
tls midascodebreaker@gmai.com
|
||||
```
|
||||
This is needed Prior to Creating Let's Encypt
|
||||
|
||||
#### Run Your Caddy Container without the -d flag and Generate SSL with Let's Encrypt
|
||||
|
||||
```
|
||||
$root@midascode:~/laravel/laradock/caddy# docker-compose up caddy
|
||||
```
|
||||
|
||||
you will be prompt here to enter your email... you may enter it or not
|
||||
```
|
||||
Attaching to laradock_mysql_1, laradock_caddy_1
|
||||
caddy_1 | Activating privacy features...
|
||||
caddy_1 | Your sites will be served over HTTPS automatically using Let's Encrypt.
|
||||
caddy_1 | By continuing, you agree to the Let's Encrypt Subscriber Agreement at:
|
||||
caddy_1 | https://letsencrypt.org/documents/LE-SA-v1.0.1-July-27-2015.pdf
|
||||
caddy_1 | Activating privacy features... done.
|
||||
caddy_1 | https://yourdomain.com
|
||||
caddy_1 | http://yourdomain.com
|
||||
```
|
||||
|
||||
After it finish Press Ctrl + C to exit ...
|
||||
|
||||
#### Stop All Containers and ReRun Caddy and Other Containers on Background
|
||||
|
||||
```
|
||||
$root@midascode:~/laravel/laradock/caddy# docker-compose down
|
||||
$root@midascode:~/laravel/laradock/caddy# docker-compose up -d mysql caddy
|
||||
```
|
||||
View your Site in the Browser Securely Using HTTPS (https://yourdomain.com)
|
||||
|
||||
##### Note that Certificate will be Automatically Renew By Caddy
|
||||
|
||||
>References:
|
||||
>
|
||||
- [https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-16-04](https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-16-04)
|
||||
- [https://www.digitalocean.com/products/one-click-apps/docker/](https://www.digitalocean.com/products/one-click-apps/docker/)
|
||||
- [https://docs.docker.com/engine/installation/linux/ubuntulinux/](https://docs.docker.com/engine/installation/linux/ubuntulinux/)
|
||||
- [https://docs.docker.com/compose/install/](https://docs.docker.com/compose/install/)
|
||||
- [https://caddyserver.com/docs/automatic-https](https://caddyserver.com/docs/automatic-https)
|
||||
- [https://caddyserver.com/docs/tls](https://caddyserver.com/docs/tls)
|
||||
- [https://caddyserver.com/docs/caddyfile](https://caddyserver.com/docs/caddyfile)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
7
aerospike/Dockerfile
Normal file
7
aerospike/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM aerospike:latest
|
||||
|
||||
MAINTAINER Luciano Jr <luciano@lucianojr.com.br>
|
||||
|
||||
RUN rm /etc/aerospike/aerospike.conf
|
||||
|
||||
ADD aerospike.conf /etc/aerospike/aerospike.conf
|
77
aerospike/aerospike.conf
Normal file
77
aerospike/aerospike.conf
Normal file
@ -0,0 +1,77 @@
|
||||
# Aerospike database configuration file.
|
||||
|
||||
# This stanza must come first.
|
||||
service {
|
||||
user root
|
||||
group root
|
||||
paxos-single-replica-limit 1 # Number of nodes where the replica count is automatically reduced to 1.
|
||||
pidfile /var/run/aerospike/asd.pid
|
||||
service-threads 4
|
||||
transaction-queues 4
|
||||
transaction-threads-per-queue 4
|
||||
proto-fd-max 15000
|
||||
}
|
||||
|
||||
logging {
|
||||
|
||||
# Log file must be an absolute path.
|
||||
file /var/log/aerospike/aerospike.log {
|
||||
context any info
|
||||
}
|
||||
|
||||
# Send log messages to stdout
|
||||
console {
|
||||
context any critical
|
||||
}
|
||||
}
|
||||
|
||||
network {
|
||||
service {
|
||||
address any
|
||||
port 3000
|
||||
|
||||
# Uncomment the following to set the `access-address` parameter to the
|
||||
# IP address of the Docker host. This will the allow the server to correctly
|
||||
# publish the address which applications and other nodes in the cluster to
|
||||
# use when addressing this node.
|
||||
# access-address <IPADDR>
|
||||
}
|
||||
|
||||
heartbeat {
|
||||
|
||||
# mesh is used for environments that do not support multicast
|
||||
mode mesh
|
||||
port 3002
|
||||
|
||||
# use asinfo -v 'tip:host=<ADDR>;port=3002' to inform cluster of
|
||||
# other mesh nodes
|
||||
mesh-port 3002
|
||||
|
||||
interval 150
|
||||
timeout 10
|
||||
}
|
||||
|
||||
fabric {
|
||||
port 3001
|
||||
}
|
||||
|
||||
info {
|
||||
port 3003
|
||||
}
|
||||
}
|
||||
|
||||
namespace test {
|
||||
replication-factor 2
|
||||
memory-size 1G
|
||||
default-ttl 5d # 5 days, use 0 to never expire/evict.
|
||||
|
||||
# storage-engine memory
|
||||
|
||||
# To use file storage backing, comment out the line above and use the
|
||||
# following lines instead.
|
||||
storage-engine device {
|
||||
file /opt/aerospike/data/test.dat
|
||||
filesize 4G
|
||||
data-in-memory true # Store data in memory in addition to file.
|
||||
}
|
||||
}
|
17
apache2/Dockerfile
Normal file
17
apache2/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
FROM webdevops/apache:ubuntu-16.04
|
||||
|
||||
MAINTAINER Eric Pfeiffer <computerfr33k@users.noreply.github.com>
|
||||
|
||||
ARG PHP_SOCKET=php-fpm:9000
|
||||
|
||||
ENV WEB_PHP_SOCKET=$PHP_SOCKET
|
||||
|
||||
ENV WEB_DOCUMENT_ROOT=/var/www/laravel/public
|
||||
|
||||
EXPOSE 80 443
|
||||
|
||||
WORKDIR /var/www/laravel/public
|
||||
|
||||
ENTRYPOINT ["/opt/docker/bin/entrypoint.sh"]
|
||||
|
||||
CMD ["supervisord"]
|
17
beanstalkd-console/Dockerfile
Normal file
17
beanstalkd-console/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
FROM php:latest
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
RUN apt-get update && apt-get install -y curl
|
||||
|
||||
RUN curl -sL https://github.com/ptrofimov/beanstalk_console/archive/master.tar.gz | tar xvz -C /tmp
|
||||
RUN mv /tmp/beanstalk_console-master /source
|
||||
|
||||
RUN apt-get remove --purge -y curl && \
|
||||
apt-get autoclean && \
|
||||
apt-get clean && \
|
||||
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
|
||||
EXPOSE 2080
|
||||
|
||||
CMD bash -c 'BEANSTALK_SERVERS=$BEANSTALKD_PORT_11300_TCP_ADDR:11300 php -S 0.0.0.0:2080 -t /source/public'
|
16
beanstalkd/Dockerfile
Normal file
16
beanstalkd/Dockerfile
Normal file
@ -0,0 +1,16 @@
|
||||
FROM phusion/baseimage:latest
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
ENV PATH /usr/local/rvm/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
|
||||
RUN apt-get update
|
||||
RUN apt-get install -y beanstalkd
|
||||
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
|
||||
VOLUME /var/lib/beanstalkd/data
|
||||
|
||||
EXPOSE 11300
|
||||
|
||||
CMD ["/usr/bin/beanstalkd"]
|
18
caddy/Caddyfile
Normal file
18
caddy/Caddyfile
Normal file
@ -0,0 +1,18 @@
|
||||
# Docs: https://caddyserver.com/docs/caddyfile
|
||||
0.0.0.0:80
|
||||
root /var/www/laravel/public
|
||||
fastcgi / php-fpm:9000 php {
|
||||
index index.php
|
||||
}
|
||||
rewrite {
|
||||
r .*
|
||||
ext /
|
||||
to /index.php?{query}
|
||||
}
|
||||
gzip
|
||||
browse
|
||||
log /var/log/caddy/access.log
|
||||
errors /var/log/caddy/error.log
|
||||
# Uncomment to enable TLS (HTTPS)
|
||||
# Change the first list to listen on port 443 when enabling TLS
|
||||
#tls self_signed
|
24
caddy/Dockerfile
Normal file
24
caddy/Dockerfile
Normal file
@ -0,0 +1,24 @@
|
||||
FROM alpine:3.4
|
||||
|
||||
MAINTAINER Eric Pfeiffer <computerfr33k@users.noreply.github.com>
|
||||
|
||||
ENV caddy_version=0.9.3
|
||||
|
||||
LABEL caddy_version="$caddy_version" architecture="amd64"
|
||||
|
||||
RUN apk update \
|
||||
&& apk upgrade \
|
||||
&& apk add tar curl
|
||||
|
||||
RUN curl --silent --show-error --fail --location \
|
||||
--header "Accept: application/tar+gzip, application/x-gzip, application/octet-stream" -o - \
|
||||
"https://github.com/mholt/caddy/releases/download/v$caddy_version/caddy_linux_amd64.tar.gz" \
|
||||
| tar --no-same-owner -C /usr/bin/ -xz caddy_linux_amd64 \
|
||||
&& mv /usr/bin/caddy_linux_amd64 /usr/bin/caddy \
|
||||
&& chmod 0755 /usr/bin/caddy
|
||||
|
||||
EXPOSE 80 443 2015
|
||||
|
||||
WORKDIR /var/www/laravel/public
|
||||
|
||||
CMD ["/usr/bin/caddy", "-conf", "/etc/Caddyfile"]
|
315
docker-compose.yml
Normal file
315
docker-compose.yml
Normal file
@ -0,0 +1,315 @@
|
||||
version: '2'
|
||||
|
||||
services:
|
||||
|
||||
### Workspace Utilities Container ###########################
|
||||
|
||||
workspace:
|
||||
build:
|
||||
context: ./workspace
|
||||
args:
|
||||
- INSTALL_XDEBUG=false
|
||||
- INSTALL_MONGO=false
|
||||
- INSTALL_NODE=false
|
||||
- INSTALL_YARN=false
|
||||
- INSTALL_DRUSH=false
|
||||
- INSTALL_AEROSPIKE_EXTENSION=false
|
||||
- COMPOSER_GLOBAL_INSTALL=false
|
||||
- INSTALL_WORKSPACE_SSH=false
|
||||
- PUID=1000
|
||||
- PGID=1000
|
||||
- NODE_VERSION=stable
|
||||
- TZ=UTC
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
extra_hosts:
|
||||
# IMPORTANT: Replace with your Docker Host IP (will be appended to /etc/hosts)
|
||||
- "dockerhost:10.0.75.1"
|
||||
ports:
|
||||
- "2222:22"
|
||||
tty: true
|
||||
|
||||
### PHP-FPM Container #######################################
|
||||
|
||||
php-fpm:
|
||||
build:
|
||||
context: ./php-fpm
|
||||
args:
|
||||
- INSTALL_XDEBUG=false
|
||||
- INSTALL_MONGO=false
|
||||
- INSTALL_ZIP_ARCHIVE=false
|
||||
- INSTALL_MEMCACHED=false
|
||||
- INSTALL_OPCACHE=false
|
||||
- INSTALL_AEROSPIKE_EXTENSION=false
|
||||
- CODEIGNITER=false
|
||||
dockerfile: Dockerfile-70
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
expose:
|
||||
- "9000"
|
||||
links:
|
||||
- workspace
|
||||
extra_hosts:
|
||||
# IMPORTANT: Replace with your Docker Host IP (will be appended to /etc/hosts)
|
||||
- "dockerhost:10.0.75.1"
|
||||
environment:
|
||||
# IMPORTANT: Set the Remote Interpreter entry matching name to `laravel`
|
||||
- PHP_IDE_CONFIG=serverName=laravel
|
||||
|
||||
### Nginx Server Container ##################################
|
||||
|
||||
nginx:
|
||||
build:
|
||||
context: ./nginx
|
||||
args:
|
||||
- PHP_UPSTREAM=php-fpm
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
volumes:
|
||||
- ./logs/nginx/:/var/log/nginx
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### Apache Server Container ##################################
|
||||
|
||||
apache2:
|
||||
build:
|
||||
context: ./apache2
|
||||
args:
|
||||
- PHP_SOCKET=php-fpm:9000
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
volumes:
|
||||
- ./logs/apache2:/var/log/apache2
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### HHVM Container ##########################################
|
||||
|
||||
hhvm:
|
||||
build: ./hhvm
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
expose:
|
||||
- "9000"
|
||||
links:
|
||||
- workspace
|
||||
|
||||
### MySQL Container #########################################
|
||||
|
||||
mysql:
|
||||
build: ./mysql
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "3306:3306"
|
||||
environment:
|
||||
MYSQL_DATABASE: homestead
|
||||
MYSQL_USER: homestead
|
||||
MYSQL_PASSWORD: secret
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
|
||||
### MariaDB Container #######################################
|
||||
|
||||
mariadb:
|
||||
build: ./mariadb
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "3306:3306"
|
||||
environment:
|
||||
MYSQL_DATABASE: homestead
|
||||
MYSQL_USER: homestead
|
||||
MYSQL_PASSWORD: secret
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
|
||||
### PostgreSQL Container ####################################
|
||||
|
||||
postgres:
|
||||
build: ./postgres
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "5432:5432"
|
||||
environment:
|
||||
POSTGRES_DB: homestead
|
||||
POSTGRES_USER: homestead
|
||||
POSTGRES_PASSWORD: secret
|
||||
|
||||
### Neo4j Container #########################################
|
||||
|
||||
neo4j:
|
||||
build: ./neo4j
|
||||
ports:
|
||||
- "7474:7474"
|
||||
- "1337:1337"
|
||||
environment:
|
||||
- NEO4J_AUTH=homestead:secret
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
|
||||
### MongoDB Container #######################################
|
||||
|
||||
mongo:
|
||||
build: ./mongo
|
||||
ports:
|
||||
- "27017:27017"
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
|
||||
### Redis Container #########################################
|
||||
|
||||
redis:
|
||||
build: ./redis
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "6379:6379"
|
||||
|
||||
### Aerospike c Container #########################################
|
||||
|
||||
aerospike:
|
||||
build: ./aerospike
|
||||
volumes_from:
|
||||
- workspace
|
||||
- volumes_data
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "3001:3001"
|
||||
- "3002:3002"
|
||||
- "3003:3003"
|
||||
|
||||
|
||||
### Memcached Container #####################################
|
||||
|
||||
memcached:
|
||||
build: ./memcached
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "11211:11211"
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### Beanstalkd Container ####################################
|
||||
|
||||
beanstalkd:
|
||||
build: ./beanstalkd
|
||||
ports:
|
||||
- "11300:11300"
|
||||
privileged: true
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### RabbitMQ Container ####################################
|
||||
|
||||
rabbitmq:
|
||||
build: ./rabbitmq
|
||||
ports:
|
||||
- "5672:5672"
|
||||
- "15671:15671"
|
||||
- "8080:15672"
|
||||
privileged: true
|
||||
environment:
|
||||
RABBITMQ_DEFAULT_USER: guest
|
||||
RABBITMQ_DEFAULT_PASS: guest
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### Beanstalkd Console Container ############################
|
||||
|
||||
beanstalkd-console:
|
||||
build: ./beanstalkd-console
|
||||
ports:
|
||||
- "2080:2080"
|
||||
links:
|
||||
- beanstalkd
|
||||
|
||||
### Caddy Server Container ##################################
|
||||
|
||||
caddy:
|
||||
build: ./caddy
|
||||
volumes_from:
|
||||
- volumes_source
|
||||
- volumes_data
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
- "2015:2015"
|
||||
volumes:
|
||||
- ./caddy/Caddyfile:/etc/Caddyfile
|
||||
- ./logs/caddy:/var/log/caddy
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### phpMyAdmin Container ##################################
|
||||
|
||||
phpmyadmin:
|
||||
build: ./phpmyadmin
|
||||
environment:
|
||||
PMA_ARBITRARY: 1
|
||||
MYSQL_USER: homestead
|
||||
MYSQL_PASSWORD: secret
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "8080:80"
|
||||
links:
|
||||
# for mysql container
|
||||
- "mysql:db"
|
||||
# for mariadb container
|
||||
# - "mariadb:db"
|
||||
|
||||
### pgAdmin Container ##################################
|
||||
|
||||
pgadmin:
|
||||
build: ./pgadmin
|
||||
ports:
|
||||
- "5050:5050"
|
||||
links:
|
||||
- postgres
|
||||
|
||||
### ElasticSearch Container ##################################
|
||||
|
||||
elasticsearch:
|
||||
build: ./elasticsearch
|
||||
volumes_from:
|
||||
- volumes_data
|
||||
ports:
|
||||
- "9200:9200"
|
||||
- "9300:9300"
|
||||
links:
|
||||
- php-fpm
|
||||
|
||||
### Laravel Application Code Container ######################
|
||||
|
||||
volumes_source:
|
||||
image: tianon/true
|
||||
volumes:
|
||||
- ../:/var/www/laravel
|
||||
|
||||
### Databases Data Container ################################
|
||||
|
||||
volumes_data:
|
||||
image: tianon/true
|
||||
volumes:
|
||||
- ./data/mysql:/var/lib/mysql
|
||||
- ./data/postgres:/var/lib/postgresql/data
|
||||
- ./data/memcached:/var/lib/memcached
|
||||
- ./data/redis:/data
|
||||
- ./data/neo4j:/var/lib/neo4j/data
|
||||
- ./data/mongo:/data/db
|
||||
- ./data/aerospike:/opt/aerospike/data
|
||||
- ./data/sessions:/sessions
|
||||
- ./data/caddy:/root/.caddy
|
||||
- ./data/elasticsearch/data:/usr/share/elasticsearch/data
|
||||
- ./data/elasticsearch/pkugins:/usr/share/elasticsearch/pkugins
|
||||
|
||||
### Add more Containers below ###############################
|
@ -1,65 +0,0 @@
|
||||
###########################################################
|
||||
# MAINTAINER: Mahmoud Zalt <mahmoud@zalt.me> #
|
||||
###########################################################
|
||||
|
||||
# PHP + NGINX Container #----------------------------------
|
||||
php-nginx:
|
||||
image: laradock/phpnginx:latest
|
||||
container_name: php-nginx
|
||||
ports:
|
||||
- "80:80"
|
||||
volumes:
|
||||
- ./settings/nginx:/etc/nginx/sites-available
|
||||
- ../laravel:/var/www
|
||||
- ./logs/nginx:/var/log/nginx
|
||||
links:
|
||||
- mysql
|
||||
- redis
|
||||
privileged: true
|
||||
# extra_hosts:
|
||||
# - "laravel.dev:xxx.xxx.xxx.xxx"
|
||||
|
||||
# MySQL Container #----------------------------------------
|
||||
mysql:
|
||||
image: laradock/mysql:latest
|
||||
container_name: mysql
|
||||
ports:
|
||||
- "3306:3306"
|
||||
volumes_from:
|
||||
- data
|
||||
environment:
|
||||
MYSQL_DATABASE: laravel-database
|
||||
MYSQL_USER: root
|
||||
MYSQL_PASSWORD: pass
|
||||
privileged: true
|
||||
|
||||
# Redis Container #----------------------------------------
|
||||
redis:
|
||||
image: laradock/redis:latest
|
||||
container_name: redis
|
||||
ports:
|
||||
- "6379:6379"
|
||||
volumes_from:
|
||||
- data
|
||||
volumes:
|
||||
- ./logs/redis:/var/log/redis
|
||||
restart: always
|
||||
privileged: true
|
||||
|
||||
# Data Volume Container #----------------------------------
|
||||
data:
|
||||
image: laradock/data:latest
|
||||
container_name: data
|
||||
volumes:
|
||||
- /var/lib/mysql
|
||||
- /var/lib/redis
|
||||
|
||||
# Beanstalkd Container #-----------------------------------
|
||||
# beanstalkd:
|
||||
# image: laradock/beanstalkd:latest
|
||||
# container_name: beanstalkd
|
||||
# ports:
|
||||
# - "11300:11300"
|
||||
# privileged: true
|
||||
|
||||
#----------------------------------------------------------
|
5
elasticsearch/Dockerfile
Normal file
5
elasticsearch/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
||||
FROM elasticsearch:latest
|
||||
|
||||
MAINTAINER Bo-Yi Wu <appleboy.tw@gmail.com>
|
||||
|
||||
EXPOSE 9200 9300
|
23
hhvm/Dockerfile
Normal file
23
hhvm/Dockerfile
Normal file
@ -0,0 +1,23 @@
|
||||
FROM ubuntu:14.04
|
||||
|
||||
RUN apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0x5a16e7281be7a449
|
||||
|
||||
RUN apt-get update -y \
|
||||
&& apt-get install -y software-properties-common \
|
||||
&& add-apt-repository "deb http://dl.hhvm.com/ubuntu $(lsb_release -sc) main" \
|
||||
&& apt-get update -y \
|
||||
&& apt-get install -y hhvm \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN mkdir -p /var/www/laravel
|
||||
|
||||
ADD server.ini /etc/hhvm/server.ini
|
||||
|
||||
RUN usermod -u 1000 www-data
|
||||
|
||||
WORKDIR /var/www/laravel
|
||||
|
||||
CMD ["/usr/bin/hhvm", "-m", "server", "-c", "/etc/hhvm/server.ini"]
|
||||
|
||||
EXPOSE 9000
|
20
hhvm/server.ini
Normal file
20
hhvm/server.ini
Normal file
@ -0,0 +1,20 @@
|
||||
; php options
|
||||
|
||||
pid = /var/run/hhvm/pid
|
||||
|
||||
; hhvm specific
|
||||
hhvm.server.port = 9000
|
||||
hhvm.server.type = fastcgi
|
||||
hhvm.server.default_document = index.php
|
||||
hhvm.server.error_document404 = index.php
|
||||
hhvm.server.upload.upload_max_file_size = 25M
|
||||
hhvm.log.level = Error
|
||||
hhvm.log.header = true
|
||||
hhvm.log.access[default][file] = /var/log/hhvm/access.log
|
||||
hhvm.log.access[default][format] = "%h %l %u %t \"%r\" %>s %b"
|
||||
hhvm.server.source_root=/var/www/laravel/public
|
||||
hhvm.repo.central.path = /var/run/hhvm/hhvm.hhbc
|
||||
|
||||
; Uncomment to log to files instead of STDOUT
|
||||
;hhvm.log.use_log_file = true
|
||||
;hhvm.log.file = /var/log/hhvm/error.log
|
@ -1,26 +0,0 @@
|
||||
APP_ENV=local
|
||||
APP_DEBUG=true
|
||||
APP_URL=http://laravel.dev
|
||||
APP_KEY=wqgyoHNBQBgPjLorn3pJNGwYlehhXfD3
|
||||
|
||||
CACHE_DRIVER=redis
|
||||
SESSION_DRIVER=redis
|
||||
QUEUE_DRIVER=beanstalkd
|
||||
|
||||
DB_HOST=laravel.dev
|
||||
DB_DATABASE=laravel-database
|
||||
DB_USERNAME=root
|
||||
DB_PASSWORD=pass
|
||||
|
||||
REDIS_HOST=laravel.dev
|
||||
REDIS_PORT=6379
|
||||
|
||||
BEANSTALKED_HOST=laravel.dev
|
||||
BEANSTALKED_PORT=11300
|
||||
|
||||
MAIL_DRIVER=smtp
|
||||
MAIL_HOST=mailtrap.io
|
||||
MAIL_PORT=2525
|
||||
MAIL_USERNAME=null
|
||||
MAIL_PASSWORD=null
|
||||
MAIL_ENCRYPTION=null
|
@ -1,26 +0,0 @@
|
||||
APP_ENV=local
|
||||
APP_DEBUG=true
|
||||
APP_URL=http://laravel.dev
|
||||
APP_KEY=SomeRandomString
|
||||
|
||||
CACHE_DRIVER=file
|
||||
SESSION_DRIVER=file
|
||||
QUEUE_DRIVER=sync
|
||||
|
||||
DB_HOST=localhost
|
||||
DB_DATABASE=homestead
|
||||
DB_USERNAME=homestead
|
||||
DB_PASSWORD=secret
|
||||
|
||||
REDIS_HOST=localhost
|
||||
REDIS_PORT=6379
|
||||
|
||||
BEANSTALKED_HOST=localhost
|
||||
BEANSTALKED_PORT=11300
|
||||
|
||||
MAIL_DRIVER=smtp
|
||||
MAIL_HOST=mailtrap.io
|
||||
MAIL_PORT=2525
|
||||
MAIL_USERNAME=null
|
||||
MAIL_PASSWORD=null
|
||||
MAIL_ENCRYPTION=null
|
3
laravel/.gitattributes
vendored
3
laravel/.gitattributes
vendored
@ -1,3 +0,0 @@
|
||||
* text=auto
|
||||
*.css linguist-vendored
|
||||
*.less linguist-vendored
|
5
laravel/.gitignore
vendored
5
laravel/.gitignore
vendored
@ -1,5 +0,0 @@
|
||||
/vendor
|
||||
/node_modules
|
||||
Homestead.yaml
|
||||
.env
|
||||
.DS_Store
|
@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
use Illuminate\Console\Command;
|
||||
use Illuminate\Foundation\Inspiring;
|
||||
|
||||
class Inspire extends Command
|
||||
{
|
||||
/**
|
||||
* The name and signature of the console command.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $signature = 'inspire';
|
||||
|
||||
/**
|
||||
* The console command description.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $description = 'Display an inspiring quote';
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
$this->comment(PHP_EOL.Inspiring::quote().PHP_EOL);
|
||||
}
|
||||
}
|
@ -1,30 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console;
|
||||
|
||||
use Illuminate\Console\Scheduling\Schedule;
|
||||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
|
||||
|
||||
class Kernel extends ConsoleKernel
|
||||
{
|
||||
/**
|
||||
* The Artisan commands provided by your application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $commands = [
|
||||
\App\Console\Commands\Inspire::class,
|
||||
];
|
||||
|
||||
/**
|
||||
* Define the application's command schedule.
|
||||
*
|
||||
* @param \Illuminate\Console\Scheduling\Schedule $schedule
|
||||
* @return void
|
||||
*/
|
||||
protected function schedule(Schedule $schedule)
|
||||
{
|
||||
$schedule->command('inspire')
|
||||
->hourly();
|
||||
}
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Events;
|
||||
|
||||
abstract class Event
|
||||
{
|
||||
//
|
||||
}
|
@ -1,44 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Exceptions;
|
||||
|
||||
use Exception;
|
||||
use Symfony\Component\HttpKernel\Exception\HttpException;
|
||||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
|
||||
|
||||
class Handler extends ExceptionHandler
|
||||
{
|
||||
/**
|
||||
* A list of the exception types that should not be reported.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $dontReport = [
|
||||
HttpException::class,
|
||||
];
|
||||
|
||||
/**
|
||||
* Report or log an exception.
|
||||
*
|
||||
* This is a great spot to send exceptions to Sentry, Bugsnag, etc.
|
||||
*
|
||||
* @param \Exception $e
|
||||
* @return void
|
||||
*/
|
||||
public function report(Exception $e)
|
||||
{
|
||||
return parent::report($e);
|
||||
}
|
||||
|
||||
/**
|
||||
* Render an exception into an HTTP response.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Exception $e
|
||||
* @return \Illuminate\Http\Response
|
||||
*/
|
||||
public function render($request, Exception $e)
|
||||
{
|
||||
return parent::render($request, $e);
|
||||
}
|
||||
}
|
@ -1,64 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Auth;
|
||||
|
||||
use App\User;
|
||||
use Validator;
|
||||
use App\Http\Controllers\Controller;
|
||||
use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers;
|
||||
|
||||
class AuthController extends Controller
|
||||
{
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Registration & Login Controller
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This controller handles the registration of new users, as well as the
|
||||
| authentication of existing users. By default, this controller uses
|
||||
| a simple trait to add these behaviors. Why don't you explore it?
|
||||
|
|
||||
*/
|
||||
|
||||
use AuthenticatesAndRegistersUsers;
|
||||
|
||||
/**
|
||||
* Create a new authentication controller instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
$this->middleware('guest', ['except' => 'getLogout']);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a validator for an incoming registration request.
|
||||
*
|
||||
* @param array $data
|
||||
* @return \Illuminate\Contracts\Validation\Validator
|
||||
*/
|
||||
protected function validator(array $data)
|
||||
{
|
||||
return Validator::make($data, [
|
||||
'name' => 'required|max:255',
|
||||
'email' => 'required|email|max:255|unique:users',
|
||||
'password' => 'required|confirmed|min:6',
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new user instance after a valid registration.
|
||||
*
|
||||
* @param array $data
|
||||
* @return User
|
||||
*/
|
||||
protected function create(array $data)
|
||||
{
|
||||
return User::create([
|
||||
'name' => $data['name'],
|
||||
'email' => $data['email'],
|
||||
'password' => bcrypt($data['password']),
|
||||
]);
|
||||
}
|
||||
}
|
@ -1,32 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Auth;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use Illuminate\Foundation\Auth\ResetsPasswords;
|
||||
|
||||
class PasswordController extends Controller
|
||||
{
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Password Reset Controller
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This controller is responsible for handling password reset requests
|
||||
| and uses a simple trait to include this behavior. You're free to
|
||||
| explore this trait and override any methods you wish to tweak.
|
||||
|
|
||||
*/
|
||||
|
||||
use ResetsPasswords;
|
||||
|
||||
/**
|
||||
* Create a new password controller instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
$this->middleware('guest');
|
||||
}
|
||||
}
|
@ -1,12 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use Illuminate\Foundation\Bus\DispatchesJobs;
|
||||
use Illuminate\Routing\Controller as BaseController;
|
||||
use Illuminate\Foundation\Validation\ValidatesRequests;
|
||||
|
||||
abstract class Controller extends BaseController
|
||||
{
|
||||
use DispatchesJobs, ValidatesRequests;
|
||||
}
|
@ -1,42 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use Illuminate\Support\Facades\Cache;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use App\Jobs\TestingQueue;
|
||||
use App\Http\Requests;
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
* Class TestingController
|
||||
*
|
||||
* @package App\Http\Controllers
|
||||
* @author Mahmoud Zalt <mahmoud@zalt.me>
|
||||
*/
|
||||
class TestingController extends Controller
|
||||
{
|
||||
|
||||
/**
|
||||
* Test some software's and respond to the user
|
||||
*
|
||||
* @return \Illuminate\View\View
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function test()
|
||||
{
|
||||
try {
|
||||
// Testing Database (MySQL)
|
||||
DB::connection()->getDatabaseName();
|
||||
|
||||
// Testing Cache (Redis)
|
||||
Cache::pull('test');
|
||||
|
||||
return view('welcome');
|
||||
|
||||
} catch(Exception $e) {
|
||||
echo $e->getMessage();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http;
|
||||
|
||||
use Illuminate\Foundation\Http\Kernel as HttpKernel;
|
||||
|
||||
class Kernel extends HttpKernel
|
||||
{
|
||||
/**
|
||||
* The application's global HTTP middleware stack.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $middleware = [
|
||||
\Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode::class,
|
||||
\App\Http\Middleware\EncryptCookies::class,
|
||||
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
|
||||
\Illuminate\Session\Middleware\StartSession::class,
|
||||
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
||||
\App\Http\Middleware\VerifyCsrfToken::class,
|
||||
];
|
||||
|
||||
/**
|
||||
* The application's route middleware.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $routeMiddleware = [
|
||||
'auth' => \App\Http\Middleware\Authenticate::class,
|
||||
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
|
||||
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
|
||||
];
|
||||
}
|
@ -1,47 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Closure;
|
||||
use Illuminate\Contracts\Auth\Guard;
|
||||
|
||||
class Authenticate
|
||||
{
|
||||
/**
|
||||
* The Guard implementation.
|
||||
*
|
||||
* @var Guard
|
||||
*/
|
||||
protected $auth;
|
||||
|
||||
/**
|
||||
* Create a new filter instance.
|
||||
*
|
||||
* @param Guard $auth
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(Guard $auth)
|
||||
{
|
||||
$this->auth = $auth;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle an incoming request.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Closure $next
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle($request, Closure $next)
|
||||
{
|
||||
if ($this->auth->guest()) {
|
||||
if ($request->ajax()) {
|
||||
return response('Unauthorized.', 401);
|
||||
} else {
|
||||
return redirect()->guest('auth/login');
|
||||
}
|
||||
}
|
||||
|
||||
return $next($request);
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Cookie\Middleware\EncryptCookies as BaseEncrypter;
|
||||
|
||||
class EncryptCookies extends BaseEncrypter
|
||||
{
|
||||
/**
|
||||
* The names of the cookies that should not be encrypted.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
//
|
||||
];
|
||||
}
|
@ -1,43 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Closure;
|
||||
use Illuminate\Contracts\Auth\Guard;
|
||||
|
||||
class RedirectIfAuthenticated
|
||||
{
|
||||
/**
|
||||
* The Guard implementation.
|
||||
*
|
||||
* @var Guard
|
||||
*/
|
||||
protected $auth;
|
||||
|
||||
/**
|
||||
* Create a new filter instance.
|
||||
*
|
||||
* @param Guard $auth
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(Guard $auth)
|
||||
{
|
||||
$this->auth = $auth;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle an incoming request.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Closure $next
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle($request, Closure $next)
|
||||
{
|
||||
if ($this->auth->check()) {
|
||||
return redirect('/home');
|
||||
}
|
||||
|
||||
return $next($request);
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as BaseVerifier;
|
||||
|
||||
class VerifyCsrfToken extends BaseVerifier
|
||||
{
|
||||
/**
|
||||
* The URIs that should be excluded from CSRF verification.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
//
|
||||
];
|
||||
}
|
@ -1,10 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Requests;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
abstract class Request extends FormRequest
|
||||
{
|
||||
//
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here is where you can register all of the routes for an application.
|
||||
| It's a breeze. Simply tell Laravel the URIs it should respond to
|
||||
| and give it the controller to call when that URI is requested.
|
||||
|
|
||||
*/
|
||||
|
||||
Route::get('/', 'TestingController@test');
|
@ -1,21 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Jobs;
|
||||
|
||||
use Illuminate\Bus\Queueable;
|
||||
|
||||
abstract class Job
|
||||
{
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Queueable Jobs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This job base class provides a central location to place any logic that
|
||||
| is shared across all of your jobs. The trait included with the class
|
||||
| provides access to the "queueOn" and "delay" queue helper methods.
|
||||
|
|
||||
*/
|
||||
|
||||
use Queueable;
|
||||
}
|
@ -1,28 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
class AppServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* Bootstrap any application services.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function boot()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Register any application services.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function register()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Contracts\Events\Dispatcher as DispatcherContract;
|
||||
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
|
||||
|
||||
class EventServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* The event listener mappings for the application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $listen = [
|
||||
'App\Events\SomeEvent' => [
|
||||
'App\Listeners\EventListener',
|
||||
],
|
||||
];
|
||||
|
||||
/**
|
||||
* Register any other events for your application.
|
||||
*
|
||||
* @param \Illuminate\Contracts\Events\Dispatcher $events
|
||||
* @return void
|
||||
*/
|
||||
public function boot(DispatcherContract $events)
|
||||
{
|
||||
parent::boot($events);
|
||||
|
||||
//
|
||||
}
|
||||
}
|
@ -1,44 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Routing\Router;
|
||||
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
|
||||
|
||||
class RouteServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* This namespace is applied to the controller routes in your routes file.
|
||||
*
|
||||
* In addition, it is set as the URL generator's root namespace.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $namespace = 'App\Http\Controllers';
|
||||
|
||||
/**
|
||||
* Define your route model bindings, pattern filters, etc.
|
||||
*
|
||||
* @param \Illuminate\Routing\Router $router
|
||||
* @return void
|
||||
*/
|
||||
public function boot(Router $router)
|
||||
{
|
||||
//
|
||||
|
||||
parent::boot($router);
|
||||
}
|
||||
|
||||
/**
|
||||
* Define the routes for the application.
|
||||
*
|
||||
* @param \Illuminate\Routing\Router $router
|
||||
* @return void
|
||||
*/
|
||||
public function map(Router $router)
|
||||
{
|
||||
$router->group(['namespace' => $this->namespace], function ($router) {
|
||||
require app_path('Http/routes.php');
|
||||
});
|
||||
}
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App;
|
||||
|
||||
use Illuminate\Auth\Authenticatable;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Auth\Passwords\CanResetPassword;
|
||||
use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract;
|
||||
use Illuminate\Contracts\Auth\CanResetPassword as CanResetPasswordContract;
|
||||
|
||||
class User extends Model implements AuthenticatableContract, CanResetPasswordContract
|
||||
{
|
||||
use Authenticatable, CanResetPassword;
|
||||
|
||||
/**
|
||||
* The database table used by the model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $table = 'users';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $fillable = ['name', 'email', 'password'];
|
||||
|
||||
/**
|
||||
* The attributes excluded from the model's JSON form.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $hidden = ['password', 'remember_token'];
|
||||
}
|
@ -1,51 +0,0 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Auto Loader
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Composer provides a convenient, automatically generated class loader
|
||||
| for our application. We just need to utilize it! We'll require it
|
||||
| into the script here so that we do not have to worry about the
|
||||
| loading of any our classes "manually". Feels great to relax.
|
||||
|
|
||||
*/
|
||||
|
||||
require __DIR__.'/bootstrap/autoload.php';
|
||||
|
||||
$app = require_once __DIR__.'/bootstrap/app.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Artisan Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When we run the console application, the current CLI command will be
|
||||
| executed in this console and the response sent back to a terminal
|
||||
| or another output device for the developers. Here goes nothing!
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel = $app->make(Illuminate\Contracts\Console\Kernel::class);
|
||||
|
||||
$status = $kernel->handle(
|
||||
$input = new Symfony\Component\Console\Input\ArgvInput,
|
||||
new Symfony\Component\Console\Output\ConsoleOutput
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Shutdown The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Once Artisan has finished running. We will fire off the shutdown events
|
||||
| so that any final work may be done by the application before we shut
|
||||
| down the process. This is the last thing to happen to the request.
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel->terminate($input, $status);
|
||||
|
||||
exit($status);
|
@ -1,55 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The first thing we will do is create a new Laravel application instance
|
||||
| which serves as the "glue" for all the components of Laravel, and is
|
||||
| the IoC container for the system binding all of the various parts.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = new Illuminate\Foundation\Application(
|
||||
realpath(__DIR__.'/../')
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Bind Important Interfaces
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Next, we need to bind some important interfaces into the container so
|
||||
| we will be able to resolve them when needed. The kernels serve the
|
||||
| incoming requests to this application from both the web and CLI.
|
||||
|
|
||||
*/
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Http\Kernel::class,
|
||||
App\Http\Kernel::class
|
||||
);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Console\Kernel::class,
|
||||
App\Console\Kernel::class
|
||||
);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Debug\ExceptionHandler::class,
|
||||
App\Exceptions\Handler::class
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Return The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This script returns the application instance. The instance is given to
|
||||
| the calling script so we can separate the building of the instances
|
||||
| from the actual running of the application and sending responses.
|
||||
|
|
||||
*/
|
||||
|
||||
return $app;
|
@ -1,34 +0,0 @@
|
||||
<?php
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Composer Auto Loader
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Composer provides a convenient, automatically generated class loader
|
||||
| for our application. We just need to utilize it! We'll require it
|
||||
| into the script here so that we do not have to worry about the
|
||||
| loading of any our classes "manually". Feels great to relax.
|
||||
|
|
||||
*/
|
||||
|
||||
require __DIR__.'/../vendor/autoload.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Include The Compiled Class File
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| To dramatically increase your application's performance, you may use a
|
||||
| compiled class file which contains all of the classes commonly used
|
||||
| by a request. The Artisan "optimize" is used to create this file.
|
||||
|
|
||||
*/
|
||||
|
||||
$compiledPath = __DIR__.'/cache/compiled.php';
|
||||
|
||||
if (file_exists($compiledPath)) {
|
||||
require $compiledPath;
|
||||
}
|
2
laravel/bootstrap/cache/.gitignore
vendored
2
laravel/bootstrap/cache/.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
@ -1,53 +0,0 @@
|
||||
{
|
||||
"name": "laravel/laravel",
|
||||
"description": "The Laravel Framework.",
|
||||
"keywords": ["framework", "laravel"],
|
||||
"license": "MIT",
|
||||
"type": "project",
|
||||
"require": {
|
||||
"php": ">=5.5.9",
|
||||
"laravel/framework": "5.1.*",
|
||||
"predis/predis": "~1.0",
|
||||
"pda/pheanstalk": "~3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"fzaninotto/faker": "~1.4",
|
||||
"mockery/mockery": "0.9.*",
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"phpspec/phpspec": "~2.1"
|
||||
},
|
||||
"autoload": {
|
||||
"classmap": [
|
||||
"database"
|
||||
],
|
||||
"psr-4": {
|
||||
"App\\": "app/"
|
||||
}
|
||||
},
|
||||
"autoload-dev": {
|
||||
"classmap": [
|
||||
"tests/TestCase.php"
|
||||
]
|
||||
},
|
||||
"scripts": {
|
||||
"post-install-cmd": [
|
||||
"php artisan clear-compiled",
|
||||
"php artisan optimize"
|
||||
],
|
||||
"pre-update-cmd": [
|
||||
"php artisan clear-compiled"
|
||||
],
|
||||
"post-update-cmd": [
|
||||
"php artisan optimize"
|
||||
],
|
||||
"post-root-package-install": [
|
||||
"php -r \"copy('.env.example', '.env');\""
|
||||
],
|
||||
"post-create-project-cmd": [
|
||||
"php artisan key:generate"
|
||||
]
|
||||
},
|
||||
"config": {
|
||||
"preferred-install": "dist"
|
||||
}
|
||||
}
|
3034
laravel/composer.lock
generated
3034
laravel/composer.lock
generated
File diff suppressed because it is too large
Load Diff
@ -1,197 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Debug Mode
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When your application is in debug mode, detailed error messages with
|
||||
| stack traces will be shown on every error that occurs within your
|
||||
| application. If disabled, a simple generic error page is shown.
|
||||
|
|
||||
*/
|
||||
|
||||
'debug' => env('APP_DEBUG', false),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application URL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This URL is used by the console to properly generate URLs when using
|
||||
| the Artisan command line tool. You should set this to the root of
|
||||
| your application so that it is used when running Artisan tasks.
|
||||
|
|
||||
*/
|
||||
|
||||
'url' => env('APP_URL', 'http://localhost'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Timezone
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify the default timezone for your application, which
|
||||
| will be used by the PHP date and date-time functions. We have gone
|
||||
| ahead and set this to a sensible default for you out of the box.
|
||||
|
|
||||
*/
|
||||
|
||||
'timezone' => 'UTC',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Locale Configuration
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The application locale determines the default locale that will be used
|
||||
| by the translation service provider. You are free to set this value
|
||||
| to any of the locales which will be supported by the application.
|
||||
|
|
||||
*/
|
||||
|
||||
'locale' => 'en',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Fallback Locale
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The fallback locale determines the locale to use when the current one
|
||||
| is not available. You may change the value to correspond to any of
|
||||
| the language folders that are provided through your application.
|
||||
|
|
||||
*/
|
||||
|
||||
'fallback_locale' => 'en',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Encryption Key
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This key is used by the Illuminate encrypter service and should be set
|
||||
| to a random, 32 character string, otherwise these encrypted strings
|
||||
| will not be safe. Please do this before deploying an application!
|
||||
|
|
||||
*/
|
||||
|
||||
'key' => env('APP_KEY', 'SomeRandomString'),
|
||||
|
||||
'cipher' => 'AES-256-CBC',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Logging Configuration
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may configure the log settings for your application. Out of
|
||||
| the box, Laravel uses the Monolog PHP logging library. This gives
|
||||
| you a variety of powerful log handlers / formatters to utilize.
|
||||
|
|
||||
| Available Settings: "single", "daily", "syslog", "errorlog"
|
||||
|
|
||||
*/
|
||||
|
||||
'log' => 'single',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Autoloaded Service Providers
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The service providers listed here will be automatically loaded on the
|
||||
| request to your application. Feel free to add your own services to
|
||||
| this array to grant expanded functionality to your applications.
|
||||
|
|
||||
*/
|
||||
|
||||
'providers' => [
|
||||
|
||||
/*
|
||||
* Laravel Framework Service Providers...
|
||||
*/
|
||||
Illuminate\Foundation\Providers\ArtisanServiceProvider::class,
|
||||
Illuminate\Auth\AuthServiceProvider::class,
|
||||
Illuminate\Broadcasting\BroadcastServiceProvider::class,
|
||||
Illuminate\Bus\BusServiceProvider::class,
|
||||
Illuminate\Cache\CacheServiceProvider::class,
|
||||
Illuminate\Foundation\Providers\ConsoleSupportServiceProvider::class,
|
||||
Illuminate\Routing\ControllerServiceProvider::class,
|
||||
Illuminate\Cookie\CookieServiceProvider::class,
|
||||
Illuminate\Database\DatabaseServiceProvider::class,
|
||||
Illuminate\Encryption\EncryptionServiceProvider::class,
|
||||
Illuminate\Filesystem\FilesystemServiceProvider::class,
|
||||
Illuminate\Foundation\Providers\FoundationServiceProvider::class,
|
||||
Illuminate\Hashing\HashServiceProvider::class,
|
||||
Illuminate\Mail\MailServiceProvider::class,
|
||||
Illuminate\Pagination\PaginationServiceProvider::class,
|
||||
Illuminate\Pipeline\PipelineServiceProvider::class,
|
||||
Illuminate\Queue\QueueServiceProvider::class,
|
||||
Illuminate\Redis\RedisServiceProvider::class,
|
||||
Illuminate\Auth\Passwords\PasswordResetServiceProvider::class,
|
||||
Illuminate\Session\SessionServiceProvider::class,
|
||||
Illuminate\Translation\TranslationServiceProvider::class,
|
||||
Illuminate\Validation\ValidationServiceProvider::class,
|
||||
Illuminate\View\ViewServiceProvider::class,
|
||||
|
||||
/*
|
||||
* Application Service Providers...
|
||||
*/
|
||||
App\Providers\AppServiceProvider::class,
|
||||
App\Providers\EventServiceProvider::class,
|
||||
App\Providers\RouteServiceProvider::class,
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Aliases
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This array of class aliases will be registered when this application
|
||||
| is started. However, feel free to register as many as you wish as
|
||||
| the aliases are "lazy" loaded so they don't hinder performance.
|
||||
|
|
||||
*/
|
||||
|
||||
'aliases' => [
|
||||
|
||||
'App' => Illuminate\Support\Facades\App::class,
|
||||
'Artisan' => Illuminate\Support\Facades\Artisan::class,
|
||||
'Auth' => Illuminate\Support\Facades\Auth::class,
|
||||
'Blade' => Illuminate\Support\Facades\Blade::class,
|
||||
'Bus' => Illuminate\Support\Facades\Bus::class,
|
||||
'Cache' => Illuminate\Support\Facades\Cache::class,
|
||||
'Config' => Illuminate\Support\Facades\Config::class,
|
||||
'Cookie' => Illuminate\Support\Facades\Cookie::class,
|
||||
'Crypt' => Illuminate\Support\Facades\Crypt::class,
|
||||
'DB' => Illuminate\Support\Facades\DB::class,
|
||||
'Eloquent' => Illuminate\Database\Eloquent\Model::class,
|
||||
'Event' => Illuminate\Support\Facades\Event::class,
|
||||
'File' => Illuminate\Support\Facades\File::class,
|
||||
'Hash' => Illuminate\Support\Facades\Hash::class,
|
||||
'Input' => Illuminate\Support\Facades\Input::class,
|
||||
'Inspiring' => Illuminate\Foundation\Inspiring::class,
|
||||
'Lang' => Illuminate\Support\Facades\Lang::class,
|
||||
'Log' => Illuminate\Support\Facades\Log::class,
|
||||
'Mail' => Illuminate\Support\Facades\Mail::class,
|
||||
'Password' => Illuminate\Support\Facades\Password::class,
|
||||
'Queue' => Illuminate\Support\Facades\Queue::class,
|
||||
'Redirect' => Illuminate\Support\Facades\Redirect::class,
|
||||
'Redis' => Illuminate\Support\Facades\Redis::class,
|
||||
'Request' => Illuminate\Support\Facades\Request::class,
|
||||
'Response' => Illuminate\Support\Facades\Response::class,
|
||||
'Route' => Illuminate\Support\Facades\Route::class,
|
||||
'Schema' => Illuminate\Support\Facades\Schema::class,
|
||||
'Session' => Illuminate\Support\Facades\Session::class,
|
||||
'Storage' => Illuminate\Support\Facades\Storage::class,
|
||||
'URL' => Illuminate\Support\Facades\URL::class,
|
||||
'Validator' => Illuminate\Support\Facades\Validator::class,
|
||||
'View' => Illuminate\Support\Facades\View::class,
|
||||
|
||||
],
|
||||
|
||||
];
|
@ -1,67 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Authentication Driver
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option controls the authentication driver that will be utilized.
|
||||
| This driver manages the retrieval and authentication of the users
|
||||
| attempting to get access to protected areas of your application.
|
||||
|
|
||||
| Supported: "database", "eloquent"
|
||||
|
|
||||
*/
|
||||
|
||||
'driver' => 'eloquent',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Authentication Model
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the "Eloquent" authentication driver, we need to know which
|
||||
| Eloquent model should be used to retrieve your users. Of course, it
|
||||
| is often just the "User" model but you may use whatever you like.
|
||||
|
|
||||
*/
|
||||
|
||||
'model' => App\User::class,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Authentication Table
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the "Database" authentication driver, we need to know which
|
||||
| table should be used to retrieve your users. We have chosen a basic
|
||||
| default value but you may easily change it to any table you like.
|
||||
|
|
||||
*/
|
||||
|
||||
'table' => 'users',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Password Reset Settings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may set the options for resetting passwords including the view
|
||||
| that is your password reset e-mail. You can also set the name of the
|
||||
| table that maintains all of the reset tokens for your application.
|
||||
|
|
||||
| The expire time is the number of minutes that the reset token should be
|
||||
| considered valid. This security feature keeps tokens short-lived so
|
||||
| they have less time to be guessed. You may change this as needed.
|
||||
|
|
||||
*/
|
||||
|
||||
'password' => [
|
||||
'email' => 'emails.password',
|
||||
'table' => 'password_resets',
|
||||
'expire' => 60,
|
||||
],
|
||||
|
||||
];
|
@ -1,49 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Broadcaster
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option controls the default broadcaster that will be used by the
|
||||
| framework when an event needs to be broadcast. You may set this to
|
||||
| any of the connections defined in the "connections" array below.
|
||||
|
|
||||
*/
|
||||
|
||||
'default' => env('BROADCAST_DRIVER', 'pusher'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Broadcast Connections
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define all of the broadcast connections that will be used
|
||||
| to broadcast events to other systems or over websockets. Samples of
|
||||
| each available type of connection are provided inside this array.
|
||||
|
|
||||
*/
|
||||
|
||||
'connections' => [
|
||||
|
||||
'pusher' => [
|
||||
'driver' => 'pusher',
|
||||
'key' => env('PUSHER_KEY'),
|
||||
'secret' => env('PUSHER_SECRET'),
|
||||
'app_id' => env('PUSHER_APP_ID'),
|
||||
],
|
||||
|
||||
'redis' => [
|
||||
'driver' => 'redis',
|
||||
'connection' => 'default',
|
||||
],
|
||||
|
||||
'log' => [
|
||||
'driver' => 'log',
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
];
|
@ -1,79 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Cache Store
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option controls the default cache connection that gets used while
|
||||
| using this caching library. This connection is used when another is
|
||||
| not explicitly specified when executing a given caching function.
|
||||
|
|
||||
*/
|
||||
|
||||
'default' => env('CACHE_DRIVER', 'file'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Stores
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define all of the cache "stores" for your application as
|
||||
| well as their drivers. You may even define multiple stores for the
|
||||
| same cache driver to group types of items stored in your caches.
|
||||
|
|
||||
*/
|
||||
|
||||
'stores' => [
|
||||
|
||||
'apc' => [
|
||||
'driver' => 'apc',
|
||||
],
|
||||
|
||||
'array' => [
|
||||
'driver' => 'array',
|
||||
],
|
||||
|
||||
'database' => [
|
||||
'driver' => 'database',
|
||||
'table' => 'cache',
|
||||
'connection' => null,
|
||||
],
|
||||
|
||||
'file' => [
|
||||
'driver' => 'file',
|
||||
'path' => storage_path('framework/cache'),
|
||||
],
|
||||
|
||||
'memcached' => [
|
||||
'driver' => 'memcached',
|
||||
'servers' => [
|
||||
[
|
||||
'host' => '127.0.0.1', 'port' => 11211, 'weight' => 100,
|
||||
],
|
||||
],
|
||||
],
|
||||
|
||||
'redis' => [
|
||||
'driver' => 'redis',
|
||||
'connection' => 'default',
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Key Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When utilizing a RAM based store such as APC or Memcached, there might
|
||||
| be other applications utilizing the same cache. So, we'll specify a
|
||||
| value to get prefixed to all our keys so we can avoid collisions.
|
||||
|
|
||||
*/
|
||||
|
||||
'prefix' => 'laravel',
|
||||
|
||||
];
|
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Additional Compiled Classes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify additional classes to include in the compiled file
|
||||
| generated by the `artisan optimize` command. These should be classes
|
||||
| that are included on basically every request into the application.
|
||||
|
|
||||
*/
|
||||
|
||||
'files' => [
|
||||
//
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Compiled File Providers
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may list service providers which define a "compiles" function
|
||||
| that returns additional files that should be compiled, providing an
|
||||
| easy way to get common files from any packages you are utilizing.
|
||||
|
|
||||
*/
|
||||
|
||||
'providers' => [
|
||||
//
|
||||
],
|
||||
|
||||
];
|
@ -1,126 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| PDO Fetch Style
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default, database results will be returned as instances of the PHP
|
||||
| stdClass object; however, you may desire to retrieve records in an
|
||||
| array format for simplicity. Here you can tweak the fetch style.
|
||||
|
|
||||
*/
|
||||
|
||||
'fetch' => PDO::FETCH_CLASS,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Database Connection Name
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify which of the database connections below you wish
|
||||
| to use as your default connection for all database work. Of course
|
||||
| you may use many connections at once using the Database library.
|
||||
|
|
||||
*/
|
||||
|
||||
'default' => env('DB_CONNECTION', 'mysql'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Database Connections
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here are each of the database connections setup for your application.
|
||||
| Of course, examples of configuring each database platform that is
|
||||
| supported by Laravel is shown below to make development simple.
|
||||
|
|
||||
|
|
||||
| All database work in Laravel is done through the PHP PDO facilities
|
||||
| so make sure you have the driver for your particular database of
|
||||
| choice installed on your machine before you begin development.
|
||||
|
|
||||
*/
|
||||
|
||||
'connections' => [
|
||||
|
||||
'sqlite' => [
|
||||
'driver' => 'sqlite',
|
||||
'database' => storage_path('database.sqlite'),
|
||||
'prefix' => '',
|
||||
],
|
||||
|
||||
'mysql' => [
|
||||
'driver' => 'mysql',
|
||||
'host' => env('DB_HOST', 'localhost'),
|
||||
'database' => env('DB_DATABASE', 'forge'),
|
||||
'username' => env('DB_USERNAME', 'forge'),
|
||||
'password' => env('DB_PASSWORD', ''),
|
||||
'charset' => 'utf8',
|
||||
'collation' => 'utf8_unicode_ci',
|
||||
'prefix' => '',
|
||||
'strict' => false,
|
||||
],
|
||||
|
||||
'pgsql' => [
|
||||
'driver' => 'pgsql',
|
||||
'host' => env('DB_HOST', 'localhost'),
|
||||
'database' => env('DB_DATABASE', 'forge'),
|
||||
'username' => env('DB_USERNAME', 'forge'),
|
||||
'password' => env('DB_PASSWORD', ''),
|
||||
'charset' => 'utf8',
|
||||
'prefix' => '',
|
||||
'schema' => 'public',
|
||||
],
|
||||
|
||||
'sqlsrv' => [
|
||||
'driver' => 'sqlsrv',
|
||||
'host' => env('DB_HOST', 'localhost'),
|
||||
'database' => env('DB_DATABASE', 'forge'),
|
||||
'username' => env('DB_USERNAME', 'forge'),
|
||||
'password' => env('DB_PASSWORD', ''),
|
||||
'charset' => 'utf8',
|
||||
'prefix' => '',
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migration Repository Table
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This table keeps track of all the migrations that have already run for
|
||||
| your application. Using this information, we can determine which of
|
||||
| the migrations on disk haven't actually been run in the database.
|
||||
|
|
||||
*/
|
||||
|
||||
'migrations' => 'migrations',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Redis Databases
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Redis is an open source, fast, and advanced key-value store that also
|
||||
| provides a richer set of commands than a typical key-value systems
|
||||
| such as APC or Memcached. Laravel makes it easy to dig right in.
|
||||
|
|
||||
*/
|
||||
|
||||
'redis' => [
|
||||
|
||||
'cluster' => false,
|
||||
|
||||
'default' => [
|
||||
'host' => env('REDIS_HOST', 'localhost'),
|
||||
'port' => env('REDIS_PORT', '6379'),
|
||||
'database' => 0,
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
];
|
@ -1,85 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Filesystem Disk
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify the default filesystem disk that should be used
|
||||
| by the framework. A "local" driver, as well as a variety of cloud
|
||||
| based drivers are available for your choosing. Just store away!
|
||||
|
|
||||
| Supported: "local", "ftp", "s3", "rackspace"
|
||||
|
|
||||
*/
|
||||
|
||||
'default' => 'local',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Cloud Filesystem Disk
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Many applications store files both locally and in the cloud. For this
|
||||
| reason, you may specify a default "cloud" driver here. This driver
|
||||
| will be bound as the Cloud disk implementation in the container.
|
||||
|
|
||||
*/
|
||||
|
||||
'cloud' => 's3',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Filesystem Disks
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may configure as many filesystem "disks" as you wish, and you
|
||||
| may even configure multiple disks of the same driver. Defaults have
|
||||
| been setup for each driver as an example of the required options.
|
||||
|
|
||||
*/
|
||||
|
||||
'disks' => [
|
||||
|
||||
'local' => [
|
||||
'driver' => 'local',
|
||||
'root' => storage_path('app'),
|
||||
],
|
||||
|
||||
'ftp' => [
|
||||
'driver' => 'ftp',
|
||||
'host' => 'ftp.example.com',
|
||||
'username' => 'your-username',
|
||||
'password' => 'your-password',
|
||||
|
||||
// Optional FTP Settings...
|
||||
// 'port' => 21,
|
||||
// 'root' => '',
|
||||
// 'passive' => true,
|
||||
// 'ssl' => true,
|
||||
// 'timeout' => 30,
|
||||
],
|
||||
|
||||
's3' => [
|
||||
'driver' => 's3',
|
||||
'key' => 'your-key',
|
||||
'secret' => 'your-secret',
|
||||
'region' => 'your-region',
|
||||
'bucket' => 'your-bucket',
|
||||
],
|
||||
|
||||
'rackspace' => [
|
||||
'driver' => 'rackspace',
|
||||
'username' => 'your-username',
|
||||
'key' => 'your-key',
|
||||
'container' => 'your-container',
|
||||
'endpoint' => 'https://identity.api.rackspacecloud.com/v2.0/',
|
||||
'region' => 'IAD',
|
||||
'url_type' => 'publicURL',
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
];
|
@ -1,124 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Mail Driver
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Laravel supports both SMTP and PHP's "mail" function as drivers for the
|
||||
| sending of e-mail. You may specify which one you're using throughout
|
||||
| your application here. By default, Laravel is setup for SMTP mail.
|
||||
|
|
||||
| Supported: "smtp", "mail", "sendmail", "mailgun", "mandrill", "ses", "log"
|
||||
|
|
||||
*/
|
||||
|
||||
'driver' => env('MAIL_DRIVER', 'smtp'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| SMTP Host Address
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may provide the host address of the SMTP server used by your
|
||||
| applications. A default option is provided that is compatible with
|
||||
| the Mailgun mail service which will provide reliable deliveries.
|
||||
|
|
||||
*/
|
||||
|
||||
'host' => env('MAIL_HOST', 'smtp.mailgun.org'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| SMTP Host Port
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is the SMTP port used by your application to deliver e-mails to
|
||||
| users of the application. Like the host we have set this value to
|
||||
| stay compatible with the Mailgun e-mail application by default.
|
||||
|
|
||||
*/
|
||||
|
||||
'port' => env('MAIL_PORT', 587),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Global "From" Address
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You may wish for all e-mails sent by your application to be sent from
|
||||
| the same address. Here, you may specify a name and address that is
|
||||
| used globally for all e-mails that are sent by your application.
|
||||
|
|
||||
*/
|
||||
|
||||
'from' => ['address' => null, 'name' => null],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| E-Mail Encryption Protocol
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify the encryption protocol that should be used when
|
||||
| the application send e-mail messages. A sensible default using the
|
||||
| transport layer security protocol should provide great security.
|
||||
|
|
||||
*/
|
||||
|
||||
'encryption' => env('MAIL_ENCRYPTION', 'tls'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| SMTP Server Username
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your SMTP server requires a username for authentication, you should
|
||||
| set it here. This will get used to authenticate with your server on
|
||||
| connection. You may also set the "password" value below this one.
|
||||
|
|
||||
*/
|
||||
|
||||
'username' => env('MAIL_USERNAME'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| SMTP Server Password
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may set the password required by your SMTP server to send out
|
||||
| messages from your application. This will be given to the server on
|
||||
| connection so that the application will be able to send messages.
|
||||
|
|
||||
*/
|
||||
|
||||
'password' => env('MAIL_PASSWORD'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Sendmail System Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the "sendmail" driver to send e-mails, we will need to know
|
||||
| the path to where Sendmail lives on this server. A default path has
|
||||
| been provided here, which will work well on most of your systems.
|
||||
|
|
||||
*/
|
||||
|
||||
'sendmail' => '/usr/sbin/sendmail -bs',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Mail "Pretend"
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When this option is enabled, e-mail will not actually be sent over the
|
||||
| web and will instead be written to your application's logs files so
|
||||
| you may inspect the message. This is great for local development.
|
||||
|
|
||||
*/
|
||||
|
||||
'pretend' => false,
|
||||
|
||||
];
|
@ -1,94 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Queue Driver
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The Laravel queue API supports a variety of back-ends via an unified
|
||||
| API, giving you convenient access to each back-end using the same
|
||||
| syntax for each one. Here you may set the default queue driver.
|
||||
|
|
||||
| Supported: "null", "sync", "database", "beanstalkd",
|
||||
| "sqs", "iron", "redis"
|
||||
|
|
||||
*/
|
||||
|
||||
'default' => env('QUEUE_DRIVER', 'sync'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Queue Connections
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may configure the connection information for each server that
|
||||
| is used by your application. A default configuration has been added
|
||||
| for each back-end shipped with Laravel. You are free to add more.
|
||||
|
|
||||
*/
|
||||
|
||||
'connections' => [
|
||||
|
||||
'sync' => [
|
||||
'driver' => 'sync',
|
||||
],
|
||||
|
||||
'database' => [
|
||||
'driver' => 'database',
|
||||
'table' => 'jobs',
|
||||
'queue' => 'default',
|
||||
'expire' => 60,
|
||||
],
|
||||
|
||||
'beanstalkd' => [
|
||||
'driver' => 'beanstalkd',
|
||||
'host' => env('BEANSTALKED_HOST', 'localhost'),
|
||||
'queue' => 'default',
|
||||
'ttr' => 60,
|
||||
'port' => env('BEANSTALKED_PORT', 11300),
|
||||
],
|
||||
|
||||
'sqs' => [
|
||||
'driver' => 'sqs',
|
||||
'key' => 'your-public-key',
|
||||
'secret' => 'your-secret-key',
|
||||
'queue' => 'your-queue-url',
|
||||
'region' => 'us-east-1',
|
||||
],
|
||||
|
||||
'iron' => [
|
||||
'driver' => 'iron',
|
||||
'host' => 'mq-aws-us-east-1.iron.io',
|
||||
'token' => 'your-token',
|
||||
'project' => 'your-project-id',
|
||||
'queue' => 'your-queue-name',
|
||||
'encrypt' => true,
|
||||
],
|
||||
|
||||
'redis' => [
|
||||
'driver' => 'redis',
|
||||
'connection' => 'default',
|
||||
'queue' => 'default',
|
||||
'expire' => 60,
|
||||
],
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Failed Queue Jobs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These options configure the behavior of failed queue job logging so you
|
||||
| can control which database and table are used to store the jobs that
|
||||
| have failed. You may change them to any database / table you wish.
|
||||
|
|
||||
*/
|
||||
|
||||
'failed' => [
|
||||
'database' => 'mysql', 'table' => 'failed_jobs',
|
||||
],
|
||||
|
||||
];
|
@ -1,38 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Third Party Services
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This file is for storing the credentials for third party services such
|
||||
| as Stripe, Mailgun, Mandrill, and others. This file provides a sane
|
||||
| default location for this type of information, allowing packages
|
||||
| to have a conventional place to find your various credentials.
|
||||
|
|
||||
*/
|
||||
|
||||
'mailgun' => [
|
||||
'domain' => '',
|
||||
'secret' => '',
|
||||
],
|
||||
|
||||
'mandrill' => [
|
||||
'secret' => '',
|
||||
],
|
||||
|
||||
'ses' => [
|
||||
'key' => '',
|
||||
'secret' => '',
|
||||
'region' => 'us-east-1',
|
||||
],
|
||||
|
||||
'stripe' => [
|
||||
'model' => App\User::class,
|
||||
'key' => '',
|
||||
'secret' => '',
|
||||
],
|
||||
|
||||
];
|
@ -1,153 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Session Driver
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option controls the default session "driver" that will be used on
|
||||
| requests. By default, we will use the lightweight native driver but
|
||||
| you may specify any of the other wonderful drivers provided here.
|
||||
|
|
||||
| Supported: "file", "cookie", "database", "apc",
|
||||
| "memcached", "redis", "array"
|
||||
|
|
||||
*/
|
||||
|
||||
'driver' => env('SESSION_DRIVER', 'file'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Lifetime
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify the number of minutes that you wish the session
|
||||
| to be allowed to remain idle before it expires. If you want them
|
||||
| to immediately expire on the browser closing, set that option.
|
||||
|
|
||||
*/
|
||||
|
||||
'lifetime' => 120,
|
||||
|
||||
'expire_on_close' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Encryption
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option allows you to easily specify that all of your session data
|
||||
| should be encrypted before it is stored. All encryption will be run
|
||||
| automatically by Laravel and you can use the Session like normal.
|
||||
|
|
||||
*/
|
||||
|
||||
'encrypt' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session File Location
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the native session driver, we need a location where session
|
||||
| files may be stored. A default has been set for you but a different
|
||||
| location may be specified. This is only needed for file sessions.
|
||||
|
|
||||
*/
|
||||
|
||||
'files' => storage_path('framework/sessions'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Database Connection
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the "database" or "redis" session drivers, you may specify a
|
||||
| connection that should be used to manage these sessions. This should
|
||||
| correspond to a connection in your database configuration options.
|
||||
|
|
||||
*/
|
||||
|
||||
'connection' => null,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Database Table
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When using the "database" session driver, you may specify the table we
|
||||
| should use to manage the sessions. Of course, a sensible default is
|
||||
| provided for you; however, you are free to change this as needed.
|
||||
|
|
||||
*/
|
||||
|
||||
'table' => 'sessions',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Sweeping Lottery
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Some session drivers must manually sweep their storage location to get
|
||||
| rid of old sessions from storage. Here are the chances that it will
|
||||
| happen on a given request. By default, the odds are 2 out of 100.
|
||||
|
|
||||
*/
|
||||
|
||||
'lottery' => [2, 100],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Cookie Name
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may change the name of the cookie used to identify a session
|
||||
| instance by ID. The name specified here will get used every time a
|
||||
| new session cookie is created by the framework for every driver.
|
||||
|
|
||||
*/
|
||||
|
||||
'cookie' => 'laravel_session',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Cookie Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The session cookie path determines the path for which the cookie will
|
||||
| be regarded as available. Typically, this will be the root path of
|
||||
| your application but you are free to change this when necessary.
|
||||
|
|
||||
*/
|
||||
|
||||
'path' => '/',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Cookie Domain
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may change the domain of the cookie used to identify a session
|
||||
| in your application. This will determine which domains the cookie is
|
||||
| available to in your application. A sensible default has been set.
|
||||
|
|
||||
*/
|
||||
|
||||
'domain' => null,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| HTTPS Only Cookies
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By setting this option to true, session cookies will only be sent back
|
||||
| to the server if the browser has a HTTPS connection. This will keep
|
||||
| the cookie from being sent to you if it can not be done securely.
|
||||
|
|
||||
*/
|
||||
|
||||
'secure' => false,
|
||||
|
||||
];
|
@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| View Storage Paths
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Most templating systems load templates from disk. Here you may specify
|
||||
| an array of paths that should be checked for your views. Of course
|
||||
| the usual Laravel view path has already been registered for you.
|
||||
|
|
||||
*/
|
||||
|
||||
'paths' => [
|
||||
realpath(base_path('resources/views')),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Compiled View Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option determines where all the compiled Blade templates will be
|
||||
| stored for your application. Typically, this is within the storage
|
||||
| directory. However, as usual, you are free to change this value.
|
||||
|
|
||||
*/
|
||||
|
||||
'compiled' => realpath(storage_path('framework/views')),
|
||||
|
||||
];
|
1
laravel/database/.gitignore
vendored
1
laravel/database/.gitignore
vendored
@ -1 +0,0 @@
|
||||
*.sqlite
|
@ -1,21 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model Factories
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define all of your model factories. Model factories give
|
||||
| you a convenient way to create models for testing and seeding your
|
||||
| database. Just tell the factory how a default model should look.
|
||||
|
|
||||
*/
|
||||
|
||||
$factory->define(App\User::class, function ($faker) {
|
||||
return [
|
||||
'name' => $faker->name,
|
||||
'email' => $faker->email,
|
||||
'password' => str_random(10),
|
||||
'remember_token' => str_random(10),
|
||||
];
|
||||
});
|
@ -1,34 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateUsersTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('users', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name');
|
||||
$table->string('email')->unique();
|
||||
$table->string('password', 60);
|
||||
$table->rememberToken();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::drop('users');
|
||||
}
|
||||
}
|
@ -1,31 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePasswordResetsTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('password_resets', function (Blueprint $table) {
|
||||
$table->string('email')->index();
|
||||
$table->string('token')->index();
|
||||
$table->timestamp('created_at');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::drop('password_resets');
|
||||
}
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Seeder;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class DatabaseSeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
* Run the database seeds.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
Model::unguard();
|
||||
|
||||
// $this->call(UserTableSeeder::class);
|
||||
|
||||
Model::reguard();
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
var elixir = require('laravel-elixir');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Elixir Asset Management
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Elixir provides a clean, fluent API for defining some basic Gulp tasks
|
||||
| for your Laravel application. By default, we are compiling the Less
|
||||
| file for our application, as well as publishing vendor resources.
|
||||
|
|
||||
*/
|
||||
|
||||
elixir(function(mix) {
|
||||
mix.sass('app.scss');
|
||||
});
|
@ -1,10 +0,0 @@
|
||||
{
|
||||
"private": true,
|
||||
"devDependencies": {
|
||||
"gulp": "^3.8.8"
|
||||
},
|
||||
"dependencies": {
|
||||
"laravel-elixir": "^2.0.0",
|
||||
"bootstrap-sass": "^3.0.0"
|
||||
}
|
||||
}
|
@ -1,5 +0,0 @@
|
||||
suites:
|
||||
main:
|
||||
namespace: App
|
||||
psr4_prefix: App
|
||||
src_path: app
|
@ -1,28 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<phpunit backupGlobals="false"
|
||||
backupStaticAttributes="false"
|
||||
bootstrap="bootstrap/autoload.php"
|
||||
colors="true"
|
||||
convertErrorsToExceptions="true"
|
||||
convertNoticesToExceptions="true"
|
||||
convertWarningsToExceptions="true"
|
||||
processIsolation="false"
|
||||
stopOnFailure="false"
|
||||
syntaxCheck="false">
|
||||
<testsuites>
|
||||
<testsuite name="Application Test Suite">
|
||||
<directory>./tests/</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<filter>
|
||||
<whitelist>
|
||||
<directory suffix=".php">app/</directory>
|
||||
</whitelist>
|
||||
</filter>
|
||||
<php>
|
||||
<env name="APP_ENV" value="testing"/>
|
||||
<env name="CACHE_DRIVER" value="array"/>
|
||||
<env name="SESSION_DRIVER" value="array"/>
|
||||
<env name="QUEUE_DRIVER" value="sync"/>
|
||||
</php>
|
||||
</phpunit>
|
@ -1,15 +0,0 @@
|
||||
<IfModule mod_rewrite.c>
|
||||
<IfModule mod_negotiation.c>
|
||||
Options -MultiViews
|
||||
</IfModule>
|
||||
|
||||
RewriteEngine On
|
||||
|
||||
# Redirect Trailing Slashes...
|
||||
RewriteRule ^(.*)/$ /$1 [L,R=301]
|
||||
|
||||
# Handle Front Controller...
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule ^ index.php [L]
|
||||
</IfModule>
|
@ -1,58 +0,0 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Laravel - A PHP Framework For Web Artisans
|
||||
*
|
||||
* @package Laravel
|
||||
* @author Taylor Otwell <taylorotwell@gmail.com>
|
||||
*/
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Auto Loader
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Composer provides a convenient, automatically generated class loader for
|
||||
| our application. We just need to utilize it! We'll simply require it
|
||||
| into the script here so that we don't have to worry about manual
|
||||
| loading any of our classes later on. It feels nice to relax.
|
||||
|
|
||||
*/
|
||||
|
||||
require __DIR__.'/../bootstrap/autoload.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Turn On The Lights
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| We need to illuminate PHP development, so let us turn on the lights.
|
||||
| This bootstraps the framework and gets it ready for use, then it
|
||||
| will load up this application so that we can run it and send
|
||||
| the responses back to the browser and delight our users.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = require_once __DIR__.'/../bootstrap/app.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Once we have the application, we can handle the incoming request
|
||||
| through the kernel, and send the associated response back to
|
||||
| the client's browser allowing them to enjoy the creative
|
||||
| and wonderful application we have prepared for them.
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
|
||||
|
||||
$response = $kernel->handle(
|
||||
$request = Illuminate\Http\Request::capture()
|
||||
);
|
||||
|
||||
$response->send();
|
||||
|
||||
$kernel->terminate($request, $response);
|
@ -1,2 +0,0 @@
|
||||
User-agent: *
|
||||
Disallow:
|
@ -1,2 +0,0 @@
|
||||
// @import "node_modules/bootstrap-sass/assets/stylesheets/bootstrap";
|
||||
|
@ -1,19 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Pagination Language Lines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The following language lines are used by the paginator library to build
|
||||
| the simple pagination links. You are free to change them to anything
|
||||
| you want to customize your views to better match your application.
|
||||
|
|
||||
*/
|
||||
|
||||
'previous' => '« Previous',
|
||||
'next' => 'Next »',
|
||||
|
||||
];
|
@ -1,22 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Password Reminder Language Lines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The following language lines are the default lines which match reasons
|
||||
| that are given by the password broker for a password update attempt
|
||||
| has failed, such as for an invalid token or invalid new password.
|
||||
|
|
||||
*/
|
||||
|
||||
'password' => 'Passwords must be at least six characters and match the confirmation.',
|
||||
'user' => "We can't find a user with that e-mail address.",
|
||||
'token' => 'This password reset token is invalid.',
|
||||
'sent' => 'We have e-mailed your password reset link!',
|
||||
'reset' => 'Your password has been reset!',
|
||||
|
||||
];
|
@ -1,108 +0,0 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Validation Language Lines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The following language lines contain the default error messages used by
|
||||
| the validator class. Some of these rules have multiple versions such
|
||||
| as the size rules. Feel free to tweak each of these messages here.
|
||||
|
|
||||
*/
|
||||
|
||||
'accepted' => 'The :attribute must be accepted.',
|
||||
'active_url' => 'The :attribute is not a valid URL.',
|
||||
'after' => 'The :attribute must be a date after :date.',
|
||||
'alpha' => 'The :attribute may only contain letters.',
|
||||
'alpha_dash' => 'The :attribute may only contain letters, numbers, and dashes.',
|
||||
'alpha_num' => 'The :attribute may only contain letters and numbers.',
|
||||
'array' => 'The :attribute must be an array.',
|
||||
'before' => 'The :attribute must be a date before :date.',
|
||||
'between' => [
|
||||
'numeric' => 'The :attribute must be between :min and :max.',
|
||||
'file' => 'The :attribute must be between :min and :max kilobytes.',
|
||||
'string' => 'The :attribute must be between :min and :max characters.',
|
||||
'array' => 'The :attribute must have between :min and :max items.',
|
||||
],
|
||||
'boolean' => 'The :attribute field must be true or false.',
|
||||
'confirmed' => 'The :attribute confirmation does not match.',
|
||||
'date' => 'The :attribute is not a valid date.',
|
||||
'date_format' => 'The :attribute does not match the format :format.',
|
||||
'different' => 'The :attribute and :other must be different.',
|
||||
'digits' => 'The :attribute must be :digits digits.',
|
||||
'digits_between' => 'The :attribute must be between :min and :max digits.',
|
||||
'email' => 'The :attribute must be a valid email address.',
|
||||
'filled' => 'The :attribute field is required.',
|
||||
'exists' => 'The selected :attribute is invalid.',
|
||||
'image' => 'The :attribute must be an image.',
|
||||
'in' => 'The selected :attribute is invalid.',
|
||||
'integer' => 'The :attribute must be an integer.',
|
||||
'ip' => 'The :attribute must be a valid IP address.',
|
||||
'max' => [
|
||||
'numeric' => 'The :attribute may not be greater than :max.',
|
||||
'file' => 'The :attribute may not be greater than :max kilobytes.',
|
||||
'string' => 'The :attribute may not be greater than :max characters.',
|
||||
'array' => 'The :attribute may not have more than :max items.',
|
||||
],
|
||||
'mimes' => 'The :attribute must be a file of type: :values.',
|
||||
'min' => [
|
||||
'numeric' => 'The :attribute must be at least :min.',
|
||||
'file' => 'The :attribute must be at least :min kilobytes.',
|
||||
'string' => 'The :attribute must be at least :min characters.',
|
||||
'array' => 'The :attribute must have at least :min items.',
|
||||
],
|
||||
'not_in' => 'The selected :attribute is invalid.',
|
||||
'numeric' => 'The :attribute must be a number.',
|
||||
'regex' => 'The :attribute format is invalid.',
|
||||
'required' => 'The :attribute field is required.',
|
||||
'required_if' => 'The :attribute field is required when :other is :value.',
|
||||
'required_with' => 'The :attribute field is required when :values is present.',
|
||||
'required_with_all' => 'The :attribute field is required when :values is present.',
|
||||
'required_without' => 'The :attribute field is required when :values is not present.',
|
||||
'required_without_all' => 'The :attribute field is required when none of :values are present.',
|
||||
'same' => 'The :attribute and :other must match.',
|
||||
'size' => [
|
||||
'numeric' => 'The :attribute must be :size.',
|
||||
'file' => 'The :attribute must be :size kilobytes.',
|
||||
'string' => 'The :attribute must be :size characters.',
|
||||
'array' => 'The :attribute must contain :size items.',
|
||||
],
|
||||
'string' => 'The :attribute must be a string.',
|
||||
'timezone' => 'The :attribute must be a valid zone.',
|
||||
'unique' => 'The :attribute has already been taken.',
|
||||
'url' => 'The :attribute format is invalid.',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Custom Validation Language Lines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may specify custom validation messages for attributes using the
|
||||
| convention "attribute.rule" to name the lines. This makes it quick to
|
||||
| specify a specific custom language line for a given attribute rule.
|
||||
|
|
||||
*/
|
||||
|
||||
'custom' => [
|
||||
'attribute-name' => [
|
||||
'rule-name' => 'custom-message',
|
||||
],
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Custom Validation Attributes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The following language lines are used to swap attribute place-holders
|
||||
| with something more reader friendly such as E-Mail Address instead
|
||||
| of "email". This simply helps us make messages a little cleaner.
|
||||
|
|
||||
*/
|
||||
|
||||
'attributes' => [],
|
||||
|
||||
];
|
@ -1,47 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Be right back.</title>
|
||||
|
||||
<link href="//fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css">
|
||||
|
||||
<style>
|
||||
html, body {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
width: 100%;
|
||||
color: #B0BEC5;
|
||||
display: table;
|
||||
font-weight: 100;
|
||||
font-family: 'Lato';
|
||||
}
|
||||
|
||||
.container {
|
||||
text-align: center;
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.content {
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 72px;
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="content">
|
||||
<div class="title">Be right back.</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
0
laravel/resources/views/vendor/.gitkeep
vendored
0
laravel/resources/views/vendor/.gitkeep
vendored
@ -1,51 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Laravel</title>
|
||||
|
||||
<link href="//fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css">
|
||||
|
||||
<style>
|
||||
html, body {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
width: 100%;
|
||||
color: #B0BEC5;
|
||||
display: table;
|
||||
font-weight: 100;
|
||||
font-family: 'Lato';
|
||||
}
|
||||
|
||||
.container {
|
||||
text-align: center;
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.content {
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 96px;
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.quote {
|
||||
font-size: 24px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="content">
|
||||
<div class="title">Laravel ♥ Docker</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -1,21 +0,0 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Laravel - A PHP Framework For Web Artisans
|
||||
*
|
||||
* @package Laravel
|
||||
* @author Taylor Otwell <taylorotwell@gmail.com>
|
||||
*/
|
||||
|
||||
$uri = urldecode(
|
||||
parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH)
|
||||
);
|
||||
|
||||
// This file allows us to emulate Apache's "mod_rewrite" functionality from the
|
||||
// built-in PHP web server. This provides a convenient way to test a Laravel
|
||||
// application without having installed a "real" web server software here.
|
||||
if ($uri !== '/' && file_exists(__DIR__.'/public'.$uri)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
require_once __DIR__.'/public/index.php';
|
2
laravel/storage/app/.gitignore
vendored
2
laravel/storage/app/.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
7
laravel/storage/framework/.gitignore
vendored
7
laravel/storage/framework/.gitignore
vendored
@ -1,7 +0,0 @@
|
||||
config.php
|
||||
routes.php
|
||||
compiled.php
|
||||
services.json
|
||||
events.scanned.php
|
||||
routes.scanned.php
|
||||
down
|
2
laravel/storage/framework/cache/.gitignore
vendored
2
laravel/storage/framework/cache/.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
2
laravel/storage/framework/views/.gitignore
vendored
2
laravel/storage/framework/views/.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
2
laravel/storage/logs/.gitignore
vendored
2
laravel/storage/logs/.gitignore
vendored
@ -1,2 +0,0 @@
|
||||
*
|
||||
!.gitignore
|
@ -1,19 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Foundation\Testing\WithoutMiddleware;
|
||||
use Illuminate\Foundation\Testing\DatabaseMigrations;
|
||||
use Illuminate\Foundation\Testing\DatabaseTransactions;
|
||||
|
||||
class ExampleTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* A basic functional test example.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function testBasicExample()
|
||||
{
|
||||
$this->visit('/')
|
||||
->see('Laravel 5');
|
||||
}
|
||||
}
|
@ -1,25 +0,0 @@
|
||||
<?php
|
||||
|
||||
class TestCase extends Illuminate\Foundation\Testing\TestCase
|
||||
{
|
||||
/**
|
||||
* The base URL to use while testing the application.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $baseUrl = 'http://localhost';
|
||||
|
||||
/**
|
||||
* Creates the application.
|
||||
*
|
||||
* @return \Illuminate\Foundation\Application
|
||||
*/
|
||||
public function createApplication()
|
||||
{
|
||||
$app = require __DIR__.'/../bootstrap/app.php';
|
||||
|
||||
$app->make(Illuminate\Contracts\Console\Kernel::class)->bootstrap();
|
||||
|
||||
return $app;
|
||||
}
|
||||
}
|
7
mariadb/Dockerfile
Normal file
7
mariadb/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM mariadb:latest
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
CMD ["mysqld"]
|
||||
|
||||
EXPOSE 3306
|
7
memcached/Dockerfile
Normal file
7
memcached/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM memcached:latest
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
CMD ["memcached"]
|
||||
|
||||
EXPOSE 11211
|
12
mongo/Dockerfile
Normal file
12
mongo/Dockerfile
Normal file
@ -0,0 +1,12 @@
|
||||
FROM mongo:latest
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
#COPY mongo.conf /usr/local/etc/mongo/mongo.conf
|
||||
|
||||
VOLUME /data/db /data/configdb
|
||||
|
||||
CMD ["mongod"]
|
||||
|
||||
EXPOSE 27017
|
||||
|
9
mysql/Dockerfile
Normal file
9
mysql/Dockerfile
Normal file
@ -0,0 +1,9 @@
|
||||
FROM mysql:5.6
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
ADD my.cnf /etc/mysql/conf.d/my.cnf
|
||||
|
||||
CMD ["mysqld"]
|
||||
|
||||
EXPOSE 3306
|
6
mysql/my.cnf
Normal file
6
mysql/my.cnf
Normal file
@ -0,0 +1,6 @@
|
||||
# The MySQL Client configuration file.
|
||||
#
|
||||
# For explanations see
|
||||
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html
|
||||
|
||||
[mysql]
|
7
neo4j/Dockerfile
Normal file
7
neo4j/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM tpires/neo4j
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
VOLUME /var/lib/neo4j/data
|
||||
|
||||
EXPOSE 7474 1337
|
19
nginx/Dockerfile
Normal file
19
nginx/Dockerfile
Normal file
@ -0,0 +1,19 @@
|
||||
FROM nginx:alpine
|
||||
|
||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||
|
||||
ADD nginx.conf /etc/nginx/
|
||||
COPY sites/*.conf /etc/nginx/sites-available/
|
||||
|
||||
ARG PHP_UPSTREAM=php-fpm
|
||||
|
||||
RUN apk update \
|
||||
&& apk upgrade \
|
||||
&& apk add --no-cache bash \
|
||||
&& adduser -D -H -u 1000 -s /bin/bash www-data \
|
||||
&& rm /etc/nginx/conf.d/default.conf \
|
||||
&& echo "upstream php-upstream { server ${PHP_UPSTREAM}:9000; }" > /etc/nginx/conf.d/upstream.conf
|
||||
|
||||
CMD ["nginx"]
|
||||
|
||||
EXPOSE 80 443
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user