From 996d52b185aabf128aea865f4b8c7741918014bd Mon Sep 17 00:00:00 2001 From: Andrew Shu Date: Wed, 18 Aug 2021 21:36:41 -0700 Subject: [PATCH] Use npm ci for Ansible task Otherwise Ansible never creates the node_modules directory. --- ansible/roles/nodejs/tasks/main.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ansible/roles/nodejs/tasks/main.yml b/ansible/roles/nodejs/tasks/main.yml index 2138af3..7336ede 100644 --- a/ansible/roles/nodejs/tasks/main.yml +++ b/ansible/roles/nodejs/tasks/main.yml @@ -18,3 +18,6 @@ # --no-bin-links option is needed to prevent npm from creating symlinks in the .bin # directory, which doesn't work inside Vagrant on Windows no_bin_links: true + # npm ci needs to be run, for a clean install, instead of npm install. + # otherwise node_modules is never created/updated (Ansible bug?) + ci: true