Available helper commands

Click on one of the commands for more info and an example.

Run docker-compose for the current project, setting the project name to the BASEHOST variable from the .env file

$ run up

Execute the php command inside the running php container, or inside a php-symfony container if none is running.

The working directory will be the current directory you are executing this command from.

eg.
$ php -v

Run the composer command inside the php docker container. The working directory will be the current directory you are executing this command from.

Your $HOME/.ssh and $HOME/.composer folders wil be mounted inside this container to enable you to make use of your ssh keys and composer cache.

eg.
$ composer require package_name

Create a new database inside the running mysql container with the given name (eg. 'symfony') and 'DEFAULT CHARSET utf8'.

eg.
$ create_db symfony

Execute a mysql command inside the running mysql container as the root user.

eg.
$ mysql "SELECT * FROM table_name;"

Execute the mysqldump command inside the running mysql container as the root user.

eg.
$ mysqldump db_name > export_file_name.sql

Import a given mysql file into a given database, inside the running mysql container as the root user.

eg.
$ mysqlimport db_name import_file_name.sql

Execute the nodejs command inside a nodejs container. The working directory will be the current directory you are executing this command from.

eg.
$ node js_file.js

Execute the npm command inside a nodejs container.

The working directory will be the current directory you are executing this command from. Your $HOME/.ssh and $HOME/.npm folders wil be mounted inside this container to enable you to make use of your ssh keys and npm cache.

eg.
$ npm install package_name

Execute the yarn command inside a nodejs container.

The working directory will be the current directory you are executing this command from. Your $HOME/.ssh and $HOME/.npm folders wil be mounted inside this container to enable you to make use of your ssh keys and npm cache.

eg.
$ yarn add package_name

Execute the redis-cli command in the running redis container.

eg.
$ redis-cli flushall