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

added task to uninstall before installing new version - allows change… #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fubarhouse
Copy link

Allow function to change versions of Node.js if the nodejs version variable changes to allow seamless porting between the available versions.

Tested with DrupalVM on provision, and reprovision between both versions, and has no effect when install hasn't been previously executed from the playbook.

@@ -26,5 +26,8 @@
src: etc/apt/preferences.d/deb_nodesource_com_node.pref.2
dest: /etc/apt/preferences.d/deb_nodesource_com_node.pref

- name: Uninstall existing installations of Node.js
apt: name=nodejs state=absent

Choose a reason for hiding this comment

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

Is there some way of making this check it is necessary? It would be way too excessive to have node reinstall itself every time we run through ansible.

Copy link
Author

Choose a reason for hiding this comment

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

Since posting this issue I've created my own Ansible implementation of NVM and I no longer use nodesource.

If you were to do so, you should check for an existing install, register a variable with the currently installed version and provide some logic to determine if it should be uninstalled first.

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