Closed Bug 1388593 Opened 7 years ago Closed 7 years ago

use npm to manage all js deps

Categories

(Socorro :: Webapp, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: lonnen, Assigned: osmose)

Details

Attachments

(1 file)

package management will help make front end maintenance easier. projects like normandy have already adopted and integrated npm into their asset pipeline, and we could probably learn from their implementation.

see
https://github.com/mozilla/normandy/blob/master/recipe-server/webpack.config.js
We don't need webpack yet but we certainly need to start using django-npm (or whatever it's called so we can stop putting things like jquery.min.js into the repo). It'll be a good step forward.
Assignee: nobody → mkelly
The PR for this is ready to land; next steps are to update the deploy process to do the following:

- Install Node 8 and npm 5.
- Run `npm install` in the /webapp-django directory to pull in dependencies.

As long as those steps are performed before `manage.py collectstatic` is called, collectstatic should find and pull in the npm dependencies correctly.

Assigning to miles until those steps are done.
Assignee: mkelly → miles
The current npm installed on socorro nodes is 3.10.10, which corresponds to node 6.11.4. Cloudops conveniently hosts its own nodesource mirror - yay! We were previously using that for node 6.x., but it's simple to change to using the 8.x branch.

So this is really easy: https://github.com/mozilla/socorro-infra/pull/314!

I'm testing a stage deploy based on this version of socorro-infra right now. If all goes well, we can roll forward with your PR.
Update on the stage deploy: we're properly on node 8.7.0 and npm 5.4.2. Kicking this back to :osmose to deal with the webapp-django boostrap.sh [0] side of things.

[0]: https://github.com/mozilla-services/socorro/blob/master/webapp-django/bin/bootstrap.sh
Assignee: miles → mkelly
Commits pushed to master at https://github.com/mozilla-services/socorro

https://github.com/mozilla-services/socorro/commit/220f9a49deb9ea1ebe5d982ff84e82adc9e0d70b
Fix bug 1388593: Use NPM to manage frontend dependencies.

https://github.com/mozilla-services/socorro/commit/9f76491018c1c10e0aaa233697e526f4d5150e4c
Merge pull request #4042 from Osmose/frontend-resources

Fix bug 1388593: Use NPM to manage frontend dependencies.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
(In reply to Miles Crabill [:miles] from comment #5)
> Update on the stage deploy: we're properly on node 8.7.0 and npm 5.4.2.
> Kicking this back to :osmose to deal with the webapp-django boostrap.sh [0]
> side of things.
> 
> [0]:
> https://github.com/mozilla-services/socorro/blob/master/webapp-django/bin/
> bootstrap.sh

Upon review, we didn't find anything that needed to change in that file. The PR is landed, and this should go out with the next deploy.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: