Node 6.2.2 & node.bcrypt.js
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Dockerfile
- Sterne
- 8.6k
- Forks
- 2k
- Ø Merge
- 10 Std. 19 Min.
- Gemergte PRs (30 T.)
- 16
Beschreibung
When using bcrypt with this image you may run into a problem if you are mounting your local node_modules folder into your docker container. There may be times when you need to recompile C++ addons (which bcrypt has). So, to do this make sure that before your container starts executing code to run npm rebuild link.
I do this by building my container and then execing into it. I then manually run npm rebuild as I haven't found a better way to do this yet.
I hope this saves somebody else the hour I wasted trying to figure this out.
Edit
So an easier solution for docker compose is command: bash -c "npm rebuild && npm start" assuming npm start kicks off your server. This same method can be applied to a Dockerfile or the command line.
Edit2
Another, albeit uglier, solution is to mount the Host machines g++ compiler:
/usr/lib/x86_64-linux-gnu/:/usr/lib/x86_64-linux-gnu/
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Es wird keine Repository-Datei und kein Test genannt. Überprüfe die Dokumentation und die Dockerfile- oder Docker Compose-Einstiegspunkte für das Node 6.2.2-Image und verifiziere anschließend den dokumentierten bcrypt-Workaround, indem du npm rebuild vor npm start ausführst; abgeschlossen ist dies, wenn die Anleitung den Fall mit gemountetem node_modules klar erklärt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- docker, docker-compose, nodejs
- Bereich
- devops, documentation
- Issue-Typ
- Dokumentation
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 25/100