mongoimport command not found while running code in docker using alpine image

I have a dockerfile for node js code as below

FROM node:10.14-alpine as buildcontainer


COPY source-code/config /home/app/config
COPY source-code/src /home/app/src
COPY source-code/package.json /home/app/package.json
COPY source-code/tsconfig.json /home/app/tsconfig.json
COPY source-code/tsconfig.build.json /home/app/tsconfig.build.json
WORKDIR /home/app
RUN npm install

FROM buildcontainer as tester
COPY . /home/app
WORKDIR /home/app

FROM tester as dev
WORKDIR /home/app
RUN npm run build
ENTRYPOINT ["/usr/local/bin/npm", "run", "start"]

Docker-compose file is below:-

version: '3.4'
services:
  mongodb-load-service:
    image: mongodb-load-service
    container_name: mongodb-load-service
    build:
      context: .
      target: dev
    ports:
      - "8080:8080"
    links:
      - mongo
    environment:
      - MONGODB_URI=mongodb://mongo/test
  mongo:
    image: mongo:latest
    container_name: mongo
    ports:
      - 27017:27017

Im using mongoimport command in node js code to import csv files in mongodb. The code runs fine when i run on local dev env.(without docker) but not when i run through docker compose file.

Error i get is:-

mongoimport command not found

In local dev env. i have installed below packages to run the code successfully:

sudo apt-get install -y mongodb-server-core
sudo apt install mongodb-clients
sudo apt install mongo-tools

But when i run the same commands through the Dockerfile using

RUN apk add mongodb-server-core

It gives some missing error.

Please help.

Source: StackOverflow