INNER CODE UNIT · JavaScript

async

madlabsinc/mevn-cli · src/commands/dockerize/index.js:67

export default async () => {
  await showBanner('MEVN CLI', 'Light speed setup for MEVN stack based apps.');
  checkIfConfigFileExists();
  await validateInstallation('docker');

  // .mevnrc
  const { template } = fetchProjectConfig();

  // Get the respective file contents
  let dockerComposeTemplate = getFileContent('docker-compose.yml');
  let dockerFileTemplate = getFileContent('Dockerfile');

  // Create Dockerfile for client directory
  const clientDockerFilePath = path.join('client', 'Dockerfile');
  if (!fs.existsSync(clientDockerFilePath)) {
    if (template === 'Nuxt.js') {
      // docker-compose.yml
      dockerComposeTemplate[4] = `${' '.repeat(

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…