Compare commits
14 Commits
Author | SHA1 | Date | |
---|---|---|---|
5e9ae56a7f | |||
5d98e78dba | |||
c5d1116333 | |||
5594c53e03 | |||
44045f85e6 | |||
fc31a2415c | |||
a42f62c626 | |||
3e4a5edc64 | |||
9289c1b6c0 | |||
3f157a3277 | |||
f732bb283b | |||
ca4aeada08 | |||
3d54d68aa1 | |||
a0153810c6 |
@ -7,9 +7,7 @@
|
|||||||
LaraDock能够帮你在**Docker**上快速搭建**Laravel**应用。
|
LaraDock能够帮你在**Docker**上快速搭建**Laravel**应用。
|
||||||
<br>
|
<br>
|
||||||
就像Laravel Homestead一样,但是Docker替换了Vagrant。
|
就像Laravel Homestead一样,但是Docker替换了Vagrant。
|
||||||
>先在Docker上使用LaraDock,然后再学习它们。
|
> 先在使用 LaraDock,然后再学习它们。
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
## 目录
|
## 目录
|
||||||
|
15
README.md
15
README.md
@ -287,7 +287,13 @@ git clone https://github.com/LaraDock/laradock.git
|
|||||||
```
|
```
|
||||||
Do the same for each project `project2.conf`, `project3.conf`,...
|
Do the same for each project `project2.conf`, `project3.conf`,...
|
||||||
|
|
||||||
6 - Create your project Databases **To Be Continue..**
|
6 - Add the domains to the **hosts** files.
|
||||||
|
|
||||||
|
```
|
||||||
|
127.0.0.1 project1.dev
|
||||||
|
```
|
||||||
|
|
||||||
|
7 - Create your project Databases. Right now you have to do it manually by entering your DB container, until we automate it soon.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -1351,8 +1357,11 @@ Make sure the ports for the services that you are trying to run (80, 3306, etc.)
|
|||||||
|
|
||||||
This error is sometimes happens because your Laravel application isn't running on the container localhost IP (Which is 127.0.0.1). Steps to fix it:
|
This error is sometimes happens because your Laravel application isn't running on the container localhost IP (Which is 127.0.0.1). Steps to fix it:
|
||||||
|
|
||||||
1. Check your running Laravel application IP by dumping `Request::ip()` variable using `dd(Request::ip())` anywhere on your application. The result is the IP of your Laravel container.
|
* Option A
|
||||||
2. Change the `DB_HOST` variable on env with the IP that you received from previous step.
|
1. Check your running Laravel application IP by dumping `Request::ip()` variable using `dd(Request::ip())` anywhere on your application. The result is the IP of your Laravel container.
|
||||||
|
2. Change the `DB_HOST` variable on env with the IP that you received from previous step.
|
||||||
|
* Option B
|
||||||
|
1. Change the `DB_HOST` value to the same name as the mysql docker container. The Laradock docker-compose file currently has this as `mysql`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -128,7 +128,7 @@ services:
|
|||||||
mariadb:
|
mariadb:
|
||||||
build: ./mariadb
|
build: ./mariadb
|
||||||
volumes:
|
volumes:
|
||||||
- mariadb
|
- mysql:/var/lib/mysql
|
||||||
ports:
|
ports:
|
||||||
- "3306:3306"
|
- "3306:3306"
|
||||||
environment:
|
environment:
|
||||||
@ -150,6 +150,19 @@ services:
|
|||||||
POSTGRES_USER: homestead
|
POSTGRES_USER: homestead
|
||||||
POSTGRES_PASSWORD: secret
|
POSTGRES_PASSWORD: secret
|
||||||
|
|
||||||
|
### PostgreSQL PostGis Container ############################
|
||||||
|
|
||||||
|
postgres-postgis:
|
||||||
|
build: ./postgres-postgis
|
||||||
|
volumes:
|
||||||
|
- postgres:/var/lib/postgresql/data
|
||||||
|
ports:
|
||||||
|
- "5432:5432"
|
||||||
|
environment:
|
||||||
|
POSTGRES_DB: homestead
|
||||||
|
POSTGRES_USER: homestead
|
||||||
|
POSTGRES_PASSWORD: secret
|
||||||
|
|
||||||
### Neo4j Container #########################################
|
### Neo4j Container #########################################
|
||||||
|
|
||||||
neo4j:
|
neo4j:
|
||||||
|
5
postgres-postgis/Dockerfile
Normal file
5
postgres-postgis/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
FROM mdillon/postgis:latest
|
||||||
|
|
||||||
|
CMD ["postgres"]
|
||||||
|
|
||||||
|
EXPOSE 5432
|
@ -10,7 +10,7 @@
|
|||||||
# https://hub.docker.com/r/laradock/workspace/tags/
|
# https://hub.docker.com/r/laradock/workspace/tags/
|
||||||
#
|
#
|
||||||
|
|
||||||
FROM laradock/workspace:1.1
|
FROM laradock/workspace:1.2
|
||||||
|
|
||||||
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
|
||||||
|
|
||||||
@ -191,6 +191,7 @@ ARG INSTALL_YARN=false
|
|||||||
ENV INSTALL_YARN ${INSTALL_YARN}
|
ENV INSTALL_YARN ${INSTALL_YARN}
|
||||||
|
|
||||||
RUN if [ ${INSTALL_YARN} = true ]; then \
|
RUN if [ ${INSTALL_YARN} = true ]; then \
|
||||||
|
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" && \
|
||||||
curl -o- -L https://yarnpkg.com/install.sh | bash && \
|
curl -o- -L https://yarnpkg.com/install.sh | bash && \
|
||||||
echo "" >> ~/.bashrc && \
|
echo "" >> ~/.bashrc && \
|
||||||
echo 'export PATH="$HOME/.yarn/bin:$PATH"' >> ~/.bashrc \
|
echo 'export PATH="$HOME/.yarn/bin:$PATH"' >> ~/.bashrc \
|
||||||
|
Reference in New Issue
Block a user