Failed to build Firebase/Firestore module

Trying to deploy vui-cli with Firebase/Firestore.

All dependencies installed successfully. But npm run build failed

$ npm run build

node build/build.js
Hash: 7209d60e7a7c49d8cbf9
Version: webpack 3.8.1
Time: 37379ms
Asset Size Chunks Chunk Names
static/js/0.e2d85b5cb7c5b623e91c.js 607 kB 0 [emitted] [big]
static/js/vendor.b4a0ed5220d5e3a408c8.js 884 kB 1 [emitted] [big] vendor
static/js/app.a8a9bc2050362f6bb92e.js 5.59 kB 2 [emitted] app
static/js/manifest.39029a85475c7a30262d.js 1.51 kB 3 [emitted] manifest
static/css/app.e1759a5b8d2c26db590f90de279a98a6.css 195 bytes 2 [emitted] app
static/js/0.e2d85b5cb7c5b623e91c.js.map 1.22 MB 0 [emitted]
static/js/vendor.b4a0ed5220d5e3a408c8.js.map 5.94 MB 1 [emitted] vendor
static/js/app.a8a9bc2050362f6bb92e.js.map 47.8 kB 2 [emitted] app
static/js/manifest.39029a85475c7a30262d.js.map 14.3 kB 3 [emitted] manifest
index.html 558 bytes [emitted]
ERROR in ./src/data/firebase-config.js
Module not found: Error: Can’t resolve 'Firebase/firestore’ in ‘/builds/vue-spa/src/data’
@ ./src/data/firebase-config.js 2:0-28
@ ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/App.vue
@ ./src/App.vue
@ ./src/main.js
Build failed with errors.

Basic gitlab-ci.yml

build site:
image: node:6
stage: build
script:
- node -v
- npm install
- npm run build
artifacts:
expire_in: 1 week
paths:
- dist

Deploy

deploy:
image: alpine
stage: deploy
script:
- apk add --no-cache rsync openssh
- mkdir -p ~/.ssh
- echo “$SSH_PRIVATE_KEY” >> ~/.ssh/id_dsa
- chmod 600 ~/.ssh/id_dsa
- echo -e “Host *\n\tStrictHostKeyChecking no\n\n” > ~/.ssh/config
- rsync -rav --delete dist/ user@server.com:/your/project/path/

Does anyone run into the same problem? BTW Locally with Firebase Command Tools I can easily deploy.