Compare commits
13 Commits
Author | SHA1 | Date | |
---|---|---|---|
380178e6fa | |||
be64b54606 | |||
cbeeb48aa1 | |||
7e2814168a | |||
5e9ae56a7f | |||
5d98e78dba | |||
c5d1116333 | |||
5594c53e03 | |||
44045f85e6 | |||
fc31a2415c | |||
a42f62c626 | |||
3e4a5edc64 | |||
9289c1b6c0 |
19
README.md
19
README.md
@ -61,6 +61,7 @@ Laradock is configured to run Laravel Apps by default, and it can be modifyed to
|
|||||||
- [Access workspace via ssh](#Workspace-ssh)
|
- [Access workspace via ssh](#Workspace-ssh)
|
||||||
- [MySQL access from host](#MySQL-access-from-host)
|
- [MySQL access from host](#MySQL-access-from-host)
|
||||||
- [MySQL root access](#MySQL-root-access)
|
- [MySQL root access](#MySQL-root-access)
|
||||||
|
- [Change MySQL port](#Change-MySQL-port)
|
||||||
- [Use custom Domain](#Use-custom-Domain)
|
- [Use custom Domain](#Use-custom-Domain)
|
||||||
- [Enable Global Composer Build Install](#Enable-Global-Composer-Build-Install)
|
- [Enable Global Composer Build Install](#Enable-Global-Composer-Build-Install)
|
||||||
- [Install Prestissimo](#Install-Prestissimo)
|
- [Install Prestissimo](#Install-Prestissimo)
|
||||||
@ -1164,6 +1165,17 @@ The default username and password for the root mysql user are `root` and `root `
|
|||||||
4 - Run any commands `show databases`, `show tables`, `select * from.....`.
|
4 - Run any commands `show databases`, `show tables`, `select * from.....`.
|
||||||
|
|
||||||
|
|
||||||
|
<a name="Change-MySQL-port"></a>
|
||||||
|
### Change MySQL port
|
||||||
|
|
||||||
|
Modify the `mysql/my.cnf` file to set your port number, `1234` is used as an example.
|
||||||
|
|
||||||
|
```
|
||||||
|
[mysqld]
|
||||||
|
port=1234
|
||||||
|
```
|
||||||
|
|
||||||
|
If you need <a href="#MySQL-access-from-host">MySQL access from your host</a>, do not forget to change the internal port number (`"3306:3306"` -> `"3306:1234"`) in the docker-compose config file.
|
||||||
|
|
||||||
<a name="Use-custom-Domain"></a>
|
<a name="Use-custom-Domain"></a>
|
||||||
### Use custom Domain (instead of the Docker IP)
|
### Use custom Domain (instead of the Docker IP)
|
||||||
@ -1357,8 +1369,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`
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -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:
|
||||||
@ -267,8 +280,6 @@ services:
|
|||||||
MYSQL_USER: homestead
|
MYSQL_USER: homestead
|
||||||
MYSQL_PASSWORD: secret
|
MYSQL_PASSWORD: secret
|
||||||
MYSQL_ROOT_PASSWORD: root
|
MYSQL_ROOT_PASSWORD: root
|
||||||
volumes:
|
|
||||||
- phpmyadmin
|
|
||||||
ports:
|
ports:
|
||||||
- "8080:80"
|
- "8080:80"
|
||||||
links:
|
links:
|
||||||
|
5
postgres-postgis/Dockerfile
Normal file
5
postgres-postgis/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
FROM mdillon/postgis:latest
|
||||||
|
|
||||||
|
CMD ["postgres"]
|
||||||
|
|
||||||
|
EXPOSE 5432
|
@ -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