apiaryio / dredd-example

Example application using Dredd and CI
MIT License
85 stars 61 forks source link

Add Wercker and more #29

Closed honzajavorek closed 6 years ago

honzajavorek commented 6 years ago

Summer cleanup 😎

honzajavorek commented 6 years ago

@nadade @kylef Call for help 🙋‍♂️

I'm trying to make Wercker to npm install --no-optional, but the no optional flag seems to be ignored - it still installs protagonist:

...
export WERCKER_NPM_INSTALL_OPTIONS="--no-optional"
source "/pipeline/npm-install-83ebc85d-4d44-47f3-a21f-75237025acae/run.sh" < /dev/null
Using wercker cache
Creating $WERCKER_CACHE_DIR/wercker/npm
Configuring npm to use wercker cache
Starting npm install, try: 1
npm WARN deprecated json-schema-faker@0.5.0-rc13: Broken not support
npm WARN deprecated nomnom@1.5.2: Package no longer supported. Contact support@npmjs.com for more info.

> protagonist@1.6.8 install /pipeline/source/node_modules/protagonist
> node-gyp rebuild
...

Even if I tried to create my own step, it was still ignored and Wercker just installed the project as without --no-optional, compiling protagonist. Any ideas?

kylef commented 6 years ago

@honzajavorek I think this may be NPM bug: https://npm.community/t/npm-install-no-optional-not-actually-filtering-optionals-in-cli-6-0-1-or-6-1-0/257 / https://github.com/npm/npm/issues/17633#issuecomment-403938408

Perhaps you can work around the issue with having a package-lock.json generated without protagonist. Probably something you should do regardless due to transient dependency licensing approval.

honzajavorek commented 6 years ago

Oh, package-lock.json is a different can of worms I'll need to resolve later. Thanks for looking into it, I think I'm fine with Wercker installing protagonist now.