Compare commits
110 Commits
Author | SHA1 | Date | |
---|---|---|---|
63fc1fde44 | |||
623ff66f40 | |||
5bf8be6303 | |||
c0a36a5a4d | |||
c0b28fc404 | |||
9e537ee16b | |||
fbae49b898 | |||
bc8772441b | |||
dba1594b05 | |||
2dd64aef55 | |||
23193babf4 | |||
fbdfc41927 | |||
7ea44ca25a | |||
76b71d264d | |||
c7289f7db3 | |||
e8d84cf9a3 | |||
4417083a80 | |||
0980523049 | |||
d8b3cb5a52 | |||
d34602ae29 | |||
cbbdb0a86b | |||
f5c80cd251 | |||
5b07fbb9c4 | |||
83a24efa70 | |||
a03c225e27 | |||
95965b12e7 | |||
58d7d4fa0b | |||
1f22e86d92 | |||
c8b526be13 | |||
b1cbd48221 | |||
d1f3bc8e5c | |||
9920397463 | |||
6f4664c579 | |||
254a9ae194 | |||
8ca26e6c06 | |||
6c8adbc195 | |||
329462a637 | |||
e105ec9569 | |||
76218808fd | |||
f18eb9728b | |||
d404555cf5 | |||
d964e2898c | |||
2d7b780e56 | |||
cf6a9ba2c9 | |||
8f6923531f | |||
61d7b18922 | |||
cde20c3ced | |||
f7dff0f72f | |||
1ec9244f7f | |||
176d4e8033 | |||
2deb9bf1cb | |||
b0edaf93a1 | |||
27af2bca8c | |||
61ac73e806 | |||
14ee775e39 | |||
1282c413fd | |||
ee2db98c61 | |||
739e8d3448 | |||
1286b7ef06 | |||
e0d7229e95 | |||
931f99ed0f | |||
fc3355a9cc | |||
53ca88714c | |||
1d420a2507 | |||
c7aa535598 | |||
5edf3f398b | |||
f6c5aa1801 | |||
a09144f02b | |||
9e4dfa2a0c | |||
99f7e65c99 | |||
e0dc683d3f | |||
eb0c941313 | |||
d27f4368ee | |||
7430a34dd5 | |||
d5647295ca | |||
b1e346383b | |||
913abc54f9 | |||
53e8229313 | |||
36c78369d5 | |||
acac6eb229 | |||
04f071555c | |||
03ff791e17 | |||
7c4f6dd7a9 | |||
f44a8e0ca0 | |||
ce7a29c662 | |||
bbff18c631 | |||
e07c128063 | |||
163eb1f73a | |||
30c8afafa2 | |||
3e771dbcfc | |||
a1bda23cd9 | |||
e6d866b8a6 | |||
35ffd02b44 | |||
d03ead34a2 | |||
d8c36ab860 | |||
2689638d7d | |||
fa7d3c239c | |||
22032974c9 | |||
4480962922 | |||
cc81e57206 | |||
5c41a4f3e9 | |||
796b46cf5a | |||
d7765a7b10 | |||
156d124db0 | |||
afdf2661bd | |||
a1af01b137 | |||
1519c80036 | |||
441146b325 | |||
0ed5487ed7 | |||
ca9d244396 |
2
.github/README.md
vendored
2
.github/README.md
vendored
@ -16,7 +16,7 @@
|
||||
<h4 align="center" style="color:#7d58c2">Use Docker First And Learn About It Later</h4>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://zalt.me"><img src="http://forthebadge.com/images/badges/built-by-developers.svg" alt="forthebadge" width="240" ></a>
|
||||
<a href="http://zalt.me"><img src="http://forthebadge.com/images/badges/built-by-developers.svg" alt="forthebadge" width="240" ></a>
|
||||
</p>
|
||||
|
||||
|
||||
|
9
.gitignore
vendored
9
.gitignore
vendored
@ -5,3 +5,12 @@
|
||||
/.project
|
||||
.docker-sync
|
||||
/jenkins/jenkins_home
|
||||
|
||||
/logstash/pipeline/*.conf
|
||||
/logstash/config/pipelines.yml
|
||||
|
||||
/nginx/ssl/*.crt
|
||||
/nginx/ssl/*.key
|
||||
/nginx/ssl/*.csr
|
||||
|
||||
.DS_Store
|
@ -11,11 +11,13 @@ env:
|
||||
- PHP_VERSION=7.0 BUILD_SERVICE=workspace
|
||||
- PHP_VERSION=7.1 BUILD_SERVICE=workspace
|
||||
- PHP_VERSION=7.2 BUILD_SERVICE=workspace
|
||||
- PHP_VERSION=7.3 BUILD_SERVICE=workspace
|
||||
|
||||
- PHP_VERSION=5.6 BUILD_SERVICE=php-fpm
|
||||
- PHP_VERSION=7.0 BUILD_SERVICE=php-fpm
|
||||
- PHP_VERSION=7.1 BUILD_SERVICE=php-fpm
|
||||
- PHP_VERSION=7.2 BUILD_SERVICE=php-fpm
|
||||
- PHP_VERSION=7.3 BUILD_SERVICE=php-fpm
|
||||
|
||||
- PHP_VERSION=hhvm BUILD_SERVICE=hhvm
|
||||
|
||||
@ -23,6 +25,7 @@ env:
|
||||
- PHP_VERSION=7.0 BUILD_SERVICE=php-worker
|
||||
- PHP_VERSION=7.1 BUILD_SERVICE=php-worker
|
||||
- PHP_VERSION=7.2 BUILD_SERVICE=php-worker
|
||||
- PHP_VERSION=7.3 BUILD_SERVICE=php-worker
|
||||
|
||||
- PHP_VERSION=NA BUILD_SERVICE=solr
|
||||
- PHP_VERSION=NA BUILD_SERVICE="mssql rethinkdb aerospike"
|
||||
@ -30,6 +33,7 @@ env:
|
||||
- PHP_VERSION=NA BUILD_SERVICE="adminer phpmyadmin pgadmin"
|
||||
- PHP_VERSION=NA BUILD_SERVICE="memcached beanstalkd beanstalkd-console rabbitmq elasticsearch certbot mailhog maildev selenium jenkins proxy proxy2 haproxy"
|
||||
- PHP_VERSION=NA BUILD_SERVICE="kibana grafana laravel-echo-server"
|
||||
- PHP_VERSION=NA BUILD_SERVICE="ipython-controller manticore"
|
||||
# - PHP_VERSION=NA BUILD_SERVICE="aws"
|
||||
|
||||
# Installing a newer Docker version
|
||||
|
@ -394,6 +394,37 @@ Always download the latest version of [Loaders for ionCube ](http://www.ioncube.
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-SonarQube"></a>
|
||||
|
||||
## Install SonarQube (automatic code review tool)
|
||||
SonarQube® is an automatic code review tool to detect bugs, vulnerabilities and code smells in your code. It can integrate with your existing workflow to enable continuous code inspection across your project branches and pull requests.
|
||||
<br>
|
||||
1 - Open the `.env` file
|
||||
<br>
|
||||
2 - Search for the `SONARQUBE_HOSTNAME=sonar.example.com` argument
|
||||
<br>
|
||||
3 - Set it to your-domain `sonar.example.com`
|
||||
<br>
|
||||
4 - `docker-compose up -d sonarqube`
|
||||
<br>
|
||||
5 - Open your browser: http://localhost:9000/
|
||||
|
||||
Troubleshooting:
|
||||
|
||||
if you encounter a database error:
|
||||
```
|
||||
docker-compose exec --user=root postgres
|
||||
source docker-entrypoint-initdb.d/init_sonarqube_db.sh
|
||||
```
|
||||
|
||||
If you encounter logs error:
|
||||
```
|
||||
docker-compose run --user=root --rm sonarqube chown sonarqube:sonarqube /opt/sonarqube/logs
|
||||
```
|
||||
[**SonarQube Documentation Here**](https://docs.sonarqube.org/latest/)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -409,7 +440,9 @@ Always download the latest version of [Loaders for ionCube ](http://www.ioncube.
|
||||
<a name="Laradock-for-Production"></a>
|
||||
## Prepare Laradock for Production
|
||||
|
||||
It's recommended for production to create a custom `docker-compose.yml` file. For that reason, Laradock is shipped with `production-docker-compose.yml` which should contain only the containers you are planning to run on production (usage example: `docker-compose -f production-docker-compose.yml up -d nginx mysql redis ...`).
|
||||
It's recommended for production to create a custom `docker-compose.yml` file, for example `production-docker-compose.yml`
|
||||
|
||||
In your new production `docker-compose.yml` file you should contain only the containers you are planning to run in production (usage example: `docker-compose -f production-docker-compose.yml up -d nginx mysql redis ...`).
|
||||
|
||||
Note: The Database (MySQL/MariaDB/...) ports should not be forwarded on production, because Docker will automatically publish the port on the host, which is quite insecure, unless specifically told not to. So make sure to remove these lines:
|
||||
|
||||
@ -508,7 +541,7 @@ docker-compose ps
|
||||
docker-compose exec workspace bash
|
||||
```
|
||||
|
||||
Add `--user=laradock` (example `docker-compose exec --user=laradock workspace bash`) to have files created as your host's user.
|
||||
Note: Should add `--user=laradock` (example `docker-compose exec --user=laradock workspace bash`) to have files created as your host's user to prevent issue owner of log file will be changed to root then laravel website cannot write on log file if using rotated log and new log file not existed
|
||||
|
||||
|
||||
4 - Run anything you want :)
|
||||
@ -532,29 +565,8 @@ phpunit
|
||||
<a name="Run-Laravel-Queue-Worker"></a>
|
||||
## Run Laravel Queue Worker
|
||||
|
||||
1 - First add `php-worker` container. It will be similar as like PHP-FPM Container.
|
||||
<br>
|
||||
a) open the `docker-compose.yml` file
|
||||
<br>
|
||||
b) add a new service container by simply copy-paste this section below PHP-FPM container
|
||||
1 - Create supervisor configuration file (for ex., named `laravel-worker.conf`) for Laravel Queue Worker in `php-worker/supervisord.d/` by simply copy from `laravel-worker.conf.example`
|
||||
|
||||
```yaml
|
||||
php-worker:
|
||||
build:
|
||||
context: ./php-worker
|
||||
args:
|
||||
- INSTALL_PGSQL=${PHP_WORKER_INSTALL_PGSQL} #Optionally install PGSQL PHP drivers
|
||||
- INSTALL_BCMATH=${PHP_WORKER_INSTALL_BCMATH} #Optionally install BCMath php package
|
||||
- INSTALL_SOAP=${PHP_WORKER_INSTALL_SOAP} #Optionally install Soap php package
|
||||
volumes_from:
|
||||
- applications
|
||||
depends_on:
|
||||
- workspace
|
||||
extra_hosts:
|
||||
- "dockerhost:${DOCKER_HOST_IP}"
|
||||
networks:
|
||||
- backend
|
||||
```
|
||||
2 - Start everything up
|
||||
|
||||
```bash
|
||||
@ -566,6 +578,34 @@ docker-compose up -d php-worker
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Run-Laravel-Scheduler"></a>
|
||||
## Run Laravel Scheduler
|
||||
|
||||
Laradock provides 2 ways to run Laravel Scheduler
|
||||
1 - Using cron in workspace container. Most of the time, when you start Laradock, it'll automatically start workspace container with cron inside, along with setting to run `schedule:run` command every minute.
|
||||
|
||||
2 - Using Supervisord in php-worker to run `schedule:run`. This way is suggested when you don't want to start workspace in production environment.
|
||||
<br>
|
||||
a) Comment out cron setting in workspace container, file `workspace/crontab/laradock`
|
||||
|
||||
```bash
|
||||
# * * * * * laradock /usr/bin/php /var/www/artisan schedule:run >> /dev/null 2>&1
|
||||
```
|
||||
<br>
|
||||
b) Create supervisor configuration file (for ex., named `laravel-scheduler.conf`) for Laravel Scheduler in `php-worker/supervisord.d/` by simply copy from `laravel-scheduler.conf.example`
|
||||
<br>
|
||||
c) Start php-worker container
|
||||
|
||||
```bash
|
||||
docker-compose up -d php-worker
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Mailu"></a>
|
||||
## Use Mailu
|
||||
@ -624,12 +664,12 @@ docker-compose up -d metabase
|
||||
|
||||
1) Boot the container `docker-compose up -d jenkins`. To enter the container type `docker-compose exec jenkins bash`.
|
||||
|
||||
2) Go to `http://localhost:8090/` (if you didn't chanhed your default port mapping)
|
||||
2) Go to `http://localhost:8090/` (if you didn't chanhed your default port mapping)
|
||||
|
||||
3) Authenticate from the web app.
|
||||
|
||||
- Default username is `admin`.
|
||||
- Default password is `docker-compose exec jenkins cat /var/jenkins_home/secrets/initialAdminPassword`.
|
||||
- Default password is `docker-compose exec jenkins cat /var/jenkins_home/secrets/initialAdminPassword`.
|
||||
|
||||
(To enter container as root type `docker-compose exec --user root jenkins bash`).
|
||||
|
||||
@ -701,6 +741,44 @@ composer require predis/predis:^1.0
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Redis-Cluster"></a>
|
||||
## Use Redis Cluster
|
||||
|
||||
1 - First make sure you run the Redis-Cluster Container (`redis-cluster`) with the `docker-compose up` command.
|
||||
|
||||
```bash
|
||||
docker-compose up -d redis-cluster
|
||||
```
|
||||
|
||||
2 - Open your Laravel's `config/database.php` and set the redis cluster configuration. Below is example configuration with phpredis.
|
||||
|
||||
Read the [Laravel official documentation](https://laravel.com/docs/5.7/redis#configuration) for more details.
|
||||
|
||||
```php
|
||||
'redis' => [
|
||||
'client' => 'phpredis',
|
||||
'options' => [
|
||||
'cluster' => 'redis',
|
||||
],
|
||||
'clusters' => [
|
||||
'default' => [
|
||||
[
|
||||
'host' => 'redis-cluster',
|
||||
'password' => null,
|
||||
'port' => 7000,
|
||||
'database' => 0,
|
||||
],
|
||||
],
|
||||
],
|
||||
],
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Mongo"></a>
|
||||
## Use Mongo
|
||||
@ -817,6 +895,67 @@ docker-compose up -d gitlab
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Gitlab-Runner"></a>
|
||||
## Use Gitlab Runner
|
||||
|
||||
1 - Retrieve the registration token in your gitlab project (Settings > CI / CD > Runners > Set up a specific Runner manually)
|
||||
|
||||
2 - Open the `.env` file and set the following changes:
|
||||
```
|
||||
# so that gitlab container will pass the correct domain to gitlab-runner container
|
||||
GITLAB_DOMAIN_NAME=http://gitlab
|
||||
|
||||
GITLAB_RUNNER_REGISTRATION_TOKEN=<value-in-step-1>
|
||||
|
||||
# so that gitlab-runner container will send POST request for registration to correct domain
|
||||
GITLAB_CI_SERVER_URL=http://gitlab
|
||||
```
|
||||
|
||||
3 - Open the `docker-compose.yml` file and add the following changes:
|
||||
```yml
|
||||
gitlab-runner:
|
||||
environment: # these values will be used during `gitlab-runner register`
|
||||
- RUNNER_EXECUTOR=docker # change from shell (default)
|
||||
- DOCKER_IMAGE=alpine
|
||||
- DOCKER_NETWORK_MODE=laradock_backend
|
||||
networks:
|
||||
- backend # connect to network where gitlab service is connected
|
||||
```
|
||||
|
||||
4 - Run the Gitlab-Runner Container (`gitlab-runner`) with the `docker-compose up` command. Example:
|
||||
|
||||
```bash
|
||||
docker-compose up -d gitlab-runner
|
||||
```
|
||||
|
||||
5 - Register the gitlab-runner to the gitlab container
|
||||
|
||||
```bash
|
||||
docker-compose exec gitlab-runner bash
|
||||
gitlab-runner register
|
||||
```
|
||||
|
||||
6 - Create a `.gitlab-ci.yml` file for your pipeline
|
||||
|
||||
```yml
|
||||
before_script:
|
||||
- echo Hello!
|
||||
|
||||
job1:
|
||||
scripts:
|
||||
- echo job1
|
||||
```
|
||||
|
||||
7 - Push changes to gitlab
|
||||
|
||||
8 - Verify that pipeline is run successful
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Adminer"></a>
|
||||
## Use Adminer
|
||||
@ -866,6 +1005,12 @@ docker-compose up -d postgres pgadmin
|
||||
2 - Open your browser and visit the localhost on port **5050**: `http://localhost:5050`
|
||||
|
||||
|
||||
3 - At login page use default credentials:
|
||||
|
||||
Username : pgadmin4@pgadmin.org
|
||||
|
||||
Password : admin
|
||||
|
||||
|
||||
|
||||
|
||||
@ -1005,8 +1150,9 @@ docker-compose up -d rethinkdb
|
||||
- set the `DB_DATABASE` to `database`.
|
||||
|
||||
|
||||
#### Additional Notes
|
||||
|
||||
|
||||
- You may do backing up of your data using the next reference: [backing up your data](https://www.rethinkdb.com/docs/backup/).
|
||||
|
||||
|
||||
<br>
|
||||
@ -1108,6 +1254,110 @@ docker-compose up -d grafana
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Traefik"></a>
|
||||
## Use Traefik
|
||||
|
||||
To use Traefik you need to do some changes in `traefik/trafik.toml` and `docker-compose.yml`.
|
||||
|
||||
1 - Open `traefik.toml` and change the `e-mail` property in `acme` section.
|
||||
|
||||
2 - Change your domain in `acme.domains`. For example: `main = "example.org"`
|
||||
|
||||
2.1 - If you have subdomains, you must add them to `sans` property in `acme.domains` section.
|
||||
|
||||
```bash
|
||||
[[acme.domais]]
|
||||
main = "example.org"
|
||||
sans = ["monitor.example.org", "pma.example.org"]
|
||||
```
|
||||
|
||||
3 - If you need to add basic authentication (https://docs.traefik.io/configuration/entrypoints/#basic-authentication), you just need to add the following text after `[entryPoints.https.tls]`:
|
||||
|
||||
```bash
|
||||
[entryPoints.https.auth.basic]
|
||||
users = ["user:password"]
|
||||
```
|
||||
|
||||
4 - You need to change the `docker-compose.yml` file to match the Traefik needs. If you want to use Traefik, you must not expose the ports of each container to the internet, but specify some labels.
|
||||
|
||||
4.1 For example, let's try with NGINX. You must have:
|
||||
|
||||
```bash
|
||||
nginx:
|
||||
build:
|
||||
context: ./nginx
|
||||
args:
|
||||
- PHP_UPSTREAM_CONTAINER=${NGINX_PHP_UPSTREAM_CONTAINER}
|
||||
- PHP_UPSTREAM_PORT=${NGINX_PHP_UPSTREAM_PORT}
|
||||
- CHANGE_SOURCE=${CHANGE_SOURCE}
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${NGINX_HOST_LOG_PATH}:/var/log/nginx
|
||||
- ${NGINX_SITES_PATH}:/etc/nginx/sites-available
|
||||
depends_on:
|
||||
- php-fpm
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
labels:
|
||||
- traefik.backend=nginx
|
||||
- traefik.frontend.rule=Host:example.org
|
||||
- traefik.port=80
|
||||
```
|
||||
|
||||
instead of
|
||||
|
||||
```bash
|
||||
nginx:
|
||||
build:
|
||||
context: ./nginx
|
||||
args:
|
||||
- PHP_UPSTREAM_CONTAINER=${NGINX_PHP_UPSTREAM_CONTAINER}
|
||||
- PHP_UPSTREAM_PORT=${NGINX_PHP_UPSTREAM_PORT}
|
||||
- CHANGE_SOURCE=${CHANGE_SOURCE}
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${NGINX_HOST_LOG_PATH}:/var/log/nginx
|
||||
- ${NGINX_SITES_PATH}:/etc/nginx/sites-available
|
||||
- ${NGINX_SSL_PATH}:/etc/nginx/ssl
|
||||
ports:
|
||||
- "${NGINX_HOST_HTTP_PORT}:80"
|
||||
- "${NGINX_HOST_HTTPS_PORT}:443"
|
||||
depends_on:
|
||||
- php-fpm
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Use-Mosquitto"></a>
|
||||
## Use Mosquitto (MQTT Broker)
|
||||
|
||||
1 - Configure Mosquitto: Change Port using `MOSQUITTO_PORT` if you wish to. Default is port 9001.
|
||||
|
||||
2 - Run the Mosquitto Container (`mosquitto`) with the `docker-compose up`command:
|
||||
|
||||
```bash
|
||||
docker-compose up -d mosquitto
|
||||
```
|
||||
|
||||
3 - Open your command line and use a MQTT Client (Eg. https://github.com/mqttjs/MQTT.js) to subscribe a topic and publish a message.
|
||||
|
||||
4 - Subscribe: `mqtt sub -t 'test' -h localhost -p 9001 -C 'ws' -v`
|
||||
|
||||
5 - Publish: `mqtt pub -t 'test' -h localhost -p 9001 -C 'ws' -m 'Hello!'`
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="CodeIgniter"></a>
|
||||
|
||||
@ -1133,6 +1383,21 @@ To install CodeIgniter 3 on Laradock all you have to do is the following simple
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Powerline"></a>
|
||||
## Install Powerline
|
||||
|
||||
1 - Open the `.env` file and set `WORKSPACE_INSTALL_POWERLINE` and `WORKSPACE_INSTALL_PYTHON` to `true`.
|
||||
|
||||
2 - Run `docker-compose build workspace`, after the step above.
|
||||
|
||||
Powerline is required python
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Symfony"></a>
|
||||
## Install Symfony
|
||||
@ -1182,6 +1447,19 @@ We also recommend [setting the timezone in Laravel](http://www.camroncade.com/ma
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Add locales to PHP-FPM"></a>
|
||||
## Add locales to PHP-FPM
|
||||
|
||||
To add locales to the container:
|
||||
|
||||
1 - Open the `.env` file and set `PHP_FPM_INSTALL_ADDITIONAL_LOCALES` to `true`.
|
||||
|
||||
2 - Add locale codes to `PHP_FPM_ADDITIONAL_LOCALES`.
|
||||
|
||||
3 - Re-build your PHP-FPM Container `docker-compose build php-fpm`.
|
||||
|
||||
4 - Check enabled locales with `docker-compose exec php-fpm locale -a`
|
||||
|
||||
|
||||
|
||||
@ -1192,7 +1470,7 @@ We also recommend [setting the timezone in Laravel](http://www.camroncade.com/ma
|
||||
You can add your cron jobs to `workspace/crontab/root` after the `php artisan` line.
|
||||
|
||||
```
|
||||
* * * * * php /var/www/artisan schedule:run >> /dev/null 2>&1
|
||||
* * * * * laradock /usr/bin/php /var/www/artisan schedule:run >> /dev/null 2>&1
|
||||
|
||||
# Custom cron
|
||||
* * * * * root echo "Every Minute" > /var/log/cron.log 2>&1
|
||||
@ -1233,7 +1511,7 @@ ssh -o PasswordAuthentication=no \
|
||||
laradock@localhost
|
||||
```
|
||||
|
||||
To login as root, replace laradock@locahost with root@localhost.
|
||||
To login as root, replace laradock@localhost with root@localhost.
|
||||
|
||||
|
||||
|
||||
@ -1374,6 +1652,23 @@ Enabling Global Composer Install during the build for the container allows you t
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Magento-2-authentication-credentials"></a>
|
||||
## Magento 2 authentication credential (composer install)
|
||||
|
||||
1 - Open the `.env` file
|
||||
|
||||
2 - Search for the `WORKSPACE_COMPOSER_AUTH` argument under the Workspace Container and set it to `true`
|
||||
|
||||
3 - Now add your credentials to `workspace/auth.json`
|
||||
|
||||
4 - Re-build the Workspace Container `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Prestissimo"></a>
|
||||
## Install Prestissimo
|
||||
@ -1482,6 +1777,22 @@ To install NPM VUE CLI in the Workspace container
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-NPM-ANGULAR-CLI"></a>
|
||||
## Install NPM ANGULAR CLI
|
||||
|
||||
To install NPM ANGULAR CLI in the Workspace container
|
||||
|
||||
1 - Open the `.env` file
|
||||
|
||||
2 - Search for the `WORKSPACE_INSTALL_NPM_ANGULAR_CLI` argument under the Workspace Container and set it to `true`
|
||||
|
||||
3 - Re-build the container `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-Linuxbrew"></a>
|
||||
@ -1499,6 +1810,47 @@ Linuxbrew is a package manager for Linux. It is the Linux version of MacOS Homeb
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-FFMPEG"></a>
|
||||
## Install FFMPEG
|
||||
|
||||
To install FFMPEG in the Workspace container
|
||||
|
||||
1 - Open the `.env` file
|
||||
|
||||
2 - Search for the `WORKSPACE_INSTALL_FFMPEG` argument under the Workspace Container and set it to `true`
|
||||
|
||||
3 - Re-build the container `docker-compose build workspace`
|
||||
|
||||
4 - If you use the `php-worker` container too, please follow the same steps above especially if you have conversions that have been queued.
|
||||
|
||||
**PS** Don't forget to install the binary in the `php-fpm` container too by applying the same steps above to its container, otherwise the you'll get an error when running the `php-ffmpeg` binary.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-GNU-Parallel"></a>
|
||||
## Install GNU Parallel
|
||||
|
||||
GNU Parallel is a command line tool to run multiple processes in parallel.
|
||||
|
||||
(see https://www.gnu.org/software/parallel/parallel_tutorial.html)
|
||||
|
||||
To install GNU Parallel in the Workspace container
|
||||
|
||||
1 - Open the `.env` file
|
||||
|
||||
2 - Search for the `WORKSPACE_INSTALL_GNU_PARALLEL` argument under the Workspace Container and set it to `true`
|
||||
|
||||
3 - Re-build the container `docker-compose build workspace`
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Common-Aliases"></a>
|
||||
@ -1593,6 +1945,21 @@ will set the clock back 1 day. See (https://github.com/wolfcw/libfaketime) for m
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<a name="Install-YAML"></a>
|
||||
## Install YAML PHP extension in the php-fpm container
|
||||
YAML PHP extension allows you to easily parse and create YAML structured data. I like YAML because it's well readable for humans. See http://php.net/manual/en/ref.yaml.php and http://yaml.org/ for more info.
|
||||
|
||||
1 - Open the `.env` file
|
||||
<br>
|
||||
2 - Search for the `PHP_FPM_INSTALL_YAML` argument under the PHP-FPM container
|
||||
<br>
|
||||
3 - Set it to `true`
|
||||
<br>
|
||||
4 - Re-build the container `docker-compose build php-fpm`<br>
|
||||
|
||||
|
||||
<br>
|
||||
<a name="phpstorm-debugging"></a>
|
||||
## PHPStorm Debugging Guide
|
||||
@ -1699,7 +2066,7 @@ Laradock comes with `sync.sh`, an optional bash script, that automates installin
|
||||
DOCKER_SYNC_STRATEGY=native_osx
|
||||
```
|
||||
|
||||
3) set `APP_CODE_PATH_CONTAINER=/var/www` to `APP_CODE_PATH_CONTAINER=/var/www:nocopy` in the .env file
|
||||
3) set `APP_CODE_CONTAINER_FLAG` to `APP_CODE_CONTAINER_FLAG=:nocopy` in the .env file
|
||||
|
||||
4) Install the docker-sync gem on the host-machine:
|
||||
```bash
|
||||
@ -1887,7 +2254,7 @@ This error sometimes happens because your Laravel application isn't running on t
|
||||
|
||||
## I get stuck when building nginx on `fetch http://mirrors.aliyun.com/alpine/v3.5/main/x86_64/APKINDEX.tar.gz`
|
||||
|
||||
As stated on [#749](https://github.com/laradock/laradock/issues/749#issuecomment-419652646), Already fixed,just set `CHANGE_SOURCE` to false.
|
||||
As stated on [#749](https://github.com/laradock/laradock/issues/749#issuecomment-419652646), Already fixed,just set `CHANGE_SOURCE` to false.
|
||||
|
||||
## Custom composer repo packagist url and npm registry url
|
||||
|
||||
|
@ -50,12 +50,6 @@ $root@server:~/laravel/ git submodule add https://github.com/Laradock/laradock.g
|
||||
$root@server:~/laravel/ cd laradock
|
||||
```
|
||||
|
||||
## Install docker-compose command
|
||||
|
||||
```
|
||||
$root@server:~/laravel/laradock# curl -L https://github.com/docker/compose/releases/download/1.8.0/run.sh > /usr/local/bin/docker-compose
|
||||
$root@server:~/chmod +x /usr/local/bin/docker-compose
|
||||
```
|
||||
## Enter the laradock folder and rename env-example to .env.
|
||||
```
|
||||
$root@server:~/laravel/laradock# cp env-example .env
|
||||
@ -75,6 +69,14 @@ Note that more containers are available, find them in the [docs](http://laradock
|
||||
docker-compose exec workspace bash
|
||||
```
|
||||
|
||||
## Execute commands
|
||||
|
||||
If you want to only execute some command and don't want to enter bash, you can execute `docker-compose run workspace <command>`.
|
||||
|
||||
```
|
||||
docker-compose run workspace php artisan migrate
|
||||
```
|
||||
|
||||
## Install and configure Laravel
|
||||
|
||||
Let's install Laravel's dependencies, add the `.env` file, generate the key and give proper permissions to the cache folder.
|
||||
|
@ -58,7 +58,7 @@ That's it! enjoy :)
|
||||
<a name="features"></a>
|
||||
## Features
|
||||
|
||||
- Easy switch between PHP versions: 7.2, 7.1, 5.6...
|
||||
- Easy switch between PHP versions: 7.3, 7.2, 7.1, 5.6...
|
||||
- Choose your favorite database engine: MySQL, Postgres, MariaDB...
|
||||
- Run your own combination of software: Memcached, HHVM, Beanstalkd...
|
||||
- Every software runs on a separate container: PHP-FPM, NGINX, PHP-CLI...
|
||||
@ -103,7 +103,7 @@ Laradock introduces the **Workspace** Image, as a development environment.
|
||||
It contains a rich set of helpful tools, all pre-configured to work and integrate with almost any combination of Containers and tools you may choose.
|
||||
|
||||
**Workspace Image Tools**
|
||||
PHP CLI - Composer - Git - Linuxbrew - Node - V8JS - Gulp - SQLite - xDebug - Envoy - Deployer - Vim - Yarn - SOAP - Drush...
|
||||
PHP CLI - Composer - Git - Linuxbrew - Node - V8JS - Gulp - SQLite - xDebug - Envoy - Deployer - Vim - Yarn - SOAP - Drush - WP-CLI...
|
||||
|
||||
You can choose, which tools to install in your workspace container and other containers, from the `.env` file.
|
||||
|
||||
|
@ -1,7 +1,4 @@
|
||||
FROM adminer:4.3.0
|
||||
|
||||
# Version 4.3.1 contains PostgreSQL login errors. See docs.
|
||||
# See https://sourceforge.net/p/adminer/bugs-and-features/548/
|
||||
FROM adminer:4
|
||||
|
||||
LABEL maintainer="Patrick Artounian <partounian@gmail.com>"
|
||||
|
||||
@ -16,11 +13,15 @@ ARG INSTALL_MSSQL=false
|
||||
ENV INSTALL_MSSQL ${INSTALL_MSSQL}
|
||||
RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
set -xe \
|
||||
&& apk --update add --no-cache --virtual .phpize-deps $PHPIZE_DEPS unixodbc unixodbc-dev \
|
||||
&& pecl channel-update pecl.php.net \
|
||||
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
|
||||
&& echo "extension=sqlsrv.so" > /usr/local/etc/php/conf.d/20-sqlsrv.ini \
|
||||
&& echo "extension=pdo_sqlsrv.so" > /usr/local/etc/php/conf.d/20-pdo_sqlsrv.ini \
|
||||
# && apk --update add --no-cache --virtual .phpize-deps $PHPIZE_DEPS unixodbc unixodbc-dev \
|
||||
# && pecl channel-update pecl.php.net \
|
||||
# && pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
|
||||
# && echo "extension=sqlsrv.so" > /usr/local/etc/php/conf.d/20-sqlsrv.ini \
|
||||
# && echo "extension=pdo_sqlsrv.so" > /usr/local/etc/php/conf.d/20-pdo_sqlsrv.ini \
|
||||
&& apk --update add --no-cache freetds unixodbc \
|
||||
&& apk --update add --no-cache --virtual .build-deps $PHPIZE_DEPS freetds-dev unixodbc-dev \
|
||||
&& docker-php-ext-install pdo_dblib \
|
||||
&& apk del .build-deps \
|
||||
;fi
|
||||
|
||||
USER adminer
|
||||
|
@ -1,7 +1,3 @@
|
||||
FROM aerospike:latest
|
||||
|
||||
LABEL maintainer="Luciano Jr <luciano@lucianojr.com.br>"
|
||||
|
||||
RUN rm /etc/aerospike/aerospike.conf
|
||||
|
||||
COPY aerospike.conf /etc/aerospike/aerospike.conf
|
||||
|
@ -1,77 +0,0 @@
|
||||
# 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.
|
||||
}
|
||||
}
|
@ -1,16 +1,7 @@
|
||||
FROM phusion/baseimage:latest
|
||||
|
||||
FROM alpine
|
||||
LABEL 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
|
||||
RUN apk add --no-cache beanstalkd
|
||||
|
||||
EXPOSE 11300
|
||||
|
||||
CMD ["/usr/bin/beanstalkd"]
|
||||
ENTRYPOINT ["/usr/bin/beanstalkd"]
|
||||
|
@ -1,27 +1,5 @@
|
||||
FROM golang:alpine
|
||||
FROM abiosoft/caddy:no-stats
|
||||
|
||||
LABEL maintainer="Huadong Zuo <admin@zuohuadong.cn>"
|
||||
CMD ["--conf", "/etc/caddy/Caddyfile", "--log", "stdout", "--agree=true"]
|
||||
|
||||
RUN apk add --no-cache \
|
||||
openssh \
|
||||
git \
|
||||
build-base && \
|
||||
go get github.com/abiosoft/caddyplug/caddyplug \
|
||||
&& caddyplug install-caddy \
|
||||
apk del build-base
|
||||
|
||||
ARG plugins="cors"
|
||||
|
||||
## ARG plugins="cors cgi cloudflare azure linode"
|
||||
|
||||
RUN caddyplug install ${plugins}
|
||||
|
||||
RUN apk add --no-cache inotify-tools \
|
||||
&& echo -e "#!/bin/sh\nwhile inotifywait -e modify /etc/caddy; do\n\tpkill caddy\ndone " >> /start.sh \
|
||||
&& chmod +x /start.sh
|
||||
|
||||
EXPOSE 80 443
|
||||
|
||||
WORKDIR /var/www/public
|
||||
|
||||
CMD ["sh","-c","/start.sh & /usr/bin/caddy -conf /etc/caddy/Caddyfile -agree"]
|
||||
EXPOSE 80 443 2015
|
||||
|
3
couchdb/Dockerfile
Normal file
3
couchdb/Dockerfile
Normal file
@ -0,0 +1,3 @@
|
||||
FROM couchdb
|
||||
|
||||
EXPOSE 5984
|
@ -39,6 +39,10 @@ volumes:
|
||||
driver: ${VOLUMES_DRIVER}
|
||||
elasticsearch:
|
||||
driver: ${VOLUMES_DRIVER}
|
||||
mosquitto:
|
||||
driver: ${VOLUMES_DRIVER}
|
||||
sonarqube:
|
||||
driver: ${VOLUMES_DRIVER}
|
||||
|
||||
services:
|
||||
|
||||
@ -56,6 +60,7 @@ services:
|
||||
- INSTALL_SSH2=${WORKSPACE_INSTALL_SSH2}
|
||||
- INSTALL_GMP=${WORKSPACE_INSTALL_GMP}
|
||||
- INSTALL_SOAP=${WORKSPACE_INSTALL_SOAP}
|
||||
- INSTALL_XSL=${WORKSPACE_INSTALL_XSL}
|
||||
- INSTALL_LDAP=${WORKSPACE_INSTALL_LDAP}
|
||||
- INSTALL_IMAP=${WORKSPACE_INSTALL_IMAP}
|
||||
- INSTALL_MONGO=${WORKSPACE_INSTALL_MONGO}
|
||||
@ -68,12 +73,14 @@ services:
|
||||
- INSTALL_NPM_GULP=${WORKSPACE_INSTALL_NPM_GULP}
|
||||
- INSTALL_NPM_BOWER=${WORKSPACE_INSTALL_NPM_BOWER}
|
||||
- INSTALL_NPM_VUE_CLI=${WORKSPACE_INSTALL_NPM_VUE_CLI}
|
||||
- INSTALL_NPM_ANGULAR_CLI=${WORKSPACE_INSTALL_NPM_ANGULAR_CLI}
|
||||
- INSTALL_DRUSH=${WORKSPACE_INSTALL_DRUSH}
|
||||
- INSTALL_WP_CLI=${WORKSPACE_INSTALL_WP_CLI}
|
||||
- INSTALL_DRUPAL_CONSOLE=${WORKSPACE_INSTALL_DRUPAL_CONSOLE}
|
||||
- INSTALL_AEROSPIKE=${WORKSPACE_INSTALL_AEROSPIKE}
|
||||
- AEROSPIKE_PHP_REPOSITORY=${AEROSPIKE_PHP_REPOSITORY}
|
||||
- INSTALL_V8JS=${WORKSPACE_INSTALL_V8JS}
|
||||
- COMPOSER_GLOBAL_INSTALL=${WORKSPACE_COMPOSER_GLOBAL_INSTALL}
|
||||
- COMPOSER_AUTH=${WORKSPACE_COMPOSER_AUTH}
|
||||
- COMPOSER_REPO_PACKAGIST=${WORKSPACE_COMPOSER_REPO_PACKAGIST}
|
||||
- INSTALL_WORKSPACE_SSH=${WORKSPACE_INSTALL_WORKSPACE_SSH}
|
||||
- INSTALL_LARAVEL_ENVOY=${WORKSPACE_INSTALL_LARAVEL_ENVOY}
|
||||
@ -91,8 +98,12 @@ services:
|
||||
- INSTALL_PG_CLIENT=${WORKSPACE_INSTALL_PG_CLIENT}
|
||||
- INSTALL_PHALCON=${WORKSPACE_INSTALL_PHALCON}
|
||||
- INSTALL_SWOOLE=${WORKSPACE_INSTALL_SWOOLE}
|
||||
- INSTALL_TAINT=${WORKSPACE_INSTALL_TAINT}
|
||||
- INSTALL_LIBPNG=${WORKSPACE_INSTALL_LIBPNG}
|
||||
- INSTALL_IONCUBE=${WORKSPACE_INSTALL_IONCUBE}
|
||||
- INSTALL_MYSQL_CLIENT=${WORKSPACE_INSTALL_MYSQL_CLIENT}
|
||||
- INSTALL_PING=${WORKSPACE_INSTALL_PING}
|
||||
- INSTALL_SSHPASS=${WORKSPACE_INSTALL_SSHPASS}
|
||||
- PUID=${WORKSPACE_PUID}
|
||||
- PGID=${WORKSPACE_PGID}
|
||||
- CHROME_DRIVER_VERSION=${WORKSPACE_CHROME_DRIVER_VERSION}
|
||||
@ -102,8 +113,14 @@ services:
|
||||
- TZ=${WORKSPACE_TIMEZONE}
|
||||
- BLACKFIRE_CLIENT_ID=${BLACKFIRE_CLIENT_ID}
|
||||
- BLACKFIRE_CLIENT_TOKEN=${BLACKFIRE_CLIENT_TOKEN}
|
||||
- INSTALL_POWERLINE=${WORKSPACE_INSTALL_POWERLINE}
|
||||
- INSTALL_FFMPEG=${WORKSPACE_INSTALL_FFMPEG}
|
||||
- INSTALL_GNU_PARALLEL=${WORKSPACE_INSTALL_GNU_PARALLEL}
|
||||
- http_proxy
|
||||
- https_proxy
|
||||
- no_proxy
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
extra_hosts:
|
||||
- "dockerhost:${DOCKER_HOST_IP}"
|
||||
ports:
|
||||
@ -111,9 +128,12 @@ services:
|
||||
tty: true
|
||||
environment:
|
||||
- PHP_IDE_CONFIG=${PHP_IDE_CONFIG}
|
||||
- DOCKER_HOST=tcp://docker-in-docker:2375
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
links:
|
||||
- docker-in-docker
|
||||
|
||||
### PHP-FPM ##############################################
|
||||
php-fpm:
|
||||
@ -127,11 +147,11 @@ services:
|
||||
- INSTALL_BLACKFIRE=${INSTALL_BLACKFIRE}
|
||||
- INSTALL_SSH2=${PHP_FPM_INSTALL_SSH2}
|
||||
- INSTALL_SOAP=${PHP_FPM_INSTALL_SOAP}
|
||||
- INSTALL_XSL=${PHP_FPM_INSTALL_XSL}
|
||||
- INSTALL_IMAP=${PHP_FPM_INSTALL_IMAP}
|
||||
- INSTALL_MONGO=${PHP_FPM_INSTALL_MONGO}
|
||||
- INSTALL_AMQP=${PHP_FPM_INSTALL_AMQP}
|
||||
- INSTALL_MSSQL=${PHP_FPM_INSTALL_MSSQL}
|
||||
- INSTALL_ZIP_ARCHIVE=${PHP_FPM_INSTALL_ZIP_ARCHIVE}
|
||||
- INSTALL_BCMATH=${PHP_FPM_INSTALL_BCMATH}
|
||||
- INSTALL_GMP=${PHP_FPM_INSTALL_GMP}
|
||||
- INSTALL_PHPREDIS=${PHP_FPM_INSTALL_PHPREDIS}
|
||||
@ -139,23 +159,36 @@ services:
|
||||
- INSTALL_OPCACHE=${PHP_FPM_INSTALL_OPCACHE}
|
||||
- INSTALL_EXIF=${PHP_FPM_INSTALL_EXIF}
|
||||
- INSTALL_AEROSPIKE=${PHP_FPM_INSTALL_AEROSPIKE}
|
||||
- AEROSPIKE_PHP_REPOSITORY=${AEROSPIKE_PHP_REPOSITORY}
|
||||
- INSTALL_MYSQLI=${PHP_FPM_INSTALL_MYSQLI}
|
||||
- INSTALL_PGSQL=${PHP_FPM_INSTALL_PGSQL}
|
||||
- INSTALL_PG_CLIENT=${PHP_FPM_INSTALL_PG_CLIENT}
|
||||
- INSTALL_POSTGIS=${PHP_FPM_INSTALL_POSTGIS}
|
||||
- INSTALL_INTL=${PHP_FPM_INSTALL_INTL}
|
||||
- INSTALL_GHOSTSCRIPT=${PHP_FPM_INSTALL_GHOSTSCRIPT}
|
||||
- INSTALL_LDAP=${PHP_FPM_INSTALL_LDAP}
|
||||
- INSTALL_PHALCON=${PHP_FPM_INSTALL_PHALCON}
|
||||
- INSTALL_SWOOLE=${PHP_FPM_INSTALL_SWOOLE}
|
||||
- INSTALL_TAINT=${PHP_FPM_INSTALL_TAINT}
|
||||
- INSTALL_IMAGE_OPTIMIZERS=${PHP_FPM_INSTALL_IMAGE_OPTIMIZERS}
|
||||
- INSTALL_IMAGEMAGICK=${PHP_FPM_INSTALL_IMAGEMAGICK}
|
||||
- INSTALL_CALENDAR=${PHP_FPM_INSTALL_CALENDAR}
|
||||
- INSTALL_FAKETIME=${PHP_FPM_INSTALL_FAKETIME}
|
||||
- INSTALL_IONCUBE=${PHP_FPM_INSTALL_IONCUBE}
|
||||
- INSTALL_APCU=${PHP_FPM_INSTALL_APCU}
|
||||
- INSTALL_YAML=${PHP_FPM_INSTALL_YAML}
|
||||
- INSTALL_RDKAFKA=${PHP_FPM_INSTALL_RDKAFKA}
|
||||
- INSTALL_ADDITIONAL_LOCALES=${PHP_FPM_INSTALL_ADDITIONAL_LOCALES}
|
||||
- INSTALL_MYSQL_CLIENT=${PHP_FPM_INSTALL_MYSQL_CLIENT}
|
||||
- INSTALL_PING=${PHP_FPM_INSTALL_PING}
|
||||
- INSTALL_SSHPASS=${PHP_FPM_INSTALL_SSHPASS}
|
||||
- ADDITIONAL_LOCALES=${PHP_FPM_ADDITIONAL_LOCALES}
|
||||
- INSTALL_FFMPEG=${PHP_FPM_FFMPEG}
|
||||
- http_proxy
|
||||
- https_proxy
|
||||
- no_proxy
|
||||
volumes:
|
||||
- ./php-fpm/php${PHP_VERSION}.ini:/usr/local/etc/php/php.ini
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
expose:
|
||||
- "9000"
|
||||
extra_hosts:
|
||||
@ -177,12 +210,42 @@ services:
|
||||
context: ./php-worker
|
||||
args:
|
||||
- PHP_VERSION=${PHP_VERSION}
|
||||
- PHALCON_VERSION=${PHALCON_VERSION}
|
||||
- INSTALL_PGSQL=${PHP_WORKER_INSTALL_PGSQL}
|
||||
- INSTALL_BCMATH=${PHP_WORKER_INSTALL_BCMATH}
|
||||
- INSTALL_PHALCON=${PHP_WORKER_INSTALL_PHALCON}
|
||||
- INSTALL_SOAP=${PHP_WORKER_INSTALL_SOAP}
|
||||
- INSTALL_ZIP_ARCHIVE=${PHP_WORKER_INSTALL_ZIP_ARCHIVE}
|
||||
- INSTALL_MYSQL_CLIENT=${PHP_WORKER_INSTALL_MYSQL_CLIENT}
|
||||
- INSTALL_AMQP=${PHP_WORKER_INSTALL_AMQP}
|
||||
- INSTALL_GHOSTSCRIPT=${PHP_WORKER_INSTALL_GHOSTSCRIPT}
|
||||
- INSTALL_SWOOLE=${PHP_WORKER_INSTALL_SWOOLE}
|
||||
- INSTALL_TAINT=${PHP_WORKER_INSTALL_TAINT}
|
||||
- INSTALL_FFMPEG=${PHP_WORKER_INSTALL_FFMPEG}
|
||||
- INSTALL_GMP=${PHP_WORKER_INSTALL_GMP}
|
||||
- PUID=${PHP_WORKER_PUID}
|
||||
- PGID=${PHP_WORKER_PGID}
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
- ./php-worker/supervisord.d:/etc/supervisord.d
|
||||
depends_on:
|
||||
- workspace
|
||||
extra_hosts:
|
||||
- "dockerhost:${DOCKER_HOST_IP}"
|
||||
networks:
|
||||
- backend
|
||||
### Laravel Horizon ############################################
|
||||
laravel-horizon:
|
||||
build:
|
||||
context: ./laravel-horizon
|
||||
args:
|
||||
- PHP_VERSION=${PHP_VERSION}
|
||||
- INSTALL_PGSQL=${PHP_FPM_INSTALL_PGSQL}
|
||||
- INSTALL_BCMATH=${PHP_FPM_INSTALL_BCMATH}
|
||||
- INSTALL_MEMCACHED=${PHP_FPM_INSTALL_MEMCACHED}
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ./php-worker/supervisord.d:/etc/supervisord.d
|
||||
- ./laravel-horizon/supervisord.d:/etc/supervisord.d
|
||||
depends_on:
|
||||
- workspace
|
||||
extra_hosts:
|
||||
@ -198,8 +261,11 @@ services:
|
||||
- PHP_UPSTREAM_CONTAINER=${NGINX_PHP_UPSTREAM_CONTAINER}
|
||||
- PHP_UPSTREAM_PORT=${NGINX_PHP_UPSTREAM_PORT}
|
||||
- CHANGE_SOURCE=${CHANGE_SOURCE}
|
||||
- http_proxy
|
||||
- https_proxy
|
||||
- no_proxy
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
- ${NGINX_HOST_LOG_PATH}:/var/log/nginx
|
||||
- ${NGINX_SITES_PATH}:/etc/nginx/sites-available
|
||||
- ${NGINX_SSL_PATH}:/etc/nginx/ssl
|
||||
@ -233,7 +299,7 @@ services:
|
||||
- PHP_UPSTREAM_TIMEOUT=${APACHE_PHP_UPSTREAM_TIMEOUT}
|
||||
- DOCUMENT_ROOT=${APACHE_DOCUMENT_ROOT}
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
- ${APACHE_HOST_LOG_PATH}:/var/log/apache2
|
||||
- ${APACHE_SITES_PATH}:/etc/apache2/sites-available
|
||||
ports:
|
||||
@ -249,7 +315,7 @@ services:
|
||||
hhvm:
|
||||
build: ./hhvm
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
expose:
|
||||
- "9000"
|
||||
depends_on:
|
||||
@ -327,7 +393,12 @@ services:
|
||||
|
||||
### MariaDB ##############################################
|
||||
mariadb:
|
||||
build: ./mariadb
|
||||
build:
|
||||
context: ./mariadb
|
||||
args:
|
||||
- http_proxy
|
||||
- https_proxy
|
||||
- no_proxy
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/mariadb:/var/lib/mysql
|
||||
- ${MARIADB_ENTRYPOINT_INITDB}:/docker-entrypoint-initdb.d
|
||||
@ -353,6 +424,18 @@ services:
|
||||
- POSTGRES_DB=${POSTGRES_DB}
|
||||
- POSTGRES_USER=${POSTGRES_USER}
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
- GITLAB_POSTGRES_INIT=${GITLAB_POSTGRES_INIT}
|
||||
- GITLAB_POSTGRES_USER=${GITLAB_POSTGRES_USER}
|
||||
- GITLAB_POSTGRES_PASSWORD=${GITLAB_POSTGRES_PASSWORD}
|
||||
- GITLAB_POSTGRES_DB=${GITLAB_POSTGRES_DB}
|
||||
- JUPYTERHUB_POSTGRES_INIT=${JUPYTERHUB_POSTGRES_INIT}
|
||||
- JUPYTERHUB_POSTGRES_USER=${JUPYTERHUB_POSTGRES_USER}
|
||||
- JUPYTERHUB_POSTGRES_PASSWORD=${JUPYTERHUB_POSTGRES_PASSWORD}
|
||||
- JUPYTERHUB_POSTGRES_DB=${JUPYTERHUB_POSTGRES_DB}
|
||||
- SONARQUBE_POSTGRES_INIT=${SONARQUBE_POSTGRES_INIT}
|
||||
- SONARQUBE_POSTGRES_DB=${SONARQUBE_POSTGRES_DB}
|
||||
- SONARQUBE_POSTGRES_USER=${SONARQUBE_POSTGRES_USER}
|
||||
- SONARQUBE_POSTGRES_PASSWORD=${SONARQUBE_POSTGRES_PASSWORD}
|
||||
networks:
|
||||
- backend
|
||||
|
||||
@ -413,6 +496,25 @@ services:
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### Redis Cluster ##########################################
|
||||
redis-cluster:
|
||||
build: ./redis-cluster
|
||||
ports:
|
||||
- "${REDIS_CLUSTER_PORT_RANGE}:7000-7005"
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### ZooKeeper #########################################
|
||||
zookeeper:
|
||||
build: ./zookeeper
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/zookeeper/data:/data
|
||||
- ${DATA_PATH_HOST}/zookeeper/datalog:/datalog
|
||||
ports:
|
||||
- "${ZOOKEEPER_PORT}:2181"
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### Aerospike ##########################################
|
||||
aerospike:
|
||||
build: ./aerospike
|
||||
@ -424,6 +526,10 @@ services:
|
||||
- "${AEROSPIKE_FABRIC_PORT}:3001"
|
||||
- "${AEROSPIKE_HEARTBEAT_PORT}:3002"
|
||||
- "${AEROSPIKE_INFO_PORT}:3003"
|
||||
environment:
|
||||
- STORAGE_GB=${AEROSPIKE_STORAGE_GB}
|
||||
- MEM_GB=${AEROSPIKE_MEM_GB}
|
||||
- NAMESPACE=${AEROSPIKE_NAMESPACE}
|
||||
networks:
|
||||
- backend
|
||||
|
||||
@ -461,6 +567,9 @@ services:
|
||||
environment:
|
||||
- RABBITMQ_DEFAULT_USER=${RABBITMQ_DEFAULT_USER}
|
||||
- RABBITMQ_DEFAULT_PASS=${RABBITMQ_DEFAULT_PASS}
|
||||
hostname: laradock-rabbitmq
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/rabbitmq:/var/lib/rabbitmq
|
||||
depends_on:
|
||||
- php-fpm
|
||||
networks:
|
||||
@ -480,7 +589,7 @@ services:
|
||||
caddy:
|
||||
build: ./caddy
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
- ${CADDY_CONFIG_PATH}:/etc/caddy
|
||||
- ${CADDY_HOST_LOG_PATH}:/var/log/caddy
|
||||
- ${DATA_PATH_HOST}:/root/.caddy
|
||||
@ -525,11 +634,14 @@ services:
|
||||
|
||||
### pgAdmin ##############################################
|
||||
pgadmin:
|
||||
build: ./pgadmin
|
||||
image: dpage/pgadmin4:latest
|
||||
environment:
|
||||
- "PGADMIN_DEFAULT_EMAIL=${PGADMIN_DEFAULT_EMAIL}"
|
||||
- "PGADMIN_DEFAULT_PASSWORD=${PGADMIN_DEFAULT_PASSWORD}"
|
||||
ports:
|
||||
- "5050:5050"
|
||||
- "${PGADMIN_PORT}:80"
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/pgadmin-backup:/var/lib/pgadmin/storage/pgadmin4
|
||||
- ${DATA_PATH_HOST}/pgadmin:/var/lib/pgadmin
|
||||
depends_on:
|
||||
- postgres
|
||||
networks:
|
||||
@ -558,6 +670,24 @@ services:
|
||||
- frontend
|
||||
- backend
|
||||
|
||||
### Logstash ##############################################
|
||||
logstash:
|
||||
build: ./logstash
|
||||
volumes:
|
||||
- './logstash/config/logstash.yml:/usr/share/logstash/config/logstash.yml'
|
||||
- './logstash/pipeline:/usr/share/logstash/pipeline'
|
||||
ports:
|
||||
- '5001:5001'
|
||||
environment:
|
||||
LS_JAVA_OPTS: '-Xmx1g -Xms1g'
|
||||
env_file:
|
||||
- .env
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
depends_on:
|
||||
- elasticsearch
|
||||
|
||||
### Kibana ##############################################
|
||||
kibana:
|
||||
build: ./kibana
|
||||
@ -575,7 +705,7 @@ services:
|
||||
context: ./certbot
|
||||
volumes:
|
||||
- ./data/certbot/certs/:/var/certs
|
||||
- ./certbot/letsencrypt/:${APP_CODE_PATH_CONTAINER}/letsencrypt
|
||||
- ./certbot/letsencrypt/:/var/www/letsencrypt
|
||||
environment:
|
||||
- CN="fake.domain.com"
|
||||
- EMAIL="fake.email@gmail.com"
|
||||
@ -698,7 +828,7 @@ services:
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
|
||||
|
||||
### Solr ################################################
|
||||
solr:
|
||||
build:
|
||||
@ -835,7 +965,7 @@ services:
|
||||
build:
|
||||
context: ./aws
|
||||
volumes:
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}
|
||||
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
|
||||
depends_on:
|
||||
- workspace
|
||||
tty: true
|
||||
@ -860,18 +990,19 @@ services:
|
||||
context: ./gitlab
|
||||
environment:
|
||||
GITLAB_OMNIBUS_CONFIG: |
|
||||
external_url '${GITLAB_DOMAIN_NAME}'
|
||||
redis['enable'] = false
|
||||
nginx['listen_https'] = false
|
||||
nginx['listen_port'] = 80
|
||||
postgresql['enable'] = false
|
||||
gitlab_rails['trusted_proxies'] = ['caddy','nginx','apache2']
|
||||
gitlab_rails['redis_host'] = 'redis'
|
||||
external_url '${GITLAB_DOMAIN_NAME}'
|
||||
redis['enable'] = false
|
||||
nginx['listen_https'] = false
|
||||
nginx['listen_port'] = 80
|
||||
nginx['custom_gitlab_server_config'] = "set_real_ip_from 172.0.0.0/8;\nreal_ip_header X-Real-IP;\nreal_ip_recursive on;"
|
||||
postgresql['enable'] = false
|
||||
gitlab_rails['trusted_proxies'] = ['caddy','nginx','apache2']
|
||||
gitlab_rails['redis_host'] = 'redis'
|
||||
gitlab_rails['redis_database'] = 8
|
||||
gitlab_rails['db_host'] = 'postgres'
|
||||
gitlab_rails['db_username'] = 'laradock_gitlab'
|
||||
gitlab_rails['db_password'] = 'laradock_gitlab'
|
||||
gitlab_rails['db_database'] = 'laradock_gitlab'
|
||||
gitlab_rails['db_host'] = '${GITLAB_POSTGRES_HOST}'
|
||||
gitlab_rails['db_username'] = '${GITLAB_POSTGRES_USER}'
|
||||
gitlab_rails['db_password'] = '${GITLAB_POSTGRES_PASSWORD}'
|
||||
gitlab_rails['db_database'] = '${GITLAB_POSTGRES_DB}'
|
||||
gitlab_rails['initial_root_password'] = '${GITLAB_ROOT_PASSWORD}'
|
||||
gitlab_rails['gitlab_shell_ssh_port'] = ${GITLAB_HOST_SSH_PORT}
|
||||
volumes:
|
||||
@ -890,12 +1021,15 @@ services:
|
||||
gitlab-runner:
|
||||
image: gitlab/gitlab-runner:latest
|
||||
environment:
|
||||
- CI_SERVER_URL=${GITLAB_DOMAIN_NAME}
|
||||
- CI_SERVER_URL=${GITLAB_CI_SERVER_URL}
|
||||
- REGISTRATION_TOKEN=${GITLAB_RUNNER_REGISTRATION_TOKEN}
|
||||
- RUNNER_NAME=${COMPOSE_PROJECT_NAME}-runner
|
||||
- REGISTER_NON_INTERACTIVE=${GITLAB_REGISTER_NON_INTERACTIVE}
|
||||
- RUNNER_EXECUTOR=shell
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/gitlab/runner:/etc/gitlab-runner
|
||||
- /var/run/docker.sock:/var/run/docker.sock:rw
|
||||
restart: always
|
||||
|
||||
|
||||
### JupyterHub #########################################
|
||||
jupyterhub:
|
||||
build:
|
||||
@ -903,7 +1037,6 @@ services:
|
||||
depends_on:
|
||||
- postgres
|
||||
- jupyterhub-user
|
||||
restart: always
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock:rw
|
||||
- ${DATA_PATH_HOST}/jupyterhub/:/data
|
||||
@ -924,7 +1057,8 @@ services:
|
||||
- JUPYTERHUB_OAUTH_CALLBACK_URL=${JUPYTERHUB_OAUTH_CALLBACK_URL}
|
||||
- JUPYTERHUB_OAUTH_CLIENT_ID=${JUPYTERHUB_OAUTH_CLIENT_ID}
|
||||
- JUPYTERHUB_OAUTH_CLIENT_SECRET=${JUPYTERHUB_OAUTH_CLIENT_SECRET}
|
||||
- JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE=${JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE}
|
||||
- JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE=${COMPOSE_PROJECT_NAME}_jupyterhub-user
|
||||
- JUPYTERHUB_ENABLE_NVIDIA=${JUPYTERHUB_ENABLE_NVIDIA}
|
||||
jupyterhub-user:
|
||||
build:
|
||||
context: ./jupyterhub
|
||||
@ -974,9 +1108,10 @@ services:
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### PHPRedisAdmin ################################################
|
||||
phpredisadmin:
|
||||
image: erikdubbelboer/phpredisadmin:latest
|
||||
### REDISWEBUI ################################################
|
||||
redis-webui:
|
||||
build:
|
||||
context: ./redis-webui
|
||||
environment:
|
||||
- ADMIN_USER=${REDIS_WEBUI_USERNAME}
|
||||
- ADMIN_PASS=${REDIS_WEBUI_PASSWORD}
|
||||
@ -993,7 +1128,6 @@ services:
|
||||
mongo-webui:
|
||||
build:
|
||||
context: ./mongo-webui
|
||||
restart: always
|
||||
environment:
|
||||
- ROOT_URL=${MONGO_WEBUI_ROOT_URL}
|
||||
- MONGO_URL=${MONGO_WEBUI_MONGO_URL}
|
||||
@ -1006,7 +1140,7 @@ services:
|
||||
- backend
|
||||
depends_on:
|
||||
- mongo
|
||||
|
||||
|
||||
### Metabase #################################################
|
||||
metabase:
|
||||
image: metabase/metabase:latest
|
||||
@ -1268,3 +1402,82 @@ services:
|
||||
backend:
|
||||
aliases:
|
||||
- fetchmail
|
||||
|
||||
### TRAEFIK #########################################
|
||||
traefik:
|
||||
build:
|
||||
context: ./traefik
|
||||
command: --docker
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
ports:
|
||||
- "${TRAEFIK_HOST_HTTP_PORT}:80"
|
||||
- "${TRAEFIK_HOST_HTTPS_PORT}:443"
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
labels:
|
||||
- traefik.backend=traefik
|
||||
- traefik.frontend.rule=Host:monitor.localhost
|
||||
- traefik.port=8080
|
||||
|
||||
### MOSQUITTO Broker #########################################
|
||||
mosquitto:
|
||||
build:
|
||||
context: ./mosquitto
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/mosquitto/data:/mosquitto/data
|
||||
ports:
|
||||
- "${MOSQUITTO_PORT}:9001"
|
||||
networks:
|
||||
- frontend
|
||||
- backend
|
||||
|
||||
### COUCHDB ###################################################
|
||||
couchdb:
|
||||
build:
|
||||
context: ./couchdb
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/couchdb/data:/opt/couchdb/data
|
||||
ports:
|
||||
- "${COUCHDB_PORT}:5984"
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### Manticore Search ###########################################
|
||||
manticore:
|
||||
build:
|
||||
context: ./manticore
|
||||
volumes:
|
||||
- ${MANTICORE_CONFIG_PATH}:/etc/sphinxsearch
|
||||
- ${DATA_PATH_HOST}/manticore/data:/var/lib/manticore/data
|
||||
- ${DATA_PATH_HOST}/manticore/log:/var/lib/manticore/log
|
||||
ports:
|
||||
- "${MANTICORE_API_PORT}:9312"
|
||||
- "${MANTICORE_SPHINXQL_PORT}:9306"
|
||||
- "${MANTICORE_HTTP_PORT}:9308"
|
||||
networks:
|
||||
- backend
|
||||
|
||||
### SONARQUBE ################################################
|
||||
sonarqube:
|
||||
build:
|
||||
context: ./sonarqube
|
||||
hostname: "${SONARQUBE_HOSTNAME}"
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/sonarqube/conf:/opt/sonarqube/conf
|
||||
- ${DATA_PATH_HOST}/sonarqube/data:/opt/sonarqube/data
|
||||
- ${DATA_PATH_HOST}/sonarqube/logs:/opt/sonarqube/logs
|
||||
- ${DATA_PATH_HOST}/sonarqube/extensions:/opt/sonarqube/extensions
|
||||
- ${DATA_PATH_HOST}/sonarqube/plugins:/opt/sonarqube/lib/bundled-plugins
|
||||
ports:
|
||||
- ${SONARQUBE_PORT}:9000
|
||||
depends_on:
|
||||
- postgres
|
||||
environment:
|
||||
- sonar.jdbc.username=${SONARQUBE_POSTGRES_USER}
|
||||
- sonar.jdbc.password=${SONARQUBE_POSTGRES_PASSWORD}
|
||||
- sonar.jdbc.url=jdbc:postgresql://${SONARQUBE_POSTGRES_HOST}:5432/${SONARQUBE_POSTGRES_DB}
|
||||
networks:
|
||||
- backend
|
||||
- frontend
|
||||
|
@ -1,3 +1,3 @@
|
||||
FROM docker.elastic.co/elasticsearch/elasticsearch:6.2.3
|
||||
FROM docker.elastic.co/elasticsearch/elasticsearch:6.6.0
|
||||
|
||||
EXPOSE 9200 9300
|
||||
|
129
env-example
129
env-example
@ -7,8 +7,11 @@
|
||||
# Point to the path of your applications code on your host
|
||||
APP_CODE_PATH_HOST=../
|
||||
|
||||
# Point to where the `APP_CODE_PATH_HOST` should be in the container. You may add flags to the path `:cached`, `:delegated`. When using Docker Sync add `:nocopy`
|
||||
APP_CODE_PATH_CONTAINER=/var/www:cached
|
||||
# Point to where the `APP_CODE_PATH_HOST` should be in the container
|
||||
APP_CODE_PATH_CONTAINER=/var/www
|
||||
|
||||
# You may add flags to the path `:cached`, `:delegated`. When using Docker Sync add `:nocopy`
|
||||
APP_CODE_CONTAINER_FLAG=:cached
|
||||
|
||||
# Choose storage path on your machine. For all storage systems
|
||||
DATA_PATH_HOST=~/.laradock/data
|
||||
@ -34,7 +37,7 @@ COMPOSE_PROJECT_NAME=laradock
|
||||
|
||||
### PHP Version ###########################################
|
||||
|
||||
# Select a PHP version of the Workspace and PHP-FPM containers (Does not apply to HHVM). Accepted values: 7.2 - 7.1 - 7.0 - 5.6
|
||||
# Select a PHP version of the Workspace and PHP-FPM containers (Does not apply to HHVM). Accepted values: 7.3 - 7.2 - 7.1 - 7.0 - 5.6
|
||||
PHP_VERSION=7.2
|
||||
|
||||
### Phalcon Version ###########################################
|
||||
@ -79,6 +82,7 @@ DOCKER_SYNC_STRATEGY=native_osx
|
||||
### WORKSPACE #############################################
|
||||
|
||||
WORKSPACE_COMPOSER_GLOBAL_INSTALL=true
|
||||
WORKSPACE_COMPOSER_AUTH=false
|
||||
WORKSPACE_COMPOSER_REPO_PACKAGIST=
|
||||
WORKSPACE_INSTALL_NODE=true
|
||||
WORKSPACE_NODE_VERSION=node
|
||||
@ -88,6 +92,7 @@ WORKSPACE_YARN_VERSION=latest
|
||||
WORKSPACE_INSTALL_NPM_GULP=true
|
||||
WORKSPACE_INSTALL_NPM_BOWER=false
|
||||
WORKSPACE_INSTALL_NPM_VUE_CLI=true
|
||||
WORKSPACE_INSTALL_NPM_ANGULAR_CLI=false
|
||||
WORKSPACE_INSTALL_PHPREDIS=true
|
||||
WORKSPACE_INSTALL_WORKSPACE_SSH=false
|
||||
WORKSPACE_INSTALL_SUBVERSION=false
|
||||
@ -97,6 +102,7 @@ WORKSPACE_INSTALL_SSH2=false
|
||||
WORKSPACE_INSTALL_LDAP=false
|
||||
WORKSPACE_INSTALL_GMP=false
|
||||
WORKSPACE_INSTALL_SOAP=false
|
||||
WORKSPACE_INSTALL_XSL=false
|
||||
WORKSPACE_INSTALL_IMAP=false
|
||||
WORKSPACE_INSTALL_MONGO=false
|
||||
WORKSPACE_INSTALL_AMQP=false
|
||||
@ -104,6 +110,7 @@ WORKSPACE_INSTALL_MSSQL=false
|
||||
WORKSPACE_INSTALL_DRUSH=false
|
||||
WORKSPACE_DRUSH_VERSION=8.1.17
|
||||
WORKSPACE_INSTALL_DRUPAL_CONSOLE=false
|
||||
WORKSPACE_INSTALL_WP_CLI=false
|
||||
WORKSPACE_INSTALL_AEROSPIKE=false
|
||||
WORKSPACE_INSTALL_V8JS=false
|
||||
WORKSPACE_INSTALL_LARAVEL_ENVOY=false
|
||||
@ -114,6 +121,7 @@ WORKSPACE_INSTALL_LINUXBREW=false
|
||||
WORKSPACE_INSTALL_MC=false
|
||||
WORKSPACE_INSTALL_SYMFONY=false
|
||||
WORKSPACE_INSTALL_PYTHON=false
|
||||
WORKSPACE_INSTALL_POWERLINE=false
|
||||
WORKSPACE_INSTALL_IMAGE_OPTIMIZERS=false
|
||||
WORKSPACE_INSTALL_IMAGEMAGICK=false
|
||||
WORKSPACE_INSTALL_TERRAFORM=false
|
||||
@ -121,17 +129,24 @@ WORKSPACE_INSTALL_DUSK_DEPS=false
|
||||
WORKSPACE_INSTALL_PG_CLIENT=false
|
||||
WORKSPACE_INSTALL_PHALCON=false
|
||||
WORKSPACE_INSTALL_SWOOLE=false
|
||||
WORKSPACE_INSTALL_TAINT=false
|
||||
WORKSPACE_INSTALL_LIBPNG=false
|
||||
WORKSPACE_INSTALL_IONCUBE=false
|
||||
WORKSPACE_INSTALL_MYSQL_CLIENT=false
|
||||
WORKSPACE_INSTALL_PING=false
|
||||
WORKSPACE_INSTALL_SSHPASS=false
|
||||
WORKSPACE_INSTALL_INOTIFY=false
|
||||
WORKSPACE_INSTALL_FSWATCH=false
|
||||
WORKSPACE_PUID=1000
|
||||
WORKSPACE_PGID=1000
|
||||
WORKSPACE_CHROME_DRIVER_VERSION=2.32
|
||||
WORKSPACE_CHROME_DRIVER_VERSION=2.42
|
||||
WORKSPACE_TIMEZONE=UTC
|
||||
WORKSPACE_SSH_PORT=2222
|
||||
WORKSPACE_INSTALL_FFMPEG=false
|
||||
WORKSPACE_INSTALL_GNU_PARALLEL=false
|
||||
|
||||
### PHP_FPM ###############################################
|
||||
|
||||
PHP_FPM_INSTALL_ZIP_ARCHIVE=true
|
||||
PHP_FPM_INSTALL_BCMATH=true
|
||||
PHP_FPM_INSTALL_MYSQLI=true
|
||||
PHP_FPM_INSTALL_INTL=true
|
||||
@ -141,6 +156,7 @@ PHP_FPM_INSTALL_IMAGE_OPTIMIZERS=true
|
||||
PHP_FPM_INSTALL_PHPREDIS=true
|
||||
PHP_FPM_INSTALL_MEMCACHED=false
|
||||
PHP_FPM_INSTALL_XDEBUG=false
|
||||
PHP_FPM_INSTALL_XHPROF=false
|
||||
PHP_FPM_INSTALL_PHPDBG=false
|
||||
PHP_FPM_INSTALL_IMAP=false
|
||||
PHP_FPM_INSTALL_MONGO=false
|
||||
@ -148,6 +164,7 @@ PHP_FPM_INSTALL_AMQP=false
|
||||
PHP_FPM_INSTALL_MSSQL=false
|
||||
PHP_FPM_INSTALL_SSH2=false
|
||||
PHP_FPM_INSTALL_SOAP=false
|
||||
PHP_FPM_INSTALL_XSL=false
|
||||
PHP_FPM_INSTALL_GMP=false
|
||||
PHP_FPM_INSTALL_EXIF=false
|
||||
PHP_FPM_INSTALL_AEROSPIKE=false
|
||||
@ -156,18 +173,41 @@ PHP_FPM_INSTALL_GHOSTSCRIPT=false
|
||||
PHP_FPM_INSTALL_LDAP=false
|
||||
PHP_FPM_INSTALL_PHALCON=false
|
||||
PHP_FPM_INSTALL_SWOOLE=false
|
||||
PHP_FPM_INSTALL_TAINT=false
|
||||
PHP_FPM_INSTALL_PG_CLIENT=false
|
||||
PHP_FPM_INSTALL_POSTGIS=false
|
||||
PHP_FPM_INSTALL_PCNTL=false
|
||||
PHP_FPM_INSTALL_CALENDAR=false
|
||||
PHP_FPM_INSTALL_FAKETIME=false
|
||||
PHP_FPM_INSTALL_IONCUBE=false
|
||||
PHP_FPM_INSTALL_RDKAFKA=false
|
||||
PHP_FPM_FAKETIME=-0
|
||||
PHP_FPM_INSTALL_APCU=false
|
||||
PHP_FPM_INSTALL_YAML=false
|
||||
PHP_FPM_INSTALL_ADDITIONAL_LOCALES=false
|
||||
PHP_FPM_INSTALL_MYSQL_CLIENT=false
|
||||
PHP_FPM_INSTALL_PING=false
|
||||
PHP_FPM_INSTALL_SSHPASS=false
|
||||
PHP_FPM_FFMPEG=false
|
||||
PHP_FPM_ADDITIONAL_LOCALES="es_ES.UTF-8 fr_FR.UTF-8"
|
||||
|
||||
### PHP_WORKER ############################################
|
||||
|
||||
PHP_WORKER_INSTALL_PGSQL=false
|
||||
PHP_WORKER_INSTALL_BCMATH=false
|
||||
PHP_WORKER_INSTALL_PHALCON=false
|
||||
PHP_WORKER_INSTALL_SOAP=false
|
||||
PHP_WORKER_INSTALL_ZIP_ARCHIVE=false
|
||||
PHP_WORKER_INSTALL_MYSQL_CLIENT=false
|
||||
PHP_WORKER_INSTALL_AMQP=false
|
||||
PHP_WORKER_INSTALL_GHOSTSCRIPT=false
|
||||
PHP_WORKER_INSTALL_SWOOLE=false
|
||||
PHP_WORKER_INSTALL_TAINT=false
|
||||
PHP_WORKER_INSTALL_FFMPEG=false
|
||||
PHP_WORKER_INSTALL_GMP=false
|
||||
|
||||
PHP_WORKER_PUID=1000
|
||||
PHP_WORKER_PGID=1000
|
||||
|
||||
### NGINX #################################################
|
||||
|
||||
@ -204,6 +244,14 @@ MYSQL_ENTRYPOINT_INITDB=./mysql/docker-entrypoint-initdb.d
|
||||
|
||||
REDIS_PORT=6379
|
||||
|
||||
### REDIS CLUSTER #########################################
|
||||
|
||||
REDIS_CLUSTER_PORT_RANGE=7000-7005
|
||||
|
||||
### ZooKeeper #############################################
|
||||
|
||||
ZOOKEEPER_PORT=2181
|
||||
|
||||
### Percona ###############################################
|
||||
|
||||
PERCONA_DATABASE=homestead
|
||||
@ -346,13 +394,9 @@ AEROSPIKE_SERVICE_PORT=3000
|
||||
AEROSPIKE_FABRIC_PORT=3001
|
||||
AEROSPIKE_HEARTBEAT_PORT=3002
|
||||
AEROSPIKE_INFO_PORT=3003
|
||||
|
||||
## Temp solution, this should be in the dockerfile
|
||||
# for all versions "https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz"
|
||||
# for php 7.2 (using this branch until the support for 7.2 on master) "https://github.com/aerospike/aerospike-client-php/archive/7.2.0-release-candidate.tar.gz"
|
||||
AEROSPIKE_PHP_REPOSITORY=https://github.com/aerospike/aerospike-client-php/archive/7.2.0-release-candidate.tar.gz
|
||||
# for php 5.6
|
||||
# AEROSPIKE_PHP_REPOSITORY=https://github.com/aerospike/aerospike-client-php5/archive/3.4.15.tar.gz
|
||||
AEROSPIKE_STORAGE_GB=1
|
||||
AEROSPIKE_MEM_GB=1
|
||||
AEROSPIKE_NAMESPACE=test
|
||||
|
||||
### RETHINKDB #############################################
|
||||
|
||||
@ -489,14 +533,25 @@ SOLR_DATAIMPORTHANDLER_MYSQL=false
|
||||
SOLR_DATAIMPORTHANDLER_MSSQL=false
|
||||
|
||||
### GITLAB ###############################################
|
||||
GITLAB_POSTGRES_INIT=true
|
||||
GITLAB_HOST_HTTP_PORT=8989
|
||||
GITLAB_HOST_HTTPS_PORT=9898
|
||||
GITLAB_HOST_SSH_PORT=2289
|
||||
GITLAB_DOMAIN_NAME=http://localhost
|
||||
GITLAB_ROOT_PASSWORD=laradock
|
||||
GITLAB_HOST_LOG_PATH=./logs/gitlab
|
||||
GITLAB_POSTGRES_HOST=postgres
|
||||
GITLAB_POSTGRES_USER=laradock_gitlab
|
||||
GITLAB_POSTGRES_PASSWORD=laradock_gitlab
|
||||
GITLAB_POSTGRES_DB=laradock_gitlab
|
||||
|
||||
### GITLAB-RUNNER ###############################################
|
||||
GITLAB_CI_SERVER_URL=http://localhost:8989
|
||||
GITLAB_RUNNER_REGISTRATION_TOKEN=<my-registration-token>
|
||||
GITLAB_REGISTER_NON_INTERACTIVE=true
|
||||
|
||||
### JUPYTERHUB ###############################################
|
||||
JUPYTERHUB_POSTGRES_INIT=true
|
||||
JUPYTERHUB_POSTGRES_HOST=postgres
|
||||
JUPYTERHUB_POSTGRES_USER=laradock_jupyterhub
|
||||
JUPYTERHUB_POSTGRES_PASSWORD=laradock_jupyterhub
|
||||
@ -505,10 +560,10 @@ JUPYTERHUB_PORT=9991
|
||||
JUPYTERHUB_OAUTH_CALLBACK_URL=http://laradock:9991/hub/oauth_callback
|
||||
JUPYTERHUB_OAUTH_CLIENT_ID={GITHUB_CLIENT_ID}
|
||||
JUPYTERHUB_OAUTH_CLIENT_SECRET={GITHUB_CLIENT_SECRET}
|
||||
JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE=laradock_jupyterhub-user
|
||||
JUPYTERHUB_CUSTOM_CONFIG=./jupyterhub/jupyterhub_config.py
|
||||
JUPYTERHUB_USER_DATA=/jupyterhub
|
||||
JUPYTERHUB_USER_LIST=./jupyterhub/userlist
|
||||
JUPYTERHUB_ENABLE_NVIDIA=false
|
||||
|
||||
### IPYTHON ##################################################
|
||||
LARADOCK_IPYTHON_CONTROLLER_IP=127.0.0.1
|
||||
@ -516,7 +571,7 @@ LARADOCK_IPYTHON_CONTROLLER_IP=127.0.0.1
|
||||
### NETDATA ###############################################
|
||||
NETDATA_PORT=19999
|
||||
|
||||
### PHPREDISADMIN #########################################
|
||||
### REDISWEBUI #########################################
|
||||
REDIS_WEBUI_USERNAME=laradock
|
||||
REDIS_WEBUI_PASSWORD=laradock
|
||||
REDIS_WEBUI_CONNECT_HOST=redis
|
||||
@ -589,7 +644,7 @@ MAILU_RECIPIENT_DELIMITER=+
|
||||
# DMARC rua and ruf email
|
||||
MAILU_DMARC_RUA=admin
|
||||
MAILU_DMARC_RUF=admin
|
||||
# Weclome email, enable and set a topic and body if you wish to send welcome
|
||||
# Welcome email, enable and set a topic and body if you wish to send welcome
|
||||
# emails to all users.
|
||||
MAILU_WELCOME=True
|
||||
MAILU_WELCOME_SUBJECT=Welcome to your new email account
|
||||
@ -611,3 +666,47 @@ MAILU_ADMIN=true
|
||||
MAILU_WEBMAIL=rainloop
|
||||
# Dav server implementation (value: radicale, none)
|
||||
MAILU_WEBDAV=radicale
|
||||
|
||||
|
||||
### TRAEFIK #################################################
|
||||
|
||||
TRAEFIK_HOST_HTTP_PORT=80
|
||||
TRAEFIK_HOST_HTTPS_PORT=443
|
||||
|
||||
|
||||
### MOSQUITTO #################################################
|
||||
|
||||
MOSQUITTO_PORT=9001
|
||||
|
||||
### COUCHDB ###################################################
|
||||
|
||||
COUCHDB_PORT=5984
|
||||
|
||||
### Manticore Search ##########################################
|
||||
|
||||
MANTICORE_CONFIG_PATH=./manticore/config
|
||||
MANTICORE_API_PORT=9312
|
||||
MANTICORE_SPHINXQL_PORT=9306
|
||||
MANTICORE_HTTP_PORT=9308
|
||||
|
||||
### pgadmin ##################################################
|
||||
# use this address http://ip6-localhost:5050
|
||||
PGADMIN_PORT=5050
|
||||
PGADMIN_DEFAULT_EMAIL=pgadmin4@pgadmin.org
|
||||
PGADMIN_DEFAULT_PASSWORD=admin
|
||||
|
||||
### SONARQUBE ################################################
|
||||
## docker-compose up -d sonarqube
|
||||
## (If you encounter a database error)
|
||||
## docker-compose exec --user=root postgres
|
||||
## source docker-entrypoint-initdb.d/init_sonarqube_db.sh
|
||||
## (If you encounter logs error)
|
||||
## docker-compose run --user=root --rm sonarqube chown sonarqube:sonarqube /opt/sonarqube/logs
|
||||
|
||||
SONARQUBE_HOSTNAME=sonar.example.com
|
||||
SONARQUBE_PORT=9000
|
||||
SONARQUBE_POSTGRES_INIT=true
|
||||
SONARQUBE_POSTGRES_HOST=postgres
|
||||
SONARQUBE_POSTGRES_DB=sonar
|
||||
SONARQUBE_POSTGRES_USER=sonar
|
||||
SONARQUBE_POSTGRES_PASSWORD=sonarPass
|
||||
|
@ -2,4 +2,8 @@ FROM theiaide/theia
|
||||
|
||||
LABEL maintainer="ahkui <ahkui@outlook.com>"
|
||||
|
||||
RUN echo 'fs.inotify.max_user_watches=524288' >> /etc/sysctl.conf
|
||||
USER root
|
||||
|
||||
RUN echo 'fs.inotify.max_user_watches=524288' >> /etc/sysctl.conf
|
||||
|
||||
USER theia
|
||||
|
@ -4,7 +4,7 @@ LABEL maintainer="ahkui <ahkui@outlook.com>"
|
||||
|
||||
USER root
|
||||
|
||||
RUN apk add --no-cache build-base
|
||||
RUN apk add --no-cache build-base zeromq-dev
|
||||
|
||||
RUN python -m pip --quiet --no-cache-dir install \
|
||||
ipyparallel
|
||||
@ -14,4 +14,4 @@ RUN ipython profile create --parallel --profile=default
|
||||
COPY ipcontroller-client.json /root/.ipython/profile_default/security/ipcontroller-client.json
|
||||
COPY ipcontroller-engine.json /root/.ipython/profile_default/security/ipcontroller-engine.json
|
||||
|
||||
CMD ["sh","-c","ipcontroller --ip=* --reuse"]
|
||||
CMD ["sh","-c","ipcontroller --ip=* --reuse"]
|
||||
|
@ -4,7 +4,7 @@ LABEL maintainer="ahkui <ahkui@outlook.com>"
|
||||
|
||||
USER root
|
||||
|
||||
RUN apk add --no-cache build-base
|
||||
RUN apk add --no-cache build-base zeromq-dev
|
||||
|
||||
RUN python -m pip --quiet --no-cache-dir install \
|
||||
ipyparallel \
|
||||
|
@ -108,3 +108,7 @@ COPY install-plugins.sh /usr/local/bin/install-plugins.sh
|
||||
#RUN chmod 644 /var/jenkins_home/.ssh/id_rsa.pub
|
||||
## ssh-keyscan -H github.com >> ~/.ssh/known_hosts
|
||||
## ssh-keyscan -H bitbucket.org >> ~/.ssh/known_hosts
|
||||
|
||||
# Fix docker permission denied error
|
||||
USER root
|
||||
RUN usermod -aG docker jenkins
|
||||
|
@ -10,6 +10,7 @@ ENV JUPYTERHUB_OAUTH_CALLBACK_URL ${JUPYTERHUB_OAUTH_CALLBACK_URL}
|
||||
ENV JUPYTERHUB_OAUTH_CLIENT_ID ${JUPYTERHUB_OAUTH_CLIENT_ID}
|
||||
ENV JUPYTERHUB_OAUTH_CLIENT_SECRET ${JUPYTERHUB_OAUTH_CLIENT_SECRET}
|
||||
ENV JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE ${JUPYTERHUB_LOCAL_NOTEBOOK_IMAGE}
|
||||
ENV JUPYTERHUB_ENABLE_NVIDIA ${JUPYTERHUB_ENABLE_NVIDIA}
|
||||
|
||||
RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
|
||||
|
||||
|
@ -6,6 +6,9 @@ import os
|
||||
|
||||
c = get_config()
|
||||
|
||||
# create system users that don't exist yet
|
||||
c.LocalAuthenticator.create_system_users = True
|
||||
|
||||
def create_dir_hook(spawner):
|
||||
username = spawner.user.name # get the username
|
||||
volume_path = os.path.join('/user-data', username)
|
||||
@ -45,8 +48,12 @@ network_name = os.environ.get('JUPYTERHUB_NETWORK_NAME','laradock_backend')
|
||||
c.DockerSpawner.use_internal_ip = True
|
||||
c.DockerSpawner.network_name = network_name
|
||||
|
||||
enable_nvidia = os.environ.get('JUPYTERHUB_ENABLE_NVIDIA','false')
|
||||
# Pass the network name as argument to spawned containers
|
||||
c.DockerSpawner.extra_host_config = { 'network_mode': network_name, 'runtime': 'nvidia' }
|
||||
c.DockerSpawner.extra_host_config = { 'network_mode': network_name }
|
||||
if 'true' == enable_nvidia:
|
||||
c.DockerSpawner.extra_host_config = { 'network_mode': network_name, 'runtime': 'nvidia' }
|
||||
pass
|
||||
# c.DockerSpawner.extra_host_config = { 'network_mode': network_name, "devices":["/dev/nvidiactl","/dev/nvidia-uvm","/dev/nvidia0"] }
|
||||
# Explicitly set notebook directory because we'll be mounting a host volume to
|
||||
# it. Most jupyter/docker-stacks *-notebook images run the Notebook server as
|
||||
|
@ -1,3 +1,3 @@
|
||||
FROM docker.elastic.co/kibana/kibana:6.2.3
|
||||
FROM docker.elastic.co/kibana/kibana:6.6.0
|
||||
|
||||
EXPOSE 5601
|
||||
|
@ -19,4 +19,4 @@ RUN npm install
|
||||
COPY laravel-echo-server.json /usr/src/app/laravel-echo-server.json
|
||||
|
||||
EXPOSE 3000
|
||||
CMD [ "npm", "start" ]
|
||||
CMD [ "npm", "start", "--force" ]
|
||||
|
@ -4,9 +4,9 @@
|
||||
"version": "0.0.1",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"laravel-echo-server": "^1.2.8"
|
||||
"laravel-echo-server": "^1.5.0"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "laravel-echo-server start"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
108
laravel-horizon/Dockerfile
Normal file
108
laravel-horizon/Dockerfile
Normal file
@ -0,0 +1,108 @@
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Image Setup
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
|
||||
ARG PHP_VERSION=${PHP_VERSION}
|
||||
FROM php:${PHP_VERSION}-alpine
|
||||
|
||||
LABEL maintainer="Mahmoud Zalt <mahmoud@zalt.me>"
|
||||
|
||||
RUN apk --update add wget \
|
||||
curl \
|
||||
git \
|
||||
build-base \
|
||||
libmemcached-dev \
|
||||
libmcrypt-dev \
|
||||
libxml2-dev \
|
||||
zlib-dev \
|
||||
autoconf \
|
||||
cyrus-sasl-dev \
|
||||
libgsasl-dev \
|
||||
supervisor \
|
||||
procps
|
||||
|
||||
RUN docker-php-ext-install mysqli mbstring pdo pdo_mysql tokenizer xml pcntl
|
||||
RUN pecl channel-update pecl.php.net && pecl install memcached mcrypt-1.0.1 && docker-php-ext-enable memcached
|
||||
|
||||
#Install BCMath package:
|
||||
ARG INSTALL_BCMATH=false
|
||||
RUN if [ ${INSTALL_BCMATH} = true ]; then \
|
||||
docker-php-ext-install bcmath \
|
||||
;fi
|
||||
|
||||
# Install PostgreSQL drivers:
|
||||
ARG INSTALL_PGSQL=false
|
||||
RUN if [ ${INSTALL_PGSQL} = true ]; then \
|
||||
apk --update add postgresql-dev \
|
||||
&& docker-php-ext-install pdo_pgsql \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# PHP Memcached:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_MEMCACHED=false
|
||||
|
||||
RUN if [ ${INSTALL_MEMCACHED} = true ]; then \
|
||||
# Install the php memcached extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
curl -L -o /tmp/memcached.tar.gz "https://github.com/php-memcached-dev/php-memcached/archive/2.2.0.tar.gz"; \
|
||||
else \
|
||||
curl -L -o /tmp/memcached.tar.gz "https://github.com/php-memcached-dev/php-memcached/archive/php7.tar.gz"; \
|
||||
fi \
|
||||
&& mkdir -p memcached \
|
||||
&& tar -C memcached -zxvf /tmp/memcached.tar.gz --strip 1 \
|
||||
&& ( \
|
||||
cd memcached \
|
||||
&& phpize \
|
||||
&& ./configure \
|
||||
&& make -j$(nproc) \
|
||||
&& make install \
|
||||
) \
|
||||
&& rm -r memcached \
|
||||
&& rm /tmp/memcached.tar.gz \
|
||||
&& docker-php-ext-enable memcached \
|
||||
;fi
|
||||
|
||||
RUN rm /var/cache/apk/* \
|
||||
&& mkdir -p /var/www
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Optional Supervisord Configuration
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# Modify the ./supervisor.conf file to match your App's requirements.
|
||||
# Make sure you rebuild your container with every change.
|
||||
#
|
||||
|
||||
COPY supervisord.conf /etc/supervisord.conf
|
||||
|
||||
ENTRYPOINT ["/usr/bin/supervisord", "-n", "-c", "/etc/supervisord.conf"]
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Optional Software's Installation
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# If you need to modify this image, feel free to do it right here.
|
||||
#
|
||||
# -- Your awesome modifications go here -- #
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Check PHP version
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
|
||||
RUN php -v | head -n 1 | grep -q "PHP ${PHP_VERSION}."
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Final Touch
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
|
||||
WORKDIR /etc/supervisor/conf.d/
|
10
laravel-horizon/supervisord.conf
Normal file
10
laravel-horizon/supervisord.conf
Normal file
@ -0,0 +1,10 @@
|
||||
[supervisord]
|
||||
nodaemon=true
|
||||
[supervisorctl]
|
||||
[inet_http_server]
|
||||
port = 127.0.0.1:9001
|
||||
[rpcinterface:supervisor]
|
||||
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface
|
||||
|
||||
[include]
|
||||
files = supervisord.d/*.conf
|
1
laravel-horizon/supervisord.d/.gitignore
vendored
Normal file
1
laravel-horizon/supervisord.d/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
*.conf
|
@ -0,0 +1,6 @@
|
||||
[program:laravel-horizon]
|
||||
process_name=%(program_name)s_%(process_num)02d
|
||||
command=php /var/www/artisan horizon
|
||||
autostart=true
|
||||
autorestart=true
|
||||
redirect_stderr=true
|
10
logstash/Dockerfile
Normal file
10
logstash/Dockerfile
Normal file
@ -0,0 +1,10 @@
|
||||
FROM docker.elastic.co/logstash/logstash:6.4.2
|
||||
|
||||
USER root
|
||||
RUN rm -f /usr/share/logstash/pipeline/logstash.conf
|
||||
RUN curl -L -o /usr/share/logstash/lib/mysql-connector-java-5.1.47.jar https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.47/mysql-connector-java-5.1.47.jar
|
||||
ADD ./pipeline/ /usr/share/logstash/pipeline/
|
||||
ADD ./config/ /usr/share/logstash/config/
|
||||
|
||||
RUN logstash-plugin install logstash-input-jdbc
|
||||
|
5
logstash/config/logstash.yml
Normal file
5
logstash/config/logstash.yml
Normal file
@ -0,0 +1,5 @@
|
||||
http.host: "0.0.0.0"
|
||||
|
||||
xpack.monitoring.enabled: false
|
||||
config.reload.automatic: true
|
||||
path.config: "/usr/share/logstash/pipeline"
|
5
manticore/Dockerfile
Normal file
5
manticore/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
||||
FROM manticoresearch/manticore
|
||||
|
||||
EXPOSE 9306
|
||||
EXPOSE 9308
|
||||
EXPOSE 9312
|
25
manticore/config/sphinx.conf
Normal file
25
manticore/config/sphinx.conf
Normal file
@ -0,0 +1,25 @@
|
||||
index testrt {
|
||||
type = rt
|
||||
rt_mem_limit = 128M
|
||||
path = /var/lib/manticore/data/testrt
|
||||
rt_field = title
|
||||
rt_field = content
|
||||
rt_attr_uint = gid
|
||||
}
|
||||
|
||||
searchd {
|
||||
listen = 9312
|
||||
listen = 9308:http
|
||||
listen = 9306:mysql41
|
||||
log = /var/lib/manticore/log/searchd.log
|
||||
# you can also send query_log to /dev/stdout to be shown in docker logs
|
||||
query_log = /var/lib/manticore/log/query.log
|
||||
read_timeout = 5
|
||||
max_children = 30
|
||||
pid_file = /var/run/searchd.pid
|
||||
seamless_rotate = 1
|
||||
preopen_indexes = 1
|
||||
unlink_old = 1
|
||||
binlog_path = /var/lib/manticore/data
|
||||
}
|
||||
|
5
mosquitto/Dockerfile
Normal file
5
mosquitto/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
||||
FROM eclipse-mosquitto:latest
|
||||
|
||||
LABEL maintainer="Luis Coutinho <luis@luiscoutinho.pt>"
|
||||
|
||||
COPY mosquitto.conf /mosquitto/config/
|
838
mosquitto/mosquitto.conf
Normal file
838
mosquitto/mosquitto.conf
Normal file
@ -0,0 +1,838 @@
|
||||
# Config file for mosquitto
|
||||
#
|
||||
# See mosquitto.conf(5) for more information.
|
||||
#
|
||||
# Default values are shown, uncomment to change.
|
||||
#
|
||||
# Use the # character to indicate a comment, but only if it is the
|
||||
# very first character on the line.
|
||||
|
||||
# =================================================================
|
||||
# General configuration
|
||||
# =================================================================
|
||||
|
||||
# Time in seconds to wait before resending an outgoing QoS=1 or
|
||||
# QoS=2 message.
|
||||
#retry_interval 20
|
||||
|
||||
# Time in seconds between updates of the $SYS tree.
|
||||
# Set to 0 to disable the publishing of the $SYS tree.
|
||||
#sys_interval 10
|
||||
|
||||
# Time in seconds between cleaning the internal message store of
|
||||
# unreferenced messages. Lower values will result in lower memory
|
||||
# usage but more processor time, higher values will have the
|
||||
# opposite effect.
|
||||
# Setting a value of 0 means the unreferenced messages will be
|
||||
# disposed of as quickly as possible.
|
||||
#store_clean_interval 10
|
||||
|
||||
# Write process id to a file. Default is a blank string which means
|
||||
# a pid file shouldn't be written.
|
||||
# This should be set to /var/run/mosquitto.pid if mosquitto is
|
||||
# being run automatically on boot with an init script and
|
||||
# start-stop-daemon or similar.
|
||||
#pid_file
|
||||
|
||||
# When run as root, drop privileges to this user and its primary
|
||||
# group.
|
||||
# Leave blank to stay as root, but this is not recommended.
|
||||
# If run as a non-root user, this setting has no effect.
|
||||
# Note that on Windows this has no effect and so mosquitto should
|
||||
# be started by the user you wish it to run as.
|
||||
#user mosquitto
|
||||
|
||||
# The maximum number of QoS 1 and 2 messages currently inflight per
|
||||
# client.
|
||||
# This includes messages that are partway through handshakes and
|
||||
# those that are being retried. Defaults to 20. Set to 0 for no
|
||||
# maximum. Setting to 1 will guarantee in-order delivery of QoS 1
|
||||
# and 2 messages.
|
||||
#max_inflight_messages 20
|
||||
|
||||
# The maximum number of QoS 1 and 2 messages to hold in a queue
|
||||
# above those that are currently in-flight. Defaults to 100. Set
|
||||
# to 0 for no maximum (not recommended).
|
||||
# See also queue_qos0_messages.
|
||||
#max_queued_messages 100
|
||||
|
||||
# Set to true to queue messages with QoS 0 when a persistent client is
|
||||
# disconnected. These messages are included in the limit imposed by
|
||||
# max_queued_messages.
|
||||
# Defaults to false.
|
||||
# This is a non-standard option for the MQTT v3.1 spec but is allowed in
|
||||
# v3.1.1.
|
||||
#queue_qos0_messages false
|
||||
|
||||
# This option sets the maximum publish payload size that the broker will allow.
|
||||
# Received messages that exceed this size will not be accepted by the broker.
|
||||
# The default value is 0, which means that all valid MQTT messages are
|
||||
# accepted. MQTT imposes a maximum payload size of 268435455 bytes.
|
||||
#message_size_limit 0
|
||||
|
||||
# This option controls whether a client is allowed to connect with a zero
|
||||
# length client id or not. This option only affects clients using MQTT v3.1.1
|
||||
# and later. If set to false, clients connecting with a zero length client id
|
||||
# are disconnected. If set to true, clients will be allocated a client id by
|
||||
# the broker. This means it is only useful for clients with clean session set
|
||||
# to true.
|
||||
#allow_zero_length_clientid true
|
||||
|
||||
# If allow_zero_length_clientid is true, this option allows you to set a prefix
|
||||
# to automatically generated client ids to aid visibility in logs.
|
||||
#auto_id_prefix
|
||||
|
||||
# This option allows persistent clients (those with clean session set to false)
|
||||
# to be removed if they do not reconnect within a certain time frame.
|
||||
#
|
||||
# This is a non-standard option in MQTT V3.1 but allowed in MQTT v3.1.1.
|
||||
#
|
||||
# Badly designed clients may set clean session to false whilst using a randomly
|
||||
# generated client id. This leads to persistent clients that will never
|
||||
# reconnect. This option allows these clients to be removed.
|
||||
#
|
||||
# The expiration period should be an integer followed by one of h d w m y for
|
||||
# hour, day, week, month and year respectively. For example
|
||||
#
|
||||
# persistent_client_expiration 2m
|
||||
# persistent_client_expiration 14d
|
||||
# persistent_client_expiration 1y
|
||||
#
|
||||
# The default if not set is to never expire persistent clients.
|
||||
#persistent_client_expiration
|
||||
|
||||
# If a client is subscribed to multiple subscriptions that overlap, e.g. foo/#
|
||||
# and foo/+/baz , then MQTT expects that when the broker receives a message on
|
||||
# a topic that matches both subscriptions, such as foo/bar/baz, then the client
|
||||
# should only receive the message once.
|
||||
# Mosquitto keeps track of which clients a message has been sent to in order to
|
||||
# meet this requirement. The allow_duplicate_messages option allows this
|
||||
# behaviour to be disabled, which may be useful if you have a large number of
|
||||
# clients subscribed to the same set of topics and are very concerned about
|
||||
# minimising memory usage.
|
||||
# It can be safely set to true if you know in advance that your clients will
|
||||
# never have overlapping subscriptions, otherwise your clients must be able to
|
||||
# correctly deal with duplicate messages even when then have QoS=2.
|
||||
#allow_duplicate_messages false
|
||||
|
||||
# The MQTT specification requires that the QoS of a message delivered to a
|
||||
# subscriber is never upgraded to match the QoS of the subscription. Enabling
|
||||
# this option changes this behaviour. If upgrade_outgoing_qos is set true,
|
||||
# messages sent to a subscriber will always match the QoS of its subscription.
|
||||
# This is a non-standard option explicitly disallowed by the spec.
|
||||
#upgrade_outgoing_qos false
|
||||
|
||||
# =================================================================
|
||||
# Default listener
|
||||
# =================================================================
|
||||
|
||||
# IP address/hostname to bind the default listener to. If not
|
||||
# given, the default listener will not be bound to a specific
|
||||
# address and so will be accessible to all network interfaces.
|
||||
# bind_address ip-address/host name
|
||||
#bind_address
|
||||
|
||||
# Port to use for the default listener.
|
||||
port 9001
|
||||
|
||||
# The maximum number of client connections to allow. This is
|
||||
# a per listener setting.
|
||||
# Default is -1, which means unlimited connections.
|
||||
# Note that other process limits mean that unlimited connections
|
||||
# are not really possible. Typically the default maximum number of
|
||||
# connections possible is around 1024.
|
||||
#max_connections -1
|
||||
|
||||
# Choose the protocol to use when listening.
|
||||
# This can be either mqtt or websockets.
|
||||
# Websockets support is currently disabled by default at compile time.
|
||||
# Certificate based TLS may be used with websockets, except that
|
||||
# only the cafile, certfile, keyfile and ciphers options are supported.
|
||||
protocol websockets
|
||||
|
||||
# When a listener is using the websockets protocol, it is possible to serve
|
||||
# http data as well. Set http_dir to a directory which contains the files you
|
||||
# wish to serve. If this option is not specified, then no normal http
|
||||
# connections will be possible.
|
||||
#http_dir
|
||||
|
||||
# Set use_username_as_clientid to true to replace the clientid that a client
|
||||
# connected with with its username. This allows authentication to be tied to
|
||||
# the clientid, which means that it is possible to prevent one client
|
||||
# disconnecting another by using the same clientid.
|
||||
# If a client connects with no username it will be disconnected as not
|
||||
# authorised when this option is set to true.
|
||||
# Do not use in conjunction with clientid_prefixes.
|
||||
# See also use_identity_as_username.
|
||||
#use_username_as_clientid
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Certificate based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# The following options can be used to enable SSL/TLS support for
|
||||
# this listener. Note that the recommended port for MQTT over TLS
|
||||
# is 8883, but this must be set manually.
|
||||
#
|
||||
# See also the mosquitto-tls man page.
|
||||
|
||||
# At least one of cafile or capath must be defined. They both
|
||||
# define methods of accessing the PEM encoded Certificate
|
||||
# Authority certificates that have signed your server certificate
|
||||
# and that you wish to trust.
|
||||
# cafile defines the path to a file containing the CA certificates.
|
||||
# capath defines a directory that will be searched for files
|
||||
# containing the CA certificates. For capath to work correctly, the
|
||||
# certificate files must have ".crt" as the file ending and you must run
|
||||
# "c_rehash <path to capath>" each time you add/remove a certificate.
|
||||
#cafile
|
||||
#capath
|
||||
|
||||
# Path to the PEM encoded server certificate.
|
||||
#certfile
|
||||
|
||||
# Path to the PEM encoded keyfile.
|
||||
#keyfile
|
||||
|
||||
# This option defines the version of the TLS protocol to use for this listener.
|
||||
# The default value allows v1.2, v1.1 and v1.0, if they are all supported by
|
||||
# the version of openssl that the broker was compiled against. For openssl >=
|
||||
# 1.0.1 the valid values are tlsv1.2 tlsv1.1 and tlsv1. For openssl < 1.0.1 the
|
||||
# valid values are tlsv1.
|
||||
#tls_version
|
||||
|
||||
# By default a TLS enabled listener will operate in a similar fashion to a
|
||||
# https enabled web server, in that the server has a certificate signed by a CA
|
||||
# and the client will verify that it is a trusted certificate. The overall aim
|
||||
# is encryption of the network traffic. By setting require_certificate to true,
|
||||
# the client must provide a valid certificate in order for the network
|
||||
# connection to proceed. This allows access to the broker to be controlled
|
||||
# outside of the mechanisms provided by MQTT.
|
||||
#require_certificate false
|
||||
|
||||
# If require_certificate is true, you may set use_identity_as_username to true
|
||||
# to use the CN value from the client certificate as a username. If this is
|
||||
# true, the password_file option will not be used for this listener.
|
||||
#use_identity_as_username false
|
||||
|
||||
# If you have require_certificate set to true, you can create a certificate
|
||||
# revocation list file to revoke access to particular client certificates. If
|
||||
# you have done this, use crlfile to point to the PEM encoded revocation file.
|
||||
#crlfile
|
||||
|
||||
# If you wish to control which encryption ciphers are used, use the ciphers
|
||||
# option. The list of available ciphers can be optained using the "openssl
|
||||
# ciphers" command and should be provided in the same format as the output of
|
||||
# that command.
|
||||
# If unset defaults to DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:@STRENGTH
|
||||
#ciphers DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:@STRENGTH
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Pre-shared-key based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# The following options can be used to enable PSK based SSL/TLS support for
|
||||
# this listener. Note that the recommended port for MQTT over TLS is 8883, but
|
||||
# this must be set manually.
|
||||
#
|
||||
# See also the mosquitto-tls man page and the "Certificate based SSL/TLS
|
||||
# support" section. Only one of certificate or PSK encryption support can be
|
||||
# enabled for any listener.
|
||||
|
||||
# The psk_hint option enables pre-shared-key support for this listener and also
|
||||
# acts as an identifier for this listener. The hint is sent to clients and may
|
||||
# be used locally to aid authentication. The hint is a free form string that
|
||||
# doesn't have much meaning in itself, so feel free to be creative.
|
||||
# If this option is provided, see psk_file to define the pre-shared keys to be
|
||||
# used or create a security plugin to handle them.
|
||||
#psk_hint
|
||||
|
||||
# Set use_identity_as_username to have the psk identity sent by the client used
|
||||
# as its username. Authentication will be carried out using the PSK rather than
|
||||
# the MQTT username/password and so password_file will not be used for this
|
||||
# listener.
|
||||
#use_identity_as_username false
|
||||
|
||||
# When using PSK, the encryption ciphers used will be chosen from the list of
|
||||
# available PSK ciphers. If you want to control which ciphers are available,
|
||||
# use the "ciphers" option. The list of available ciphers can be optained
|
||||
# using the "openssl ciphers" command and should be provided in the same format
|
||||
# as the output of that command.
|
||||
#ciphers
|
||||
|
||||
# =================================================================
|
||||
# Extra listeners
|
||||
# =================================================================
|
||||
|
||||
# Listen on a port/ip address combination. By using this variable
|
||||
# multiple times, mosquitto can listen on more than one port. If
|
||||
# this variable is used and neither bind_address nor port given,
|
||||
# then the default listener will not be started.
|
||||
# The port number to listen on must be given. Optionally, an ip
|
||||
# address or host name may be supplied as a second argument. In
|
||||
# this case, mosquitto will attempt to bind the listener to that
|
||||
# address and so restrict access to the associated network and
|
||||
# interface. By default, mosquitto will listen on all interfaces.
|
||||
# Note that for a websockets listener it is not possible to bind to a host
|
||||
# name.
|
||||
# listener port-number [ip address/host name]
|
||||
#listener
|
||||
|
||||
# The maximum number of client connections to allow. This is
|
||||
# a per listener setting.
|
||||
# Default is -1, which means unlimited connections.
|
||||
# Note that other process limits mean that unlimited connections
|
||||
# are not really possible. Typically the default maximum number of
|
||||
# connections possible is around 1024.
|
||||
#max_connections -1
|
||||
|
||||
# The listener can be restricted to operating within a topic hierarchy using
|
||||
# the mount_point option. This is achieved be prefixing the mount_point string
|
||||
# to all topics for any clients connected to this listener. This prefixing only
|
||||
# happens internally to the broker; the client will not see the prefix.
|
||||
#mount_point
|
||||
|
||||
# Choose the protocol to use when listening.
|
||||
# This can be either mqtt or websockets.
|
||||
# Certificate based TLS may be used with websockets, except that only the
|
||||
# cafile, certfile, keyfile and ciphers options are supported.
|
||||
#protocol mqtt
|
||||
|
||||
# When a listener is using the websockets protocol, it is possible to serve
|
||||
# http data as well. Set http_dir to a directory which contains the files you
|
||||
# wish to serve. If this option is not specified, then no normal http
|
||||
# connections will be possible.
|
||||
#http_dir
|
||||
|
||||
# Set use_username_as_clientid to true to replace the clientid that a client
|
||||
# connected with with its username. This allows authentication to be tied to
|
||||
# the clientid, which means that it is possible to prevent one client
|
||||
# disconnecting another by using the same clientid.
|
||||
# If a client connects with no username it will be disconnected as not
|
||||
# authorised when this option is set to true.
|
||||
# Do not use in conjunction with clientid_prefixes.
|
||||
# See also use_identity_as_username.
|
||||
#use_username_as_clientid
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Certificate based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# The following options can be used to enable certificate based SSL/TLS support
|
||||
# for this listener. Note that the recommended port for MQTT over TLS is 8883,
|
||||
# but this must be set manually.
|
||||
#
|
||||
# See also the mosquitto-tls man page and the "Pre-shared-key based SSL/TLS
|
||||
# support" section. Only one of certificate or PSK encryption support can be
|
||||
# enabled for any listener.
|
||||
|
||||
# At least one of cafile or capath must be defined to enable certificate based
|
||||
# TLS encryption. They both define methods of accessing the PEM encoded
|
||||
# Certificate Authority certificates that have signed your server certificate
|
||||
# and that you wish to trust.
|
||||
# cafile defines the path to a file containing the CA certificates.
|
||||
# capath defines a directory that will be searched for files
|
||||
# containing the CA certificates. For capath to work correctly, the
|
||||
# certificate files must have ".crt" as the file ending and you must run
|
||||
# "c_rehash <path to capath>" each time you add/remove a certificate.
|
||||
#cafile
|
||||
#capath
|
||||
|
||||
# Path to the PEM encoded server certificate.
|
||||
#certfile
|
||||
|
||||
# Path to the PEM encoded keyfile.
|
||||
#keyfile
|
||||
|
||||
# By default an TLS enabled listener will operate in a similar fashion to a
|
||||
# https enabled web server, in that the server has a certificate signed by a CA
|
||||
# and the client will verify that it is a trusted certificate. The overall aim
|
||||
# is encryption of the network traffic. By setting require_certificate to true,
|
||||
# the client must provide a valid certificate in order for the network
|
||||
# connection to proceed. This allows access to the broker to be controlled
|
||||
# outside of the mechanisms provided by MQTT.
|
||||
#require_certificate false
|
||||
|
||||
# If require_certificate is true, you may set use_identity_as_username to true
|
||||
# to use the CN value from the client certificate as a username. If this is
|
||||
# true, the password_file option will not be used for this listener.
|
||||
#use_identity_as_username false
|
||||
|
||||
# If you have require_certificate set to true, you can create a certificate
|
||||
# revocation list file to revoke access to particular client certificates. If
|
||||
# you have done this, use crlfile to point to the PEM encoded revocation file.
|
||||
#crlfile
|
||||
|
||||
# If you wish to control which encryption ciphers are used, use the ciphers
|
||||
# option. The list of available ciphers can be optained using the "openssl
|
||||
# ciphers" command and should be provided in the same format as the output of
|
||||
# that command.
|
||||
#ciphers
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Pre-shared-key based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# The following options can be used to enable PSK based SSL/TLS support for
|
||||
# this listener. Note that the recommended port for MQTT over TLS is 8883, but
|
||||
# this must be set manually.
|
||||
#
|
||||
# See also the mosquitto-tls man page and the "Certificate based SSL/TLS
|
||||
# support" section. Only one of certificate or PSK encryption support can be
|
||||
# enabled for any listener.
|
||||
|
||||
# The psk_hint option enables pre-shared-key support for this listener and also
|
||||
# acts as an identifier for this listener. The hint is sent to clients and may
|
||||
# be used locally to aid authentication. The hint is a free form string that
|
||||
# doesn't have much meaning in itself, so feel free to be creative.
|
||||
# If this option is provided, see psk_file to define the pre-shared keys to be
|
||||
# used or create a security plugin to handle them.
|
||||
#psk_hint
|
||||
|
||||
# Set use_identity_as_username to have the psk identity sent by the client used
|
||||
# as its username. Authentication will be carried out using the PSK rather than
|
||||
# the MQTT username/password and so password_file will not be used for this
|
||||
# listener.
|
||||
#use_identity_as_username false
|
||||
|
||||
# When using PSK, the encryption ciphers used will be chosen from the list of
|
||||
# available PSK ciphers. If you want to control which ciphers are available,
|
||||
# use the "ciphers" option. The list of available ciphers can be optained
|
||||
# using the "openssl ciphers" command and should be provided in the same format
|
||||
# as the output of that command.
|
||||
#ciphers
|
||||
|
||||
# =================================================================
|
||||
# Persistence
|
||||
# =================================================================
|
||||
|
||||
# If persistence is enabled, save the in-memory database to disk
|
||||
# every autosave_interval seconds. If set to 0, the persistence
|
||||
# database will only be written when mosquitto exits. See also
|
||||
# autosave_on_changes.
|
||||
# Note that writing of the persistence database can be forced by
|
||||
# sending mosquitto a SIGUSR1 signal.
|
||||
#autosave_interval 1800
|
||||
|
||||
# If true, mosquitto will count the number of subscription changes, retained
|
||||
# messages received and queued messages and if the total exceeds
|
||||
# autosave_interval then the in-memory database will be saved to disk.
|
||||
# If false, mosquitto will save the in-memory database to disk by treating
|
||||
# autosave_interval as a time in seconds.
|
||||
#autosave_on_changes false
|
||||
|
||||
# Save persistent message data to disk (true/false).
|
||||
# This saves information about all messages, including
|
||||
# subscriptions, currently in-flight messages and retained
|
||||
# messages.
|
||||
# retained_persistence is a synonym for this option.
|
||||
persistence true
|
||||
|
||||
# The filename to use for the persistent database, not including
|
||||
# the path.
|
||||
#persistence_file mosquitto.db
|
||||
|
||||
# Location for persistent database. Must include trailing /
|
||||
# Default is an empty string (current directory).
|
||||
# Set to e.g. /var/lib/mosquitto/ if running as a proper service on Linux or
|
||||
# similar.
|
||||
persistence_location /mosquitto/data/
|
||||
|
||||
# =================================================================
|
||||
# Logging
|
||||
# =================================================================
|
||||
|
||||
# Places to log to. Use multiple log_dest lines for multiple
|
||||
# logging destinations.
|
||||
# Possible destinations are: stdout stderr syslog topic file
|
||||
#
|
||||
# stdout and stderr log to the console on the named output.
|
||||
#
|
||||
# syslog uses the userspace syslog facility which usually ends up
|
||||
# in /var/log/messages or similar.
|
||||
#
|
||||
# topic logs to the broker topic '$SYS/broker/log/<severity>',
|
||||
# where severity is one of D, E, W, N, I, M which are debug, error,
|
||||
# warning, notice, information and message. Message type severity is used by
|
||||
# the subscribe/unsubscribe log_types and publishes log messages to
|
||||
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe.
|
||||
#
|
||||
# The file destination requires an additional parameter which is the file to be
|
||||
# logged to, e.g. "log_dest file /var/log/mosquitto.log". The file will be
|
||||
# closed and reopened when the broker receives a HUP signal. Only a single file
|
||||
# destination may be configured.
|
||||
#
|
||||
# Note that if the broker is running as a Windows service it will default to
|
||||
# "log_dest none" and neither stdout nor stderr logging is available.
|
||||
# Use "log_dest none" if you wish to disable logging.
|
||||
log_dest file /mosquitto/log/mosquitto.log
|
||||
|
||||
# If using syslog logging (not on Windows), messages will be logged to the
|
||||
# "daemon" facility by default. Use the log_facility option to choose which of
|
||||
# local0 to local7 to log to instead. The option value should be an integer
|
||||
# value, e.g. "log_facility 5" to use local5.
|
||||
#log_facility
|
||||
|
||||
# Types of messages to log. Use multiple log_type lines for logging
|
||||
# multiple types of messages.
|
||||
# Possible types are: debug, error, warning, notice, information,
|
||||
# none, subscribe, unsubscribe, websockets, all.
|
||||
# Note that debug type messages are for decoding the incoming/outgoing
|
||||
# network packets. They are not logged in "topics".
|
||||
log_type error
|
||||
log_type warning
|
||||
log_type notice
|
||||
log_type information
|
||||
log_type all
|
||||
|
||||
# Change the websockets logging level. This is a global option, it is not
|
||||
# possible to set per listener. This is an integer that is interpreted by
|
||||
# libwebsockets as a bit mask for its lws_log_levels enum. See the
|
||||
# libwebsockets documentation for more details. "log_type websockets" must also
|
||||
# be enabled.
|
||||
#websockets_log_level 0
|
||||
|
||||
# If set to true, client connection and disconnection messages will be included
|
||||
# in the log.
|
||||
#connection_messages true
|
||||
|
||||
# If set to true, add a timestamp value to each log message.
|
||||
#log_timestamp true
|
||||
|
||||
# =================================================================
|
||||
# Security
|
||||
# =================================================================
|
||||
|
||||
# If set, only clients that have a matching prefix on their
|
||||
# clientid will be allowed to connect to the broker. By default,
|
||||
# all clients may connect.
|
||||
# For example, setting "secure-" here would mean a client "secure-
|
||||
# client" could connect but another with clientid "mqtt" couldn't.
|
||||
#clientid_prefixes
|
||||
|
||||
# Boolean value that determines whether clients that connect
|
||||
# without providing a username are allowed to connect. If set to
|
||||
# false then a password file should be created (see the
|
||||
# password_file option) to control authenticated client access.
|
||||
# Defaults to true.
|
||||
#allow_anonymous true
|
||||
|
||||
# In addition to the clientid_prefixes, allow_anonymous and TLS
|
||||
# authentication options, username based authentication is also
|
||||
# possible. The default support is described in "Default
|
||||
# authentication and topic access control" below. The auth_plugin
|
||||
# allows another authentication method to be used.
|
||||
# Specify the path to the loadable plugin and see the
|
||||
# "Authentication and topic access plugin options" section below.
|
||||
#auth_plugin
|
||||
|
||||
# If auth_plugin_deny_special_chars is true, the default, then before an ACL
|
||||
# check is made, the username/client id of the client needing the check is
|
||||
# searched for the presence of either a '+' or '#' character. If either of
|
||||
# these characters is found in either the username or client id, then the ACL
|
||||
# check is denied before it is sent to the plugin.o
|
||||
#
|
||||
# This check prevents the case where a malicious user could circumvent an ACL
|
||||
# check by using one of these characters as their username or client id. This
|
||||
# is the same issue as was reported with mosquitto itself as CVE-2017-7650.
|
||||
#
|
||||
# If you are entirely sure that the plugin you are using is not vulnerable to
|
||||
# this attack (i.e. if you never use usernames or client ids in topics) then
|
||||
# you can disable this extra check and have all ACL checks delivered to your
|
||||
# plugin by setting auth_plugin_deny_special_chars to false.
|
||||
#auth_plugin_deny_special_chars true
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Default authentication and topic access control
|
||||
# -----------------------------------------------------------------
|
||||
|
||||
# Control access to the broker using a password file. This file can be
|
||||
# generated using the mosquitto_passwd utility. If TLS support is not compiled
|
||||
# into mosquitto (it is recommended that TLS support should be included) then
|
||||
# plain text passwords are used, in which case the file should be a text file
|
||||
# with lines in the format:
|
||||
# username:password
|
||||
# The password (and colon) may be omitted if desired, although this
|
||||
# offers very little in the way of security.
|
||||
#
|
||||
# See the TLS client require_certificate and use_identity_as_username options
|
||||
# for alternative authentication options.
|
||||
#password_file
|
||||
|
||||
# Access may also be controlled using a pre-shared-key file. This requires
|
||||
# TLS-PSK support and a listener configured to use it. The file should be text
|
||||
# lines in the format:
|
||||
# identity:key
|
||||
# The key should be in hexadecimal format without a leading "0x".
|
||||
#psk_file
|
||||
|
||||
# Control access to topics on the broker using an access control list
|
||||
# file. If this parameter is defined then only the topics listed will
|
||||
# have access.
|
||||
# If the first character of a line of the ACL file is a # it is treated as a
|
||||
# comment.
|
||||
# Topic access is added with lines of the format:
|
||||
#
|
||||
# topic [read|write|readwrite] <topic>
|
||||
#
|
||||
# The access type is controlled using "read", "write" or "readwrite". This
|
||||
# parameter is optional (unless <topic> contains a space character) - if not
|
||||
# given then the access is read/write. <topic> can contain the + or #
|
||||
# wildcards as in subscriptions.
|
||||
#
|
||||
# The first set of topics are applied to anonymous clients, assuming
|
||||
# allow_anonymous is true. User specific topic ACLs are added after a
|
||||
# user line as follows:
|
||||
#
|
||||
# user <username>
|
||||
#
|
||||
# The username referred to here is the same as in password_file. It is
|
||||
# not the clientid.
|
||||
#
|
||||
#
|
||||
# If is also possible to define ACLs based on pattern substitution within the
|
||||
# topic. The patterns available for substition are:
|
||||
#
|
||||
# %c to match the client id of the client
|
||||
# %u to match the username of the client
|
||||
#
|
||||
# The substitution pattern must be the only text for that level of hierarchy.
|
||||
#
|
||||
# The form is the same as for the topic keyword, but using pattern as the
|
||||
# keyword.
|
||||
# Pattern ACLs apply to all users even if the "user" keyword has previously
|
||||
# been given.
|
||||
#
|
||||
# If using bridges with usernames and ACLs, connection messages can be allowed
|
||||
# with the following pattern:
|
||||
# pattern write $SYS/broker/connection/%c/state
|
||||
#
|
||||
# pattern [read|write|readwrite] <topic>
|
||||
#
|
||||
# Example:
|
||||
#
|
||||
# pattern write sensor/%u/data
|
||||
#
|
||||
#acl_file
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Authentication and topic access plugin options
|
||||
# -----------------------------------------------------------------
|
||||
|
||||
# If the auth_plugin option above is used, define options to pass to the
|
||||
# plugin here as described by the plugin instructions. All options named
|
||||
# using the format auth_opt_* will be passed to the plugin, for example:
|
||||
#
|
||||
# auth_opt_db_host
|
||||
# auth_opt_db_port
|
||||
# auth_opt_db_username
|
||||
# auth_opt_db_password
|
||||
|
||||
|
||||
# =================================================================
|
||||
# Bridges
|
||||
# =================================================================
|
||||
|
||||
# A bridge is a way of connecting multiple MQTT brokers together.
|
||||
# Create a new bridge using the "connection" option as described below. Set
|
||||
# options for the bridges using the remaining parameters. You must specify the
|
||||
# address and at least one topic to subscribe to.
|
||||
# Each connection must have a unique name.
|
||||
# The address line may have multiple host address and ports specified. See
|
||||
# below in the round_robin description for more details on bridge behaviour if
|
||||
# multiple addresses are used.
|
||||
# The direction that the topic will be shared can be chosen by
|
||||
# specifying out, in or both, where the default value is out.
|
||||
# The QoS level of the bridged communication can be specified with the next
|
||||
# topic option. The default QoS level is 0, to change the QoS the topic
|
||||
# direction must also be given.
|
||||
# The local and remote prefix options allow a topic to be remapped when it is
|
||||
# bridged to/from the remote broker. This provides the ability to place a topic
|
||||
# tree in an appropriate location.
|
||||
# For more details see the mosquitto.conf man page.
|
||||
# Multiple topics can be specified per connection, but be careful
|
||||
# not to create any loops.
|
||||
# If you are using bridges with cleansession set to false (the default), then
|
||||
# you may get unexpected behaviour from incoming topics if you change what
|
||||
# topics you are subscribing to. This is because the remote broker keeps the
|
||||
# subscription for the old topic. If you have this problem, connect your bridge
|
||||
# with cleansession set to true, then reconnect with cleansession set to false
|
||||
# as normal.
|
||||
#connection <name>
|
||||
#address <host>[:<port>] [<host>[:<port>]]
|
||||
#topic <topic> [[[out | in | both] qos-level] local-prefix remote-prefix]
|
||||
|
||||
# Set the version of the MQTT protocol to use with for this bridge. Can be one
|
||||
# of mqttv31 or mqttv311. Defaults to mqttv31.
|
||||
#bridge_protocol_version mqttv31
|
||||
|
||||
# If a bridge has topics that have "out" direction, the default behaviour is to
|
||||
# send an unsubscribe request to the remote broker on that topic. This means
|
||||
# that changing a topic direction from "in" to "out" will not keep receiving
|
||||
# incoming messages. Sending these unsubscribe requests is not always
|
||||
# desirable, setting bridge_attempt_unsubscribe to false will disable sending
|
||||
# the unsubscribe request.
|
||||
#bridge_attempt_unsubscribe true
|
||||
|
||||
# If the bridge has more than one address given in the address/addresses
|
||||
# configuration, the round_robin option defines the behaviour of the bridge on
|
||||
# a failure of the bridge connection. If round_robin is false, the default
|
||||
# value, then the first address is treated as the main bridge connection. If
|
||||
# the connection fails, the other secondary addresses will be attempted in
|
||||
# turn. Whilst connected to a secondary bridge, the bridge will periodically
|
||||
# attempt to reconnect to the main bridge until successful.
|
||||
# If round_robin is true, then all addresses are treated as equals. If a
|
||||
# connection fails, the next address will be tried and if successful will
|
||||
# remain connected until it fails
|
||||
#round_robin false
|
||||
|
||||
# Set the client id to use on the remote end of this bridge connection. If not
|
||||
# defined, this defaults to 'name.hostname' where name is the connection name
|
||||
# and hostname is the hostname of this computer.
|
||||
# This replaces the old "clientid" option to avoid confusion. "clientid"
|
||||
# remains valid for the time being.
|
||||
#remote_clientid
|
||||
|
||||
# Set the clientid to use on the local broker. If not defined, this defaults to
|
||||
# 'local.<clientid>'. If you are bridging a broker to itself, it is important
|
||||
# that local_clientid and clientid do not match.
|
||||
#local_clientid
|
||||
|
||||
# Set the clean session variable for this bridge.
|
||||
# When set to true, when the bridge disconnects for any reason, all
|
||||
# messages and subscriptions will be cleaned up on the remote
|
||||
# broker. Note that with cleansession set to true, there may be a
|
||||
# significant amount of retained messages sent when the bridge
|
||||
# reconnects after losing its connection.
|
||||
# When set to false, the subscriptions and messages are kept on the
|
||||
# remote broker, and delivered when the bridge reconnects.
|
||||
#cleansession false
|
||||
|
||||
# If set to true, publish notification messages to the local and remote brokers
|
||||
# giving information about the state of the bridge connection. Retained
|
||||
# messages are published to the topic $SYS/broker/connection/<clientid>/state
|
||||
# unless the notification_topic option is used.
|
||||
# If the message is 1 then the connection is active, or 0 if the connection has
|
||||
# failed.
|
||||
#notifications true
|
||||
|
||||
# Choose the topic on which notification messages for this bridge are
|
||||
# published. If not set, messages are published on the topic
|
||||
# $SYS/broker/connection/<clientid>/state
|
||||
#notification_topic
|
||||
|
||||
# Set the keepalive interval for this bridge connection, in
|
||||
# seconds.
|
||||
#keepalive_interval 60
|
||||
|
||||
# Set the start type of the bridge. This controls how the bridge starts and
|
||||
# can be one of three types: automatic, lazy and once. Note that RSMB provides
|
||||
# a fourth start type "manual" which isn't currently supported by mosquitto.
|
||||
#
|
||||
# "automatic" is the default start type and means that the bridge connection
|
||||
# will be started automatically when the broker starts and also restarted
|
||||
# after a short delay (30 seconds) if the connection fails.
|
||||
#
|
||||
# Bridges using the "lazy" start type will be started automatically when the
|
||||
# number of queued messages exceeds the number set with the "threshold"
|
||||
# parameter. It will be stopped automatically after the time set by the
|
||||
# "idle_timeout" parameter. Use this start type if you wish the connection to
|
||||
# only be active when it is needed.
|
||||
#
|
||||
# A bridge using the "once" start type will be started automatically when the
|
||||
# broker starts but will not be restarted if the connection fails.
|
||||
#start_type automatic
|
||||
|
||||
# Set the amount of time a bridge using the automatic start type will wait
|
||||
# until attempting to reconnect. Defaults to 30 seconds.
|
||||
#restart_timeout 30
|
||||
|
||||
# Set the amount of time a bridge using the lazy start type must be idle before
|
||||
# it will be stopped. Defaults to 60 seconds.
|
||||
#idle_timeout 60
|
||||
|
||||
# Set the number of messages that need to be queued for a bridge with lazy
|
||||
# start type to be restarted. Defaults to 10 messages.
|
||||
# Must be less than max_queued_messages.
|
||||
#threshold 10
|
||||
|
||||
# If try_private is set to true, the bridge will attempt to indicate to the
|
||||
# remote broker that it is a bridge not an ordinary client. If successful, this
|
||||
# means that loop detection will be more effective and that retained messages
|
||||
# will be propagated correctly. Not all brokers support this feature so it may
|
||||
# be necessary to set try_private to false if your bridge does not connect
|
||||
# properly.
|
||||
#try_private true
|
||||
|
||||
# Set the username to use when connecting to a broker that requires
|
||||
# authentication.
|
||||
# This replaces the old "username" option to avoid confusion. "username"
|
||||
# remains valid for the time being.
|
||||
#remote_username
|
||||
|
||||
# Set the password to use when connecting to a broker that requires
|
||||
# authentication. This option is only used if remote_username is also set.
|
||||
# This replaces the old "password" option to avoid confusion. "password"
|
||||
# remains valid for the time being.
|
||||
#remote_password
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# Certificate based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# Either bridge_cafile or bridge_capath must be defined to enable TLS support
|
||||
# for this bridge.
|
||||
# bridge_cafile defines the path to a file containing the
|
||||
# Certificate Authority certificates that have signed the remote broker
|
||||
# certificate.
|
||||
# bridge_capath defines a directory that will be searched for files containing
|
||||
# the CA certificates. For bridge_capath to work correctly, the certificate
|
||||
# files must have ".crt" as the file ending and you must run "c_rehash <path to
|
||||
# capath>" each time you add/remove a certificate.
|
||||
#bridge_cafile
|
||||
#bridge_capath
|
||||
|
||||
# Path to the PEM encoded client certificate, if required by the remote broker.
|
||||
#bridge_certfile
|
||||
|
||||
# Path to the PEM encoded client private key, if required by the remote broker.
|
||||
#bridge_keyfile
|
||||
|
||||
# When using certificate based encryption, bridge_insecure disables
|
||||
# verification of the server hostname in the server certificate. This can be
|
||||
# useful when testing initial server configurations, but makes it possible for
|
||||
# a malicious third party to impersonate your server through DNS spoofing, for
|
||||
# example. Use this option in testing only. If you need to resort to using this
|
||||
# option in a production environment, your setup is at fault and there is no
|
||||
# point using encryption.
|
||||
#bridge_insecure false
|
||||
|
||||
# -----------------------------------------------------------------
|
||||
# PSK based SSL/TLS support
|
||||
# -----------------------------------------------------------------
|
||||
# Pre-shared-key encryption provides an alternative to certificate based
|
||||
# encryption. A bridge can be configured to use PSK with the bridge_identity
|
||||
# and bridge_psk options. These are the client PSK identity, and pre-shared-key
|
||||
# in hexadecimal format with no "0x". Only one of certificate and PSK based
|
||||
# encryption can be used on one
|
||||
# bridge at once.
|
||||
#bridge_identity
|
||||
#bridge_psk
|
||||
|
||||
|
||||
# =================================================================
|
||||
# External config files
|
||||
# =================================================================
|
||||
|
||||
# External configuration files may be included by using the
|
||||
# include_dir option. This defines a directory that will be searched
|
||||
# for config files. All files that end in '.conf' will be loaded as
|
||||
# a configuration file. It is best to have this as the last option
|
||||
# in the main file. This option will only be processed from the main
|
||||
# configuration file. The directory specified must not contain the
|
||||
# main configuration file.
|
||||
#include_dir
|
||||
|
||||
# =================================================================
|
||||
# rsmb options - unlikely to ever be supported
|
||||
# =================================================================
|
||||
|
||||
#ffdc_output
|
||||
#max_log_entries
|
||||
#trace_level
|
||||
#trace_output
|
@ -14,18 +14,29 @@ RUN if [ ${CHANGE_SOURCE} = true ]; then \
|
||||
|
||||
RUN apk update \
|
||||
&& apk upgrade \
|
||||
&& apk --update add logrotate \
|
||||
&& apk add --no-cache openssl \
|
||||
&& apk add --no-cache bash \
|
||||
&& adduser -D -H -u 1000 -s /bin/bash www-data
|
||||
&& apk add --no-cache bash
|
||||
|
||||
RUN set -x ; \
|
||||
addgroup -g 82 -S www-data ; \
|
||||
adduser -u 82 -D -S -G www-data www-data && exit 0 ; exit 1
|
||||
|
||||
ARG PHP_UPSTREAM_CONTAINER=php-fpm
|
||||
ARG PHP_UPSTREAM_PORT=9000
|
||||
|
||||
# Create 'messages' file used from 'logrotate'
|
||||
RUN touch /var/log/messages
|
||||
|
||||
# Copy 'logrotate' config file
|
||||
COPY logrotate/nginx /etc/logrotate.d/
|
||||
|
||||
# Set upstream conf and remove the default conf
|
||||
RUN echo "upstream php-upstream { server ${PHP_UPSTREAM_CONTAINER}:${PHP_UPSTREAM_PORT}; }" > /etc/nginx/conf.d/upstream.conf \
|
||||
&& rm /etc/nginx/conf.d/default.conf
|
||||
|
||||
ADD ./startup.sh /opt/startup.sh
|
||||
RUN sed -i 's/\r//g' /opt/startup.sh
|
||||
CMD ["/bin/bash", "/opt/startup.sh"]
|
||||
|
||||
EXPOSE 80 443
|
||||
|
14
nginx/logrotate/nginx
Normal file
14
nginx/logrotate/nginx
Normal file
@ -0,0 +1,14 @@
|
||||
/var/log/nginx/*.log {
|
||||
daily
|
||||
missingok
|
||||
rotate 32
|
||||
compress
|
||||
delaycompress
|
||||
nodateext
|
||||
notifempty
|
||||
create 644 www-data root
|
||||
sharedscripts
|
||||
postrotate
|
||||
[ -f /var/run/nginx.pid ] && kill -USR1 `cat /var/run/nginx.pid`
|
||||
endscript
|
||||
}
|
4
nginx/ssl/.gitignore
vendored
Normal file
4
nginx/ssl/.gitignore
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
*.crt
|
||||
*.csr
|
||||
*.key
|
||||
*.pem
|
@ -6,4 +6,8 @@ if [ ! -f /etc/nginx/ssl/default.crt ]; then
|
||||
openssl x509 -req -days 365 -in "/etc/nginx/ssl/default.csr" -signkey "/etc/nginx/ssl/default.key" -out "/etc/nginx/ssl/default.crt"
|
||||
fi
|
||||
|
||||
# Start crond in background
|
||||
crond -l 2 -b
|
||||
|
||||
# Start nginx in foreground
|
||||
nginx
|
||||
|
@ -1,10 +0,0 @@
|
||||
FROM fenglc/pgadmin4
|
||||
|
||||
LABEL maintainer="Huadong Zuo <admin@zuohuadong.cn>"
|
||||
|
||||
# user: pgadmin4@pgadmin.org
|
||||
# password: admin
|
||||
# pg_dump & postgresql all in "/usr/bin"
|
||||
# backup in "/var/lib/pgadmin/storage/pgadmin4"
|
||||
|
||||
EXPOSE 5050
|
@ -14,7 +14,8 @@
|
||||
|
||||
ARG LARADOCK_PHP_VERSION
|
||||
|
||||
FROM laradock/php-fpm:2.2-${LARADOCK_PHP_VERSION}
|
||||
# FROM laradock/php-fpm:2.2-${LARADOCK_PHP_VERSION}
|
||||
FROM letsdockerize/laradock-php-fpm:2.4-${LARADOCK_PHP_VERSION}
|
||||
|
||||
LABEL maintainer="Mahmoud Zalt <mahmoud@zalt.me>"
|
||||
|
||||
@ -24,20 +25,27 @@ ARG LARADOCK_PHP_VERSION
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
|
||||
# always run apt update when start and after add new source list, then clean up at end.
|
||||
RUN apt-get update -yqq && \
|
||||
apt-get install -y apt-utils && \
|
||||
pecl channel-update pecl.php.net
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Mandatory Software's Installation
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# Mandatory Software's such as ("mcrypt", "pdo_mysql", "libssl-dev", ....)
|
||||
# are installed on the base image 'laradock/php-fpm' image. If you want
|
||||
# to add more Software's or remove existing one, you need to edit the
|
||||
# base image (https://github.com/Laradock/php-fpm).
|
||||
#
|
||||
RUN set -xe; \
|
||||
apt-get update -yqq && \
|
||||
pecl channel-update pecl.php.net && \
|
||||
apt-get install -yqq \
|
||||
apt-utils \
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Mandatory Software's Installation
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# Mandatory Software's such as ("mcrypt", "pdo_mysql", "libssl-dev", ....)
|
||||
# are installed on the base image 'laradock/php-fpm' image. If you want
|
||||
# to add more Software's or remove existing one, you need to edit the
|
||||
# base image (https://github.com/Laradock/php-fpm).
|
||||
#
|
||||
# next lines are here becase there is no auto build on dockerhub see https://github.com/laradock/laradock/pull/1903#issuecomment-463142846
|
||||
libzip-dev zip unzip && \
|
||||
docker-php-ext-configure zip --with-libzip && \
|
||||
# Install the zip extension
|
||||
docker-php-ext-install zip && \
|
||||
php -m | grep -q 'zip'
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
@ -47,7 +55,7 @@ RUN apt-get update -yqq && \
|
||||
# Optional Software's will only be installed if you set them to `true`
|
||||
# in the `docker-compose.yml` before the build.
|
||||
# Example:
|
||||
# - INSTALL_ZIP_ARCHIVE=true
|
||||
# - INSTALL_SOAP=true
|
||||
#
|
||||
|
||||
###########################################################################
|
||||
@ -92,6 +100,18 @@ RUN if [ ${INSTALL_SOAP} = true ]; then \
|
||||
docker-php-ext-install soap \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# XSL:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_XSL=false
|
||||
|
||||
RUN if [ ${INSTALL_XSL} = true ]; then \
|
||||
# Install the xsl extension
|
||||
apt-get -y install libxslt-dev && \
|
||||
docker-php-ext-install xsl \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# pgsql
|
||||
###########################################################################
|
||||
@ -108,13 +128,17 @@ RUN if [ ${INSTALL_PGSQL} = true ]; then \
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_PG_CLIENT=false
|
||||
ARG INSTALL_POSTGIS=false
|
||||
|
||||
RUN if [ ${INSTALL_PG_CLIENT} = true ]; then \
|
||||
# Create folders if not exists (https://github.com/tianon/docker-brew-debian/issues/65)
|
||||
mkdir -p /usr/share/man/man1 && \
|
||||
mkdir -p /usr/share/man/man7 && \
|
||||
# Install the pgsql client
|
||||
apt-get install -y postgresql-client \
|
||||
apt-get install -y postgresql-client && \
|
||||
if [ ${INSTALL_POSTGIS} = true ]; then \
|
||||
apt-get install -y postgis; \
|
||||
fi \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -187,7 +211,7 @@ ARG INSTALL_SWOOLE=false
|
||||
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||
# Install Php Swoole Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl install swoole-2.0.11; \
|
||||
pecl install swoole-2.0.10; \
|
||||
else \
|
||||
if [ $(php -r "echo PHP_MINOR_VERSION;") = "0" ]; then \
|
||||
pecl install swoole-2.2.0; \
|
||||
@ -196,6 +220,22 @@ RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||
fi \
|
||||
fi && \
|
||||
docker-php-ext-enable swoole \
|
||||
&& php -m | grep -q 'swoole' \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Taint EXTENSION
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_TAINT=false
|
||||
|
||||
RUN if [ ${INSTALL_TAINT} = true ]; then \
|
||||
# Install Php TAINT Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "7" ]; then \
|
||||
pecl install taint && \
|
||||
docker-php-ext-enable taint && \
|
||||
php -m | grep -q 'taint'; \
|
||||
fi \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -214,6 +254,34 @@ RUN if [ ${INSTALL_MONGO} = true ]; then \
|
||||
docker-php-ext-enable mongodb \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Xhprof:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_XHPROF=false
|
||||
|
||||
RUN if [ ${INSTALL_XHPROF} = true ]; then \
|
||||
# Install the php xhprof extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = 7 ]; then \
|
||||
curl -L -o /tmp/xhprof.tar.gz "https://github.com/tideways/php-xhprof-extension/archive/v4.1.6.tar.gz"; \
|
||||
else \
|
||||
curl -L -o /tmp/xhprof.tar.gz "https://codeload.github.com/phacility/xhprof/tar.gz/master"; \
|
||||
fi \
|
||||
&& mkdir -p xhprof \
|
||||
&& tar -C xhprof -zxvf /tmp/xhprof.tar.gz --strip 1 \
|
||||
&& ( \
|
||||
cd xhprof \
|
||||
&& phpize \
|
||||
&& ./configure \
|
||||
&& make \
|
||||
&& make install \
|
||||
) \
|
||||
&& rm -r xhprof \
|
||||
&& rm /tmp/xhprof.tar.gz \
|
||||
;fi
|
||||
|
||||
COPY ./xhprof.ini /usr/local/etc/php/conf.d
|
||||
|
||||
###########################################################################
|
||||
# AMQP:
|
||||
###########################################################################
|
||||
@ -221,23 +289,21 @@ RUN if [ ${INSTALL_MONGO} = true ]; then \
|
||||
ARG INSTALL_AMQP=false
|
||||
|
||||
RUN if [ ${INSTALL_AMQP} = true ]; then \
|
||||
apt-get install librabbitmq-dev -y && \
|
||||
# download and install manually, to make sure it's compatible with ampq installed by pecl later
|
||||
# install cmake first
|
||||
apt-get update && apt-get -y install cmake && \
|
||||
curl -L -o /tmp/rabbitmq-c.tar.gz https://github.com/alanxz/rabbitmq-c/archive/master.tar.gz && \
|
||||
mkdir -p rabbitmq-c && \
|
||||
tar -C rabbitmq-c -zxvf /tmp/rabbitmq-c.tar.gz --strip 1 && \
|
||||
cd rabbitmq-c/ && \
|
||||
mkdir _build && cd _build/ && \
|
||||
cmake .. && \
|
||||
cmake --build . --target install && \
|
||||
# Install the amqp extension
|
||||
pecl install amqp && \
|
||||
docker-php-ext-enable amqp \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# ZipArchive:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_ZIP_ARCHIVE=false
|
||||
|
||||
RUN if [ ${INSTALL_ZIP_ARCHIVE} = true ]; then \
|
||||
apt-get install libzip-dev -y && \
|
||||
docker-php-ext-configure zip --with-libzip && \
|
||||
# Install the zip extension
|
||||
docker-php-ext-install zip \
|
||||
docker-php-ext-enable amqp && \
|
||||
# Install the sockets extension
|
||||
docker-php-ext-install sockets \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -321,30 +387,30 @@ RUN if [ ${INSTALL_EXIF} = true ]; then \
|
||||
USER root
|
||||
|
||||
ARG INSTALL_AEROSPIKE=false
|
||||
ARG AEROSPIKE_PHP_REPOSITORY
|
||||
|
||||
RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \
|
||||
RUN set -xe; \
|
||||
if [ ${INSTALL_AEROSPIKE} = true ]; then \
|
||||
# Fix dependencies for PHPUnit within aerospike extension
|
||||
apt-get -y install sudo wget && \
|
||||
# Install the php aerospike extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php5/archive/master.tar.gz; \
|
||||
else \
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz ${AEROSPIKE_PHP_REPOSITORY}; \
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz; \
|
||||
fi \
|
||||
&& mkdir -p aerospike-client-php \
|
||||
&& tar -C aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \
|
||||
&& mkdir -p /tmp/aerospike-client-php \
|
||||
&& tar -C /tmp/aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \
|
||||
&& \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
( \
|
||||
cd aerospike-client-php/src/aerospike \
|
||||
cd /tmp/aerospike-client-php/src/aerospike \
|
||||
&& phpize \
|
||||
&& ./build.sh \
|
||||
&& make install \
|
||||
) \
|
||||
else \
|
||||
( \
|
||||
cd aerospike-client-php/src \
|
||||
cd /tmp/aerospike-client-php/src \
|
||||
&& phpize \
|
||||
&& ./build.sh \
|
||||
&& make install \
|
||||
@ -438,7 +504,8 @@ RUN if [ ${INSTALL_LDAP} = true ]; then \
|
||||
|
||||
ARG INSTALL_MSSQL=false
|
||||
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
RUN set -eux; \
|
||||
if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
apt-get -y install freetds-dev libsybdb5 \
|
||||
&& ln -s /usr/lib/x86_64-linux-gnu/libsybdb.so /usr/lib/libsybdb.so \
|
||||
@ -461,12 +528,16 @@ RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
&& ln -sfn /etc/locale.alias /usr/share/locale/locale.alias \
|
||||
&& locale-gen \
|
||||
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
|
||||
&& pecl install pdo_sqlsrv sqlsrv \
|
||||
&& if [ $(php -r "echo PHP_MINOR_VERSION;") = "0" ]; then \
|
||||
pecl install pdo_sqlsrv-5.3.0 sqlsrv-5.3.0 \
|
||||
;else \
|
||||
pecl install pdo_sqlsrv sqlsrv \
|
||||
;fi \
|
||||
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
|
||||
&& php -m | grep -q 'pdo_sqlsrv' \
|
||||
&& php -m | grep -q 'sqlsrv' \
|
||||
;fi \
|
||||
;fi
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Image optimizers:
|
||||
@ -528,22 +599,137 @@ ARG INSTALL_PHALCON=false
|
||||
ARG LARADOCK_PHALCON_VERSION
|
||||
ENV LARADOCK_PHALCON_VERSION ${LARADOCK_PHALCON_VERSION}
|
||||
|
||||
# Copy phalcon configration
|
||||
COPY ./phalcon.ini /usr/local/etc/php/conf.d/phalcon.ini.disable
|
||||
|
||||
RUN if [ $INSTALL_PHALCON = true ]; then \
|
||||
apt-get update && apt-get install -y unzip libpcre3-dev gcc make re2c \
|
||||
&& curl -L -o /tmp/cphalcon.zip https://github.com/phalcon/cphalcon/archive/v${LARADOCK_PHALCON_VERSION}.zip \
|
||||
&& unzip -d /tmp/ /tmp/cphalcon.zip \
|
||||
&& cd /tmp/cphalcon-${LARADOCK_PHALCON_VERSION}/build \
|
||||
&& ./install \
|
||||
&& echo "extension=phalcon.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/phalcon.ini \
|
||||
&& ln -s /etc/php/${LARADOCK_PHP_VERSION}/mods-available/phalcon.ini /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/30-phalcon.ini \
|
||||
&& mv /usr/local/etc/php/conf.d/phalcon.ini.disable /usr/local/etc/php/conf.d/phalcon.ini \
|
||||
&& rm -rf /tmp/cphalcon* \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# APCU:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_APCU=false
|
||||
|
||||
RUN if [ ${INSTALL_APCU} = true ]; then \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl install -a apcu-4.0.11; \
|
||||
else \
|
||||
pecl install apcu; \
|
||||
fi && \
|
||||
docker-php-ext-enable apcu \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# YAML:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_YAML=false
|
||||
|
||||
RUN if [ ${INSTALL_YAML} = true ]; then \
|
||||
apt-get install libyaml-dev -y ; \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl install -a yaml-1.3.2; \
|
||||
else \
|
||||
pecl install yaml; \
|
||||
fi && \
|
||||
docker-php-ext-enable yaml \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# RDKAFKA:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_RDKAFKA=false
|
||||
|
||||
RUN if [ ${INSTALL_RDKAFKA} = true ]; then \
|
||||
apt-get install -y librdkafka-dev && \
|
||||
pecl install rdkafka && \
|
||||
docker-php-ext-enable rdkafka \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Install additional locales:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_ADDITIONAL_LOCALES=false
|
||||
ARG ADDITIONAL_LOCALES
|
||||
|
||||
RUN if [ ${INSTALL_ADDITIONAL_LOCALES} = true ]; then \
|
||||
apt-get install -y locales \
|
||||
&& echo '' >> /usr/share/locale/locale.alias \
|
||||
&& temp="${ADDITIONAL_LOCALES%\"}" \
|
||||
&& temp="${temp#\"}" \
|
||||
&& for i in ${temp}; do sed -i "/$i/s/^#//g" /etc/locale.gen; done \
|
||||
&& locale-gen \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# MySQL Client:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_MYSQL_CLIENT=false
|
||||
|
||||
RUN if [ ${INSTALL_MYSQL_CLIENT} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install mysql-client \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# ping:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_PING=false
|
||||
|
||||
RUN if [ ${INSTALL_PING} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install inetutils-ping \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# sshpass:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_SSHPASS=false
|
||||
|
||||
RUN if [ ${INSTALL_SSHPASS} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install sshpass \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# FFMPEG:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_FFMPEG=false
|
||||
|
||||
RUN if [ ${INSTALL_FFMPEG} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install ffmpeg \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Check PHP version:
|
||||
###########################################################################
|
||||
|
||||
RUN php -v | head -n 1 | grep -q "PHP ${LARADOCK_PHP_VERSION}."
|
||||
RUN set -xe; php -v | head -n 1 | grep -q "PHP ${LARADOCK_PHP_VERSION}."
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
|
@ -1,9 +1,9 @@
|
||||
; NOTE: The actual opcache.so extention is NOT SET HERE but rather (/usr/local/etc/php/conf.d/docker-php-ext-opcache.ini)
|
||||
|
||||
opcache.enable="1"
|
||||
opcache.memory_consumption="256"
|
||||
opcache.use_cwd="0"
|
||||
opcache.max_file_size="0"
|
||||
opcache.max_accelerated_files = 30000
|
||||
opcache.validate_timestamps="1"
|
||||
opcache.revalidate_freq="0"
|
||||
opcache.enable=1
|
||||
opcache.memory_consumption=256
|
||||
opcache.use_cwd=0
|
||||
opcache.max_file_size=0
|
||||
opcache.max_accelerated_files=30000
|
||||
opcache.validate_timestamps=1
|
||||
opcache.revalidate_freq=0
|
||||
|
1
php-fpm/phalcon.ini
Normal file
1
php-fpm/phalcon.ini
Normal file
@ -0,0 +1 @@
|
||||
extension=phalcon.so
|
1918
php-fpm/php7.3.ini
Normal file
1918
php-fpm/php7.3.ini
Normal file
File diff suppressed because it is too large
Load Diff
8
php-fpm/xhprof.ini
Normal file
8
php-fpm/xhprof.ini
Normal file
@ -0,0 +1,8 @@
|
||||
[xhprof]
|
||||
; extension=xhprof.so
|
||||
extension=tideways.so
|
||||
xhprof.output_dir=/var/www/xhprof
|
||||
; no need to autoload, control in the program
|
||||
tideways.auto_prepend_library=0
|
||||
; set default rate
|
||||
tideways.sample_rate=100
|
@ -16,6 +16,7 @@ RUN apk --update add wget \
|
||||
libmemcached-dev \
|
||||
libmcrypt-dev \
|
||||
libxml2-dev \
|
||||
pcre-dev \
|
||||
zlib-dev \
|
||||
autoconf \
|
||||
cyrus-sasl-dev \
|
||||
@ -25,6 +26,15 @@ RUN apk --update add wget \
|
||||
RUN docker-php-ext-install mysqli mbstring pdo pdo_mysql tokenizer xml pcntl
|
||||
RUN pecl channel-update pecl.php.net && pecl install memcached mcrypt-1.0.1 && docker-php-ext-enable memcached
|
||||
|
||||
# Add a non-root user:
|
||||
ARG PUID=1000
|
||||
ENV PUID ${PUID}
|
||||
ARG PGID=1000
|
||||
ENV PGID ${PGID}
|
||||
|
||||
RUN addgroup -g ${PGID} laradock && \
|
||||
adduser -D -G laradock -u ${PUID} laradock
|
||||
|
||||
#Install SOAP package:
|
||||
ARG INSTALL_SOAP=false
|
||||
RUN if [ ${INSTALL_SOAP} = true ]; then \
|
||||
@ -44,9 +54,101 @@ RUN if [ ${INSTALL_PGSQL} = true ]; then \
|
||||
&& docker-php-ext-install pdo_pgsql \
|
||||
;fi
|
||||
|
||||
# Install ZipArchive:
|
||||
ARG INSTALL_ZIP_ARCHIVE=false
|
||||
RUN if [ ${INSTALL_ZIP_ARCHIVE} = true ]; then \
|
||||
apk --update add libzip-dev && \
|
||||
docker-php-ext-configure zip --with-libzip && \
|
||||
# Install the zip extension
|
||||
docker-php-ext-install zip \
|
||||
;fi
|
||||
|
||||
# Install MySQL Client:
|
||||
ARG INSTALL_MYSQL_CLIENT=false
|
||||
RUN if [ ${INSTALL_MYSQL_CLIENT} = true ]; then \
|
||||
apk --update add mysql-client \
|
||||
;fi
|
||||
|
||||
# Install FFMPEG:
|
||||
ARG INSTALL_FFMPEG=false
|
||||
RUN if [ ${INSTALL_FFMPEG} = true ]; then \
|
||||
apk --update add ffmpeg \
|
||||
;fi
|
||||
|
||||
# Install AMQP:
|
||||
ARG INSTALL_AMQP=false
|
||||
|
||||
RUN if [ ${INSTALL_AMQP} = true ]; then \
|
||||
apk --update add rabbitmq-c rabbitmq-c-dev && \
|
||||
pecl install amqp && \
|
||||
docker-php-ext-enable amqp && \
|
||||
docker-php-ext-install sockets \
|
||||
;fi
|
||||
|
||||
# Install Phalcon ext
|
||||
ARG INSTALL_PHALCON=false
|
||||
ARG PHALCON_VERSION
|
||||
ENV PHALCON_VERSION ${PHALCON_VERSION}
|
||||
|
||||
RUN if [ $INSTALL_PHALCON = true ]; then \
|
||||
apk --update add unzip gcc make re2c bash\
|
||||
&& curl -L -o /tmp/cphalcon.zip https://github.com/phalcon/cphalcon/archive/v${PHALCON_VERSION}.zip \
|
||||
&& unzip -d /tmp/ /tmp/cphalcon.zip \
|
||||
&& cd /tmp/cphalcon-${PHALCON_VERSION}/build \
|
||||
&& ./install \
|
||||
&& rm -rf /tmp/cphalcon* \
|
||||
;fi
|
||||
|
||||
RUN if [ $INSTALL_GHOSTSCRIPT = true ]; then \
|
||||
apk --update add ghostscript \
|
||||
;fi
|
||||
|
||||
#Install GMP package:
|
||||
ARG INSTALL_GMP=false
|
||||
RUN if [ ${INSTALL_GMP} = true ]; then \
|
||||
apk add --update --no-cache gmp gmp-dev \
|
||||
&& docker-php-ext-install gmp \
|
||||
;fi
|
||||
|
||||
|
||||
RUN rm /var/cache/apk/* \
|
||||
&& mkdir -p /var/www
|
||||
|
||||
|
||||
###########################################################################
|
||||
# Swoole EXTENSION
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_SWOOLE=false
|
||||
|
||||
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||
# Install Php Swoole Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl -q install swoole-2.0.10; \
|
||||
else \
|
||||
if [ $(php -r "echo PHP_MINOR_VERSION;") = "0" ]; then \
|
||||
pecl install swoole-2.2.0; \
|
||||
else \
|
||||
pecl install swoole; \
|
||||
fi \
|
||||
fi \
|
||||
&& docker-php-ext-enable swoole \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Taint EXTENSION
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_TAINT=false
|
||||
|
||||
RUN if [ ${INSTALL_TAINT} = true ]; then \
|
||||
# Install Php TAINT Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "7" ]; then \
|
||||
pecl install taint; \
|
||||
fi && \
|
||||
docker-php-ext-enable taint \
|
||||
;fi
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Optional Supervisord Configuration
|
||||
|
8
php-worker/supervisord.d/laravel-scheduler.conf.example
Normal file
8
php-worker/supervisord.d/laravel-scheduler.conf.example
Normal file
@ -0,0 +1,8 @@
|
||||
[program:laravel-scheduler]
|
||||
process_name=%(program_name)s_%(process_num)02d
|
||||
command=/bin/sh -c "while [ true ]; do (php /var/www/artisan schedule:run --verbose --no-interaction &); sleep 60; done"
|
||||
autostart=true
|
||||
autorestart=true
|
||||
numprocs=1
|
||||
user=laradock
|
||||
redirect_stderr=true
|
@ -4,4 +4,5 @@ command=php /var/www/artisan queue:work --sleep=3 --tries=3 --daemon
|
||||
autostart=true
|
||||
autorestart=true
|
||||
numprocs=8
|
||||
user=laradock
|
||||
redirect_stderr=true
|
||||
|
@ -1,3 +1,4 @@
|
||||
*.sh
|
||||
!init_gitlab_db.sh
|
||||
!init_jupyterhub_db.sh
|
||||
!init_sonarqube_db.sh
|
||||
|
@ -33,9 +33,12 @@
|
||||
# EOSQL
|
||||
#
|
||||
### default database and user for gitlab ##############################################
|
||||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
CREATE USER laradock_gitlab WITH PASSWORD 'laradock_gitlab';
|
||||
CREATE DATABASE laradock_gitlab;
|
||||
GRANT ALL PRIVILEGES ON DATABASE laradock_gitlab TO laradock_gitlab;
|
||||
ALTER ROLE laradock_gitlab CREATEROLE SUPERUSER;
|
||||
EOSQL
|
||||
if [ "$GITLAB_POSTGRES_INIT" == 'true' ]; then
|
||||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
CREATE USER $GITLAB_POSTGRES_USER WITH PASSWORD '$GITLAB_POSTGRES_PASSWORD';
|
||||
CREATE DATABASE $GITLAB_POSTGRES_DB;
|
||||
GRANT ALL PRIVILEGES ON DATABASE $GITLAB_POSTGRES_DB TO $GITLAB_POSTGRES_USER;
|
||||
ALTER ROLE $GITLAB_POSTGRES_USER CREATEROLE SUPERUSER;
|
||||
EOSQL
|
||||
echo
|
||||
fi
|
@ -33,9 +33,12 @@
|
||||
# EOSQL
|
||||
#
|
||||
### default database and user for jupyterhub ##############################################
|
||||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
CREATE USER laradock_jupyterhub WITH PASSWORD 'laradock_jupyterhub';
|
||||
CREATE DATABASE laradock_jupyterhub;
|
||||
GRANT ALL PRIVILEGES ON DATABASE laradock_jupyterhub TO laradock_jupyterhub;
|
||||
ALTER ROLE laradock_jupyterhub CREATEROLE SUPERUSER;
|
||||
EOSQL
|
||||
if [ "$JUPYTERHUB_POSTGRES_INIT" == 'true' ]; then
|
||||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
CREATE USER $JUPYTERHUB_POSTGRES_USER WITH PASSWORD '$JUPYTERHUB_POSTGRES_PASSWORD';
|
||||
CREATE DATABASE $JUPYTERHUB_POSTGRES_DB;
|
||||
GRANT ALL PRIVILEGES ON DATABASE $JUPYTERHUB_POSTGRES_DB TO $JUPYTERHUB_POSTGRES_USER;
|
||||
ALTER ROLE $JUPYTERHUB_POSTGRES_USER CREATEROLE SUPERUSER;
|
||||
EOSQL
|
||||
echo
|
||||
fi
|
||||
|
44
postgres/docker-entrypoint-initdb.d/init_sonarqube_db.sh
Normal file
44
postgres/docker-entrypoint-initdb.d/init_sonarqube_db.sh
Normal file
@ -0,0 +1,44 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copy createdb.sh.example to createdb.sh
|
||||
# then uncomment then set database name and username to create you need databases
|
||||
#
|
||||
# example: .env POSTGRES_USER=appuser and need db name is myshop_db
|
||||
#
|
||||
# psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
# CREATE USER myuser WITH PASSWORD 'mypassword';
|
||||
# CREATE DATABASE myshop_db;
|
||||
# GRANT ALL PRIVILEGES ON DATABASE myshop_db TO myuser;
|
||||
# EOSQL
|
||||
#
|
||||
# this sh script will auto run when the postgres container starts and the $DATA_PATH_HOST/postgres not found.
|
||||
#
|
||||
#
|
||||
# psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
# CREATE USER db1 WITH PASSWORD 'db1';
|
||||
# CREATE DATABASE db1;
|
||||
# GRANT ALL PRIVILEGES ON DATABASE db1 TO db1;
|
||||
# EOSQL
|
||||
#
|
||||
# psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
# CREATE USER db2 WITH PASSWORD 'db2';
|
||||
# CREATE DATABASE db2;
|
||||
# GRANT ALL PRIVILEGES ON DATABASE db2 TO db2;
|
||||
# EOSQL
|
||||
#
|
||||
# psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
# CREATE USER db3 WITH PASSWORD 'db3';
|
||||
# CREATE DATABASE db3;
|
||||
# GRANT ALL PRIVILEGES ON DATABASE db3 TO db3;
|
||||
# EOSQL
|
||||
#
|
||||
### default database and user for gitlab ##############################################
|
||||
if [ "$SONARQUBE_POSTGRES_INIT" == 'true' ]; then
|
||||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
|
||||
CREATE USER $SONARQUBE_POSTGRES_USER WITH PASSWORD '$SONARQUBE_POSTGRES_PASSWORD';
|
||||
CREATE DATABASE $SONARQUBE_POSTGRES_DB;
|
||||
GRANT ALL PRIVILEGES ON DATABASE $SONARQUBE_POSTGRES_DB TO $SONARQUBE_POSTGRES_USER;
|
||||
ALTER ROLE $SONARQUBE_POSTGRES_USER CREATEROLE SUPERUSER;
|
||||
EOSQL
|
||||
echo
|
||||
fi
|
@ -1,7 +1,7 @@
|
||||
FROM rabbitmq
|
||||
FROM rabbitmq:alpine
|
||||
|
||||
LABEL maintainer="Mahmoud Zalt <mahmoud@zalt.me>"
|
||||
|
||||
RUN rabbitmq-plugins enable --offline rabbitmq_management
|
||||
|
||||
EXPOSE 15671 15672
|
||||
EXPOSE 4369 5671 5672 15671 15672 25672
|
||||
|
3
redis-cluster/Dockerfile
Normal file
3
redis-cluster/Dockerfile
Normal file
@ -0,0 +1,3 @@
|
||||
FROM grokzen/redis-cluster:latest
|
||||
|
||||
LABEL maintainer="hareku <hareku908@gmail.com>"
|
3
redis-webui/Dockerfile
Normal file
3
redis-webui/Dockerfile
Normal file
@ -0,0 +1,3 @@
|
||||
FROM erikdubbelboer/phpredisadmin
|
||||
|
||||
LABEL maintainer="ahkui <ahkui@outlook.com>"
|
1377
redis/redis.conf
Normal file
1377
redis/redis.conf
Normal file
File diff suppressed because it is too large
Load Diff
@ -4,6 +4,13 @@ LABEL maintainer="Cristian Mello <cristianc.mello@gmail.com>"
|
||||
|
||||
VOLUME /data/rethinkdb_data
|
||||
|
||||
#Necessary for the backup rethinkdb
|
||||
RUN apt-get -y update \
|
||||
&& apt-get -y upgrade \
|
||||
&& apt-get -y install python-pip \
|
||||
&& pip install rethinkdb \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN cp /etc/rethinkdb/default.conf.sample /etc/rethinkdb/instances.d/instance1.conf
|
||||
|
||||
CMD ["rethinkdb", "--bind", "all"]
|
||||
|
@ -18,7 +18,7 @@ ENV SOLR_DATAIMPORTHANDLER_MSSQL ${SOLR_DATAIMPORTHANDLER_MSSQL}
|
||||
# download mssql connector for dataimporthandler
|
||||
RUN if [ ${SOLR_DATAIMPORTHANDLER_MSSQL} = true ]; then \
|
||||
curl -L -o /tmp/mssql-jdbc-7.0.0.jre8.jar "https://github.com/Microsoft/mssql-jdbc/releases/download/v7.0.0/mssql-jdbc-7.0.0.jre8.jar" \
|
||||
&& mkdir /opt/solr/contrib/dataimporthandler/lib \
|
||||
&& mkdir -p /opt/solr/contrib/dataimporthandler/lib \
|
||||
&& mv /tmp/mssql-jdbc-7.0.0.jre8.jar "/opt/solr/contrib/dataimporthandler/lib/mssql-jdbc-7.0.0.jre8.jar" \
|
||||
;fi
|
||||
|
||||
|
3
sonarqube/Dockerfile
Normal file
3
sonarqube/Dockerfile
Normal file
@ -0,0 +1,3 @@
|
||||
FROM sonarqube:latest
|
||||
|
||||
LABEL maintainer="xiagw <fxiaxiaoyu@gmail.com>"
|
4
sync.sh
4
sync.sh
@ -41,7 +41,7 @@ display_options () {
|
||||
print_style " install" "info"; printf "\t\t Installs docker-sync gem on the host machine.\n"
|
||||
print_style " up [services]" "success"; printf "\t Starts docker-sync and runs docker compose.\n"
|
||||
print_style " down" "success"; printf "\t\t\t Stops containers and docker-sync.\n"
|
||||
print_style " bash" "success"; printf "\t\t\t Opens bash on the workspace.\n"
|
||||
print_style " bash" "success"; printf "\t\t\t Opens bash on the workspace with user laradock.\n"
|
||||
print_style " sync" "info"; printf "\t\t\t Manually triggers the synchronization of files.\n"
|
||||
print_style " clean" "danger"; printf "\t\t Removes all files from docker-sync.\n"
|
||||
}
|
||||
@ -69,7 +69,7 @@ elif [ "$1" == "down" ]; then
|
||||
docker-sync stop
|
||||
|
||||
elif [ "$1" == "bash" ]; then
|
||||
docker-compose exec workspace bash
|
||||
docker-compose exec --user=laradock workspace bash
|
||||
|
||||
elif [ "$1" == "install" ]; then
|
||||
print_style "Installing docker-sync\n" "info"
|
||||
|
7
traefik/Dockerfile
Normal file
7
traefik/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM traefik:1.7.5-alpine
|
||||
|
||||
LABEL maintainer="Luis Coutinho <luis@luiscoutinho.pt>"
|
||||
|
||||
COPY traefik.toml acme.json /
|
||||
|
||||
RUN chmod 600 /acme.json
|
0
traefik/acme.json
Normal file
0
traefik/acme.json
Normal file
23
traefik/traefik.toml
Normal file
23
traefik/traefik.toml
Normal file
@ -0,0 +1,23 @@
|
||||
defaultEntryPoints = ["http", "https"]
|
||||
|
||||
[entryPoints]
|
||||
[entryPoints.http]
|
||||
address = ":80"
|
||||
[entryPoints.http.redirect]
|
||||
entryPoint = "https"
|
||||
[entryPoints.https]
|
||||
address = ":443"
|
||||
[entryPoints.https.tls]
|
||||
|
||||
[web]
|
||||
address = ":8080"
|
||||
[acme]
|
||||
email = "email@example.org"
|
||||
storage = "acme.json"
|
||||
entryPoint = "https"
|
||||
onHostRule = true
|
||||
[acme.httpChallenge]
|
||||
entryPoint = "http"
|
||||
|
||||
[[acme.domais]]
|
||||
main = "localhost"
|
@ -16,9 +16,23 @@ if [ -n "${PHP_VERSION}" ]; then
|
||||
sed -i -- 's/=false/=true/g' .env
|
||||
sed -i -- 's/PHPDBG=true/PHPDBG=false/g' .env
|
||||
if [ "${PHP_VERSION}" == "5.6" ]; then
|
||||
sed -i -- 's/^AEROSPIKE_PHP_REPOSITORY=/##AEROSPIKE_PHP_REPOSITORY=/g' .env
|
||||
sed -i -- 's/^# AEROSPIKE_PHP_REPOSITORY=/AEROSPIKE_PHP_REPOSITORY=/g' .env
|
||||
# Aerospike C Client SDK 4.0.7, Debian 9.6 is not supported
|
||||
# https://github.com/aerospike/aerospike-client-php5/issues/145
|
||||
sed -i -- 's/PHP_FPM_INSTALL_AEROSPIKE=true/PHP_FPM_INSTALL_AEROSPIKE=false/g' .env
|
||||
fi
|
||||
if [ "${PHP_VERSION}" == "7.3" ]; then
|
||||
# V8JS extension does not yet support PHP 7.3.
|
||||
sed -i -- 's/WORKSPACE_INSTALL_V8JS=true/WORKSPACE_INSTALL_V8JS=false/g' .env
|
||||
# This ssh2 extension does not yet support PHP 7.3.
|
||||
sed -i -- 's/PHP_FPM_INSTALL_SSH2=true/PHP_FPM_INSTALL_SSH2=false/g' .env
|
||||
# xdebug extension does not yet support PHP 7.3.
|
||||
sed -i -- 's/PHP_FPM_INSTALL_XDEBUG=true/PHP_FPM_INSTALL_XDEBUG=false/g' .env
|
||||
# memcached extension does not yet support PHP 7.3.
|
||||
sed -i -- 's/PHP_FPM_INSTALL_MEMCACHED=true/PHP_FPM_INSTALL_MEMCACHED=false/g' .env
|
||||
fi
|
||||
|
||||
sed -i -- 's/CHANGE_SOURCE=true/CHANGE_SOURCE=false/g' .env
|
||||
|
||||
cat .env
|
||||
docker-compose build ${BUILD_SERVICE}
|
||||
docker images
|
||||
|
@ -14,7 +14,8 @@
|
||||
|
||||
ARG LARADOCK_PHP_VERSION
|
||||
|
||||
FROM laradock/workspace:2.2-${LARADOCK_PHP_VERSION}
|
||||
# FROM laradock/workspace:2.2-${LARADOCK_PHP_VERSION}
|
||||
FROM letsdockerize/laradock-workspace:2.4-${LARADOCK_PHP_VERSION}
|
||||
|
||||
LABEL maintainer="Mahmoud Zalt <mahmoud@zalt.me>"
|
||||
|
||||
@ -37,22 +38,31 @@ ARG PGID=1000
|
||||
ENV PGID ${PGID}
|
||||
|
||||
# always run apt update when start and after add new source list, then clean up at end.
|
||||
RUN apt-get update -yqq && \
|
||||
RUN set -xe; \
|
||||
apt-get update -yqq && \
|
||||
pecl channel-update pecl.php.net && \
|
||||
groupadd -g ${PGID} laradock && \
|
||||
useradd -u ${PUID} -g laradock -m laradock -G docker_env && \
|
||||
usermod -p "*" laradock
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Mandatory Software's Installation
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# Mandatory Software's such as ("php-cli", "git", "vim", ....) are
|
||||
# installed on the base image 'laradock/workspace' image. If you want
|
||||
# to add more Software's or remove existing one, you need to edit the
|
||||
# base image (https://github.com/Laradock/workspace).
|
||||
#
|
||||
usermod -p "*" laradock -s /bin/bash && \
|
||||
apt-get install -yqq \
|
||||
apt-utils \
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
# Mandatory Software's Installation
|
||||
#--------------------------------------------------------------------------
|
||||
#
|
||||
# Mandatory Software's such as ("php-cli", "git", "vim", ....) are
|
||||
# installed on the base image 'laradock/workspace' image. If you want
|
||||
# to add more Software's or remove existing one, you need to edit the
|
||||
# base image (https://github.com/Laradock/workspace).
|
||||
#
|
||||
# next lines are here becase there is no auto build on dockerhub see https://github.com/laradock/laradock/pull/1903#issuecomment-463142846
|
||||
libzip-dev zip unzip \
|
||||
# Install the zip extension
|
||||
php${LARADOCK_PHP_VERSION}-zip \
|
||||
# nasm
|
||||
nasm && \
|
||||
php -m | grep -q 'zip'
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
@ -90,14 +100,14 @@ RUN sed -i 's/\r//' /root/aliases.sh && \
|
||||
echo "" >> ~/.bashrc && \
|
||||
echo "# Load Custom Aliases" >> ~/.bashrc && \
|
||||
echo "source ~/aliases.sh" >> ~/.bashrc && \
|
||||
echo "" >> ~/.bashrc
|
||||
echo "" >> ~/.bashrc
|
||||
|
||||
USER laradock
|
||||
|
||||
RUN echo "" >> ~/.bashrc && \
|
||||
echo "# Load Custom Aliases" >> ~/.bashrc && \
|
||||
echo "source ~/aliases.sh" >> ~/.bashrc && \
|
||||
echo "" >> ~/.bashrc
|
||||
echo "" >> ~/.bashrc
|
||||
|
||||
###########################################################################
|
||||
# Composer:
|
||||
@ -108,6 +118,9 @@ USER root
|
||||
# Add the composer.json
|
||||
COPY ./composer.json /home/laradock/.composer/composer.json
|
||||
|
||||
# Add the auth.json for magento 2 credentials
|
||||
COPY ./auth.json /home/laradock/.composer/auth.json
|
||||
|
||||
# Make sure that ~/.composer belongs to laradock
|
||||
RUN chown -R laradock:laradock /home/laradock/.composer
|
||||
|
||||
@ -122,6 +135,15 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
|
||||
composer global install \
|
||||
;fi
|
||||
|
||||
# Check if auth file is disabled
|
||||
ARG COMPOSER_AUTH=false
|
||||
ENV COMPOSER_AUTH ${COMPOSER_AUTH}
|
||||
|
||||
RUN if [ ${COMPOSER_AUTH} = false ]; then \
|
||||
# remove the file
|
||||
rm /home/laradock/.composer/auth.json \
|
||||
;fi
|
||||
|
||||
ARG COMPOSER_REPO_PACKAGIST
|
||||
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
|
||||
|
||||
@ -174,6 +196,21 @@ RUN if [ ${INSTALL_DRUSH} = true ]; then \
|
||||
drush core-status \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# WP CLI:
|
||||
###########################################################################
|
||||
|
||||
# The command line interface for WordPress
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_WP_CLI=false
|
||||
|
||||
RUN if [ ${INSTALL_WP_CLI} = true ]; then \
|
||||
curl -fsSL -o /usr/local/bin/wp https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar | bash && \
|
||||
chmod +x /usr/local/bin/wp \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# SSH2:
|
||||
###########################################################################
|
||||
@ -194,11 +231,11 @@ RUN if [ ${INSTALL_SSH2} = true ]; then \
|
||||
USER root
|
||||
|
||||
ARG INSTALL_GMP=false
|
||||
ARG PHP_VERSION=${PHP_VERSION}
|
||||
ARG PHP_VERSION=${LARADOCK_PHP_VERSION}
|
||||
|
||||
RUN if [ ${INSTALL_GMP} = true ]; then \
|
||||
# Install the PHP GMP extension
|
||||
apt-get -y install php${PHP_VERSION}-gmp \
|
||||
apt-get -y install php${LARADOCK_PHP_VERSION}-gmp \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -214,6 +251,20 @@ RUN if [ ${INSTALL_SOAP} = true ]; then \
|
||||
apt-get -y install libxml2-dev php${LARADOCK_PHP_VERSION}-soap \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# XSL:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_XSL=false
|
||||
|
||||
RUN if [ ${INSTALL_XSL} = true ]; then \
|
||||
# Install the PHP XSL extension
|
||||
apt-get -y install libxslt-dev php${LARADOCK_PHP_VERSION}-xsl \
|
||||
;fi
|
||||
|
||||
|
||||
###########################################################################
|
||||
# LDAP:
|
||||
###########################################################################
|
||||
@ -294,7 +345,7 @@ ARG BLACKFIRE_CLIENT_TOKEN
|
||||
ENV BLACKFIRE_CLIENT_TOKEN ${BLACKFIRE_CLIENT_TOKEN}
|
||||
|
||||
RUN if [ ${INSTALL_XDEBUG} = false -a ${INSTALL_BLACKFIRE} = true ]; then \
|
||||
curl -L https://packagecloud.io/gpg.key | apt-key add - && \
|
||||
curl -L https://packages.blackfire.io/gpg.key | apt-key add - && \
|
||||
echo "deb http://packages.blackfire.io/debian any main" | tee /etc/apt/sources.list.d/blackfire.list && \
|
||||
apt-get update -yqq && \
|
||||
apt-get install blackfire-agent \
|
||||
@ -359,10 +410,7 @@ RUN if [ ${INSTALL_AMQP} = true ]; then \
|
||||
ARG INSTALL_PHPREDIS=false
|
||||
|
||||
RUN if [ ${INSTALL_PHPREDIS} = true ]; then \
|
||||
# Install Php Redis extension
|
||||
printf "\n" | pecl -q install -o -f redis && \
|
||||
echo "extension=redis.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/redis.ini && \
|
||||
phpenmod redis \
|
||||
apt-get install -yqq php-redis \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -374,7 +422,7 @@ ARG INSTALL_SWOOLE=false
|
||||
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||
# Install Php Swoole Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl -q install swoole-2.0.11; \
|
||||
pecl -q install swoole-2.0.10; \
|
||||
else \
|
||||
if [ $(php -r "echo PHP_MINOR_VERSION;") = "0" ]; then \
|
||||
pecl install swoole-2.2.0; \
|
||||
@ -384,6 +432,23 @@ RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||
fi && \
|
||||
echo "extension=swoole.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/swoole.ini && \
|
||||
ln -s /etc/php/${LARADOCK_PHP_VERSION}/mods-available/swoole.ini /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/20-swoole.ini \
|
||||
&& php -m | grep -q 'swoole' \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Taint EXTENSION
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_TAINT=false
|
||||
|
||||
RUN if [ "${INSTALL_TAINT}" = true ]; then \
|
||||
# Install Php TAINT Extension
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "7" ]; then \
|
||||
pecl install taint && \
|
||||
echo "extension=taint.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/taint.ini && \
|
||||
ln -s /etc/php/${LARADOCK_PHP_VERSION}/mods-available/taint.ini /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/20-taint.ini && \
|
||||
php -m | grep -q 'taint'; \
|
||||
fi \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
@ -397,6 +462,31 @@ RUN if [ ${INSTALL_LIBPNG} = true ]; then \
|
||||
apt-get install libpng16-16 \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Inotify EXTENSION:
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_INOTIFY=false
|
||||
|
||||
RUN if [ ${INSTALL_INOTIFY} = true ]; then \
|
||||
pecl -q install inotify && \
|
||||
echo "extension=inotify.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/inotify.ini && \
|
||||
ln -s /etc/php/${LARADOCK_PHP_VERSION}/mods-available/inotify.ini /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/20-inotify.ini \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# fswatch
|
||||
###########################################################################
|
||||
|
||||
ARG INSTALL_FSWATCH=false
|
||||
|
||||
RUN if [ ${INSTALL_FSWATCH} = true ]; then \
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 47FE03C1 \
|
||||
&& add-apt-repository -y ppa:hadret/fswatch \
|
||||
|| apt-get update -yqq \
|
||||
&& apt-get -y install fswatch \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# IonCube Loader
|
||||
###########################################################################
|
||||
@ -440,6 +530,7 @@ ARG INSTALL_NODE=false
|
||||
ARG INSTALL_NPM_GULP=false
|
||||
ARG INSTALL_NPM_BOWER=false
|
||||
ARG INSTALL_NPM_VUE_CLI=false
|
||||
ARG INSTALL_NPM_ANGULAR_CLI=false
|
||||
ARG NPM_REGISTRY
|
||||
ENV NPM_REGISTRY ${NPM_REGISTRY}
|
||||
ENV NVM_DIR /home/laradock/.nvm
|
||||
@ -464,6 +555,9 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
|
||||
&& if [ ${INSTALL_NPM_VUE_CLI} = true ]; then \
|
||||
npm install -g @vue/cli \
|
||||
;fi \
|
||||
&& if [ ${INSTALL_NPM_ANGULAR_CLI} = true ]; then \
|
||||
npm install -g @angular/cli \
|
||||
;fi \
|
||||
&& ln -s `npm bin --global` /home/laradock/.node-bin \
|
||||
;fi
|
||||
|
||||
@ -487,6 +581,20 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
|
||||
# Add PATH for node
|
||||
ENV PATH $PATH:/home/laradock/.node-bin
|
||||
|
||||
# Make it so the node modules can be executed with 'docker-compose exec'
|
||||
# We'll create symbolic links into '/usr/local/bin'.
|
||||
RUN if [ ${INSTALL_NODE} = true ]; then \
|
||||
find $NVM_DIR -type f -name node -exec ln -s {} /usr/local/bin/node \; && \
|
||||
NODE_MODS_DIR="$NVM_DIR/versions/node/$(node -v)/lib/node_modules" && \
|
||||
ln -s $NODE_MODS_DIR/bower/bin/bower /usr/local/bin/bower && \
|
||||
ln -s $NODE_MODS_DIR/gulp/bin/gulp.js /usr/local/bin/gulp && \
|
||||
ln -s $NODE_MODS_DIR/npm/bin/npm-cli.js /usr/local/bin/npm && \
|
||||
ln -s $NODE_MODS_DIR/npm/bin/npx-cli.js /usr/local/bin/npx && \
|
||||
ln -s $NODE_MODS_DIR/vue-cli/bin/vue /usr/local/bin/vue && \
|
||||
ln -s $NODE_MODS_DIR/vue-cli/bin/vue-init /usr/local/bin/vue-init && \
|
||||
ln -s $NODE_MODS_DIR/vue-cli/bin/vue-list /usr/local/bin/vue-list \
|
||||
;fi
|
||||
|
||||
RUN if [ ${NPM_REGISTRY} ]; then \
|
||||
. ~/.bashrc && npm config set registry ${NPM_REGISTRY} \
|
||||
;fi
|
||||
@ -531,26 +639,30 @@ ENV PATH $PATH:/home/laradock/.yarn/bin
|
||||
USER root
|
||||
|
||||
ARG INSTALL_AEROSPIKE=false
|
||||
ARG AEROSPIKE_PHP_REPOSITORY
|
||||
|
||||
RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \
|
||||
RUN set -xe; \
|
||||
if [ ${INSTALL_AEROSPIKE} = true ]; then \
|
||||
# Fix dependencies for PHPUnit within aerospike extension
|
||||
apt-get -y install sudo wget && \
|
||||
# Install the php aerospike extension
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz ${AEROSPIKE_PHP_REPOSITORY} \
|
||||
&& mkdir -p aerospike-client-php \
|
||||
&& tar -C aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php5/archive/master.tar.gz; \
|
||||
else \
|
||||
curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz; \
|
||||
fi \
|
||||
&& mkdir -p /tmp/aerospike-client-php \
|
||||
&& tar -C /tmp/aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \
|
||||
&& \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
( \
|
||||
cd aerospike-client-php/src/aerospike \
|
||||
cd /tmp/aerospike-client-php/src/aerospike \
|
||||
&& phpize \
|
||||
&& ./build.sh \
|
||||
&& make install \
|
||||
) \
|
||||
else \
|
||||
( \
|
||||
cd aerospike-client-php/src \
|
||||
cd /tmp/aerospike-client-php/src \
|
||||
&& phpize \
|
||||
&& ./build.sh \
|
||||
&& make install \
|
||||
@ -560,7 +672,7 @@ RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \
|
||||
&& echo 'extension=aerospike.so' >> /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/aerospike.ini \
|
||||
&& echo 'aerospike.udf.lua_system_path=/usr/local/aerospike/lua' >> /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/aerospike.ini \
|
||||
&& echo 'aerospike.udf.lua_user_path=/usr/local/aerospike/usr-lua' >> /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/aerospike.ini \
|
||||
;fi
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# PHP V8JS:
|
||||
@ -570,14 +682,19 @@ USER root
|
||||
|
||||
ARG INSTALL_V8JS=false
|
||||
|
||||
RUN if [ ${INSTALL_V8JS} = true ]; then \
|
||||
# Install the php V8JS extension
|
||||
RUN set -xe; \
|
||||
if [ ${INSTALL_V8JS} = true ]; then \
|
||||
add-apt-repository -y ppa:pinepain/libv8-archived \
|
||||
&& apt-get update -yqq \
|
||||
&& apt-get install -y php${LARADOCK_PHP_VERSION}-xml php${LARADOCK_PHP_VERSION}-dev php-pear libv8-5.4 \
|
||||
&& pecl install v8js \
|
||||
&& apt-get install -y libv8-5.4 && \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
pecl install v8js-0.6.4; \
|
||||
else \
|
||||
pecl install v8js; \
|
||||
fi \
|
||||
&& echo "extension=v8js.so" >> /etc/php/${LARADOCK_PHP_VERSION}/cli/php.ini \
|
||||
;fi
|
||||
&& php -m | grep -q 'v8js' \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Laravel Envoy:
|
||||
@ -596,7 +713,7 @@ RUN if [ ${INSTALL_LARAVEL_ENVOY} = true ]; then \
|
||||
# Laravel Installer:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
USER laradock
|
||||
|
||||
ARG COMPOSER_REPO_PACKAGIST
|
||||
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
|
||||
@ -675,7 +792,8 @@ RUN if [ ${INSTALL_LINUXBREW} = true ]; then \
|
||||
|
||||
ARG INSTALL_MSSQL=false
|
||||
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
RUN set -eux; \
|
||||
if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||
apt-get -y install php5.6-sybase freetds-bin freetds-common libsybdb5 \
|
||||
&& php -m | grep -q 'mssql' \
|
||||
@ -693,13 +811,17 @@ RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
ln -sfn /opt/mssql-tools/bin/bcp /usr/bin/bcp && \
|
||||
echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
|
||||
locale-gen && \
|
||||
pecl install sqlsrv pdo_sqlsrv && \
|
||||
if [ $(php -r "echo PHP_MINOR_VERSION;") = "0" ]; then \
|
||||
pecl install sqlsrv-5.3.0 pdo_sqlsrv-5.3.0 \
|
||||
;else \
|
||||
pecl install sqlsrv pdo_sqlsrv \
|
||||
;fi && \
|
||||
echo "extension=sqlsrv.so" > /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/20-sqlsrv.ini && \
|
||||
echo "extension=pdo_sqlsrv.so" > /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/20-pdo_sqlsrv.ini \
|
||||
&& php -m | grep -q 'sqlsrv' \
|
||||
&& php -m | grep -q 'pdo_sqlsrv' \
|
||||
;fi \
|
||||
;fi
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# Minio:
|
||||
@ -765,6 +887,23 @@ RUN if [ ${INSTALL_PYTHON} = true ]; then \
|
||||
&& python -m pip install --upgrade virtualenv \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# POWERLINE:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
ARG INSTALL_POWERLINE=false
|
||||
|
||||
RUN if [ ${INSTALL_POWERLINE} = true ]; then \
|
||||
if [ ${INSTALL_PYTHON} = true ]; then \
|
||||
python -m pip install --upgrade powerline-status && \
|
||||
echo "" >> /etc/bash.bashrc && \
|
||||
echo ". /usr/local/lib/python2.7/dist-packages/powerline/bindings/bash/powerline.sh" >> /etc/bash.bashrc \
|
||||
;fi \
|
||||
;fi
|
||||
|
||||
USER laradock
|
||||
|
||||
###########################################################################
|
||||
# ImageMagick:
|
||||
###########################################################################
|
||||
@ -809,15 +948,6 @@ RUN if [ ${INSTALL_PG_CLIENT} = true ]; then \
|
||||
&& apt-get -y install postgresql-client-10 \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# nasm
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
RUN apt-get update -yqq \
|
||||
&& apt-get -yqq install nasm
|
||||
|
||||
###########################################################################
|
||||
# Dusk Dependencies:
|
||||
###########################################################################
|
||||
@ -863,11 +993,75 @@ RUN if [ $INSTALL_PHALCON = true ]; then \
|
||||
&& rm -rf /tmp/cphalcon* \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# MySQL Client:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_MYSQL_CLIENT=false
|
||||
|
||||
RUN if [ ${INSTALL_MYSQL_CLIENT} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install mysql-client \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# ping:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_PING=false
|
||||
|
||||
RUN if [ ${INSTALL_PING} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install inetutils-ping \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# sshpass:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_SSHPASS=false
|
||||
|
||||
RUN if [ ${INSTALL_SSHPASS} = true ]; then \
|
||||
apt-get update -yqq && \
|
||||
apt-get -y install sshpass \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# FFMpeg:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_FFMPEG=false
|
||||
|
||||
RUN if [ ${INSTALL_FFMPEG} = true ]; then \
|
||||
apt-get -y install ffmpeg \
|
||||
;fi
|
||||
|
||||
###########################################################################
|
||||
# GNU Parallel:
|
||||
###########################################################################
|
||||
|
||||
USER root
|
||||
|
||||
ARG INSTALL_GNU_PARALLEL=false
|
||||
|
||||
RUN if [ ${INSTALL_GNU_PARALLEL} = true ]; then \
|
||||
apt-get -y install parallel \
|
||||
;fi
|
||||
|
||||
|
||||
###########################################################################
|
||||
# Check PHP version:
|
||||
###########################################################################
|
||||
|
||||
RUN php -v | head -n 1 | grep -q "PHP ${LARADOCK_PHP_VERSION}."
|
||||
RUN set -xe; php -v | head -n 1 | grep -q "PHP ${LARADOCK_PHP_VERSION}."
|
||||
|
||||
#
|
||||
#--------------------------------------------------------------------------
|
||||
|
@ -46,8 +46,8 @@ alias h="history"
|
||||
alias j="jobs"
|
||||
alias e='exit'
|
||||
alias c="clear"
|
||||
alias cla="clear && ls -l"
|
||||
alias cll="clear && ls -la"
|
||||
alias cla="clear && ls -la"
|
||||
alias cll="clear && ls -l"
|
||||
alias cls="clear && ls"
|
||||
alias code="cd /var/www"
|
||||
alias ea="vi ~/aliases.sh"
|
||||
@ -107,6 +107,13 @@ alias gd="git --no-pager diff"
|
||||
alias git-revert="git reset --hard && git clean -df"
|
||||
alias gs="git status"
|
||||
alias whoops="git reset --hard && git clean -df"
|
||||
alias glog="git log --oneline --decorate --graph"
|
||||
alias gloga="git log --oneline --decorate --graph --all"
|
||||
alias gsh="git show"
|
||||
alias grb="git rebase -i"
|
||||
alias gbr="git branch"
|
||||
alias gc="git commit"
|
||||
alias gck="git checkout"
|
||||
|
||||
# Create a new directory and enter it
|
||||
function mkd() {
|
||||
|
8
workspace/auth.json
Normal file
8
workspace/auth.json
Normal file
@ -0,0 +1,8 @@
|
||||
{
|
||||
"http-basic": {
|
||||
"repo.magento.com": {
|
||||
"username": "",
|
||||
"password": ""
|
||||
}
|
||||
}
|
||||
}
|
10
zookeeper/Dockerfile
Normal file
10
zookeeper/Dockerfile
Normal file
@ -0,0 +1,10 @@
|
||||
FROM zookeeper:latest
|
||||
|
||||
LABEL maintainer="Hyduan <hyduan96@qq.com>"
|
||||
|
||||
VOLUME /data
|
||||
VOLUME /datalog
|
||||
|
||||
EXPOSE 2181
|
||||
|
||||
CMD ["zookeeper"]
|
Reference in New Issue
Block a user