Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#3380] Update dev image + code clean up #3392

Merged
merged 1 commit into from
Jan 15, 2020
Merged

Conversation

iperdomo
Copy link
Contributor

  • Update to the latest akvo/akvo-flow-builder image that is based
    on a published google/cloud-sdk
  • Remove references to ruby build process, e.g. RAKEP_MODE BUNDLE etc
    We're now using node to bundle our client application
  • Use npm ci instead of npm install as part of the build
    https://docs.npmjs.com/cli/ci.html
  • Cache $HOME/.npm to speed up builds

- Update to the latest akvo/akvo-flow-builder image that is based
  on a published google/cloud-sdk
- Remove references to ruby build process, e.g. RAKEP_MODE BUNDLE etc
  We're now using `node` to bundle our client application
- Use `npm ci` instead of `npm install` as part of the build
  https://docs.npmjs.com/cli/ci.html
- Cache `$HOME/.npm` to speed up builds
@iperdomo iperdomo requested a review from dlebrero January 15, 2020 06:24
@iperdomo iperdomo self-assigned this Jan 15, 2020
@@ -5,7 +5,8 @@ services:
- docker
cache:
directories:
- $HOME/.m2
- "$HOME/.m2"
- "$HOME/.npm"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For my information, what is stored here? I thought npm does not use a global path, but just messes around with the node_modules dir

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the documentation page

# keep the npm cache around to speed up installs
cache:
  directories:
  - "$HOME/.npm"

https://docs.npmjs.com/cli/ci.html

In a fresh container:

cd $HOME/.npm/
~/.npm # du -sh
43.6M	.

The actual content can be found here:
https://gist.github.com/iperdomo/042af3dafe282012e3cb66230a51da2b

npm ci deletes the local node_modules if exists, before installing the versions used in package-lock.json

@dlebrero dlebrero merged commit 1c17732 into develop Jan 15, 2020
@dlebrero dlebrero deleted the issue/3380-update-image branch January 15, 2020 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants