DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Cover image for fast mvp cli tool πŸ”« πŸ”«
Lucas.T
Lucas.T

Posted on

fast mvp cli tool πŸ”« πŸ”«

Hello dev community πŸ‘‹

A quick article to share with you my latest creation.


Lately several product ideas come in my mind and I thought to myself that I always use the same tools, languages, libraries to achieve my goals and create my web applications here are the main ones:

  • docker.
  • nodeJs (expressjs, mongodb with mongoose).
  • Vuejs.

Usually I create a repository for each service, that is to say I isolate the api, the front and the container in separate repositories but the disadvantage of this method is that the configuration takes some time and that’s not the goal I want it to be in a few seconds and with some manipulations I'll like to have a dev environment ready to go !

So here's my solution:

A command line tool that allows me to create a repoitory following a template and clone this folder locally in order to run a single command to have my dev environment ready.

What you need:

  • Working with a macos operating system.
  • Docker.
  • Nodejs >= 12.0.0.
  • vue-cli installed globally on your computer.
  • Github token.!

What you get:

  • Fresh new project connected to a fresh new repo.
  • Docker with docker-compose to run all your services.
  • Mongodb instance.
  • If using mongodb atlas script to dumb database in mongo container.
  • Redis instance.
  • Nodejs API ready to use with expressjs.
  • Vuejs app with vue-cli.
  • Eslint airbnb config.
  • Prettier config.
  • ...

Here is the structure of your project:

└── .github/ // github metadata
└── api/
    β”œβ”€β”€ .eslintrc.json
    β”œβ”€β”€ .prettierignore
    β”œβ”€β”€ .prettierrc.json
    β”œβ”€β”€ dockerfile
    β”œβ”€β”€ index.js
    β”œβ”€β”€ nodemon.json
    β”œβ”€β”€ package.json
└── client/
    β”œβ”€β”€ dockerfile
    // vue-cli boilerplate.
β”œβ”€β”€ .dockerignore
β”œβ”€β”€ .gitignore
β”œβ”€β”€ LICENSE
β”œβ”€β”€ bdd.sh
β”œβ”€β”€ docker-compose.yml
β”œβ”€β”€ redis.conf
β”œβ”€β”€ README.md
Enter fullscreen mode Exit fullscreen mode

How to use it:

Install
Install the project globally:

npm i -g fast-mvp-cli
Enter fullscreen mode Exit fullscreen mode

Run process

fast-mvp-cli
Enter fullscreen mode Exit fullscreen mode

Or with npx required npm >= v5.2

npx fast-mvp-cli
Enter fullscreen mode Exit fullscreen mode

Once it's done, just follow the process πŸ™‚

process of fast-mvp-cli package

For those curious, do not hesitate to contribute:

Thank's :)

Top comments (0)

We are hiring! Do you want to be our Senior Platform Engineer? Forem is hiring a Senior Platform Engineer

If you're interested in ops and site reliability and capable of dipping in to our Linux stack, we'd love your help shoring up our systems!