diff --git a/src/create.js b/src/create.js index 8591a68d..ba9d9d28 100644 --- a/src/create.js +++ b/src/create.js @@ -33,6 +33,9 @@ const createEnv = async function() { 'memcached': { 'image': images['memcached'], }, + 'redis': { + 'image': images['redis'], + }, 'nginx': { 'image': images['nginx'], 'expose': [ @@ -267,6 +270,7 @@ const createEnv = async function() { ], 'depends_on': [ 'memcached', + 'redis' ], 'networks': [ 'default', @@ -279,7 +283,7 @@ const createEnv = async function() { // Unlike Mac and Windows, Docker is a first class citizen on Linux // and doesn't have any kind of translation layer between users and the - // file system. Because of this the phpfpm container will be running as the + // file system. Because of this the phpfpm container will be running as the // wrong user. Here we setup the docker-compose.yml file to rebuild the // phpfpm container so that it runs as the user who created the project. if ( os.platform() == 'linux' ) { @@ -296,7 +300,7 @@ const createEnv = async function() { baseConfig.services.phpfpm.volumes.push( `~/.ssh:/home/${process.env.USER}/.ssh:cached` ); } else { - // the official containers for this project will have a www-data user. + // the official containers for this project will have a www-data user. baseConfig.services.phpfpm.volumes.push( '~/.ssh:/home/www-data/.ssh:cached' ); } diff --git a/src/image.js b/src/image.js index 660f467c..66d06ecb 100644 --- a/src/image.js +++ b/src/image.js @@ -24,7 +24,8 @@ const images = { 'wpsnapshots': '10up/wpsnapshots:dev', 'memcached': 'memcached:latest', 'nginx': 'nginx:latest', - 'elasticsearch': 'docker.elastic.co/elasticsearch/elasticsearch:5.6.16' + 'elasticsearch': 'docker.elastic.co/elasticsearch/elasticsearch:5.6.16', + 'redis': 'redis:latest' }; const help = function() { @@ -38,9 +39,9 @@ Updates any docker images used by your environment to the latest versions availa }; const update = function( image ) { - try { + try { execSync( `docker pull ${image}`, { stdio: 'inherit' } ); - } + } catch ( ex ) { }