Unverified Commit bbedaf42 authored by Sebastian Castro's avatar Sebastian Castro
Browse files

docker: improve performance on mac

parent 21452f43
.git
.gitignore
.htaccess
/tests
/docs
\ No newline at end of file
......@@ -12,7 +12,7 @@ ssh_password
*~
.idea
/web/matomo/
/docker/docker-compose.local.yml
docker-compose.local.yml
/custom/
###> symfony/framework-bundle ###
......
v3.2.7
======
* BREAKING CHANGE: the docker-composer.yml has been moved to the root of the project. If you have any docker-compose.local.yml, please move it also to the root
v3.2.1
======
* MAJOR: The way of managing SAAS instance cron jobs have changed. In your main database run `db.Project.updateMany({}, {$currentDate: {nextUpdateAt: true}})` and check `docs/installation.md` for new cron jobs configuration
......
......@@ -8,10 +8,10 @@ GIT = git
GULP = gulp
YARN = yarn
DOCKER = docker-compose
DOCKER_COMPOSE= $$( if [ -f docker/docker-compose.local.yml ]; then \
echo docker/docker-compose.local.yml; \
DOCKER_COMPOSE= $$( if [ -f docker-compose.local.yml ]; then \
echo docker-compose.local.yml; \
else \
echo docker/docker-compose.yml; \
echo docker-compose.yml; \
fi )
.DEFAULT_GOAL = help
......@@ -39,17 +39,7 @@ warmup: ## Warmump the cache
$(SYMFONY) cache:warmup
fix-perms: ## Fix permissions of all var files
chown -R gogocarto var/cache
chown -R gogocarto var/log
chown -R gogocarto var/sessions
chown -R gogocarto web/uploads
chmod 777 -R var/
sleep 10 && chmod 777 -R var/ &
sleep 60 && chmod 777 -R var/ &
sleep 120 && chmod 777 -R var/ &
sleep 300 && chmod 777 -R var/ &
sleep 600 && chmod 777 -R var/ &
sleep 2000 && chmod 777 -R var/ &
install-assets: ## Install the assets
$(SYMFONY) assets:install web/ --symlink
......@@ -89,7 +79,7 @@ shell: ## Start shell inside Docker
commands: ## Display all commands in the project namespace
$(SYMFONY) list $(PROJECT)
init: install assets load-fixtures ## Initialize the project
init: install assets load-fixtures purge fix-perms ## Initialize the project
install: composer-install yarn-install ## Install vendors
......
version: '3'
services:
gogocarto:
build: server
build:
context: .
dockerfile: docker/Dockerfile
depends_on:
- mongo
container_name: gogocarto
volumes:
- ..:/var/www
volumes:
- .:/var/www:cached
- /var/www/var/cache
- /var/www/var/log
- /var/www/var/sessions
- /var/www/web/uploads
- ./vendor:/var/www/html/vendor:delegated
- ./node_modules:/var/www/html/node_modules:delegated
ports:
- "3008:80"
links:
- mongo:mongo
tty: true
mongo:
image: shikhir/alpine-mongodb
......@@ -24,7 +28,6 @@ services:
- mongo:/data/mongodb
ports:
- "27017:27017"
tty: true
volumes:
mongo: {}
......@@ -97,8 +97,8 @@ RUN npm install -g gulp
RUN npm install -g yarn
# Config files
COPY custom-php-conf.ini /usr/local/etc/php/conf.d/
COPY apache.conf /etc/apache2/sites-available/000-default.conf
COPY docker/custom-php-conf.ini /usr/local/etc/php/conf.d/
COPY docker/apache.conf /etc/apache2/sites-available/000-default.conf
# We don't need this directory
RUN rm -R /var/www/html
......
date.timezone = "Europe/Paris"
memory_limit = 1000M
default_socket_timeout = 300
max_execution_time = 300
zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts-20180731/xdebug.so
xdebug.remote_enable=1
......
......@@ -20,7 +20,7 @@ With the Docker installation, you have all the required softwares installed in t
### Local docker-compose
If you have a specific environment, need for custom env vars, want to avoid exposing ports, etc, you can create a copy of `docker/docker-compose.yml` named `docker/docker-compose.local.yml` (it will be gitignored).
If you have a specific environment, need for custom env vars, want to avoid exposing ports, etc, you can create a copy of `docker-compose.yml` named `docker-compose.local.yml` (it will be gitignored).
Manual Install
......@@ -34,7 +34,7 @@ Main requirements are :
4. [MongoDB](http://php.net/manual/fr/mongodb.installation.php)
5. Web Server (Apache, Nginx)
Please refer to the dockerfile to know all dependencies : [DockerFile](../docker/server/Dockerfile)
Please refer to the dockerfile to know all dependencies : [DockerFile](../docker/Dockerfile)
You can also check [the Debian Buster Installation Guide](./installation_debian.md)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment