How to install vue/cli app under docker

Hi there. From what I can tell, it seems like your confusion is in the command: portion of your docker-compose.yml
This is the command that docker-compose will run in your container after it is started, when you run the docker-compose up command.
Probably, you want to change that to npm run serve so when you bring up your cluster via docker-compose up, your vtasks_web container will start the webserver and make your app available.

The question you probably have now is “well how do I run npm-install in my vstasks_web container to install my npm dependencies, etc.?” The answer to that is via the docker-compose run command.

The sequence you might typically follow is:

docker-compose build #builds your images
docker-compose run --rm vtasks_web npm install #runs npm-install on a vtasks_web container, which will install your npm dependencies, and then removes the container. 
docker-compose up #bring up your cluster. this will then run `npm run serve` and start your server in the vtasks_web container, assuming your 'command:' entry in your docker-compose.yml is changed to "npm run serve"

A couple of notes about the docker-compose run command:

the command passed by run overrides the command defined in the service configuration (i.e. it won’t run whatever you have in the “command:” option in your docker-compose.yml, which in your case will presumably be ‘npm run serve’.)

[…] the command does not create any of the ports specified in the service configuration. This prevents port collisions with already-open ports. If you do want the service’s ports to be created and mapped to the host, specify the –service-ports flag (basically this means you can run a docker-run command even if you already have your cluster up, and it won’t interfere with the running containers’ networking/ports.)

Using volumes (which it appears you have configured already), the node_modules directory and anything else changed by npm install (package-lock.json perhaps) will persist on the host and be shared across container instances, and your source files on your host machine will be available to the container, so you should be good to go