/ansible-role-node

Ansible role to install node using node version manager

MIT LicenseMIT

Ansible Role for NodeJS via NVM

License: MIT

This repo contains a Linux-distro agnostic Ansible role that installs NodeJS using NVM (Node Version Manager).

Requirements

  • No additional requirements.

  • ⚠️ Note: the role does not change your profile files (~/.bash_profile, ~/.zshrc, ~/.profile, or ~/.bashrc). Make sure that you have added following to the profile file for automatic nvm loading:

    export NVM_DIR="${HOME}/.nvm"
    [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"

Example Ansible Playbook

- hosts: 127.0.0.1
  roles:
    - role: ansible-role-node
      vars:
        nvm_node_version: 16 # Node version needs to be installed.
        nvm_npm_global_packages: # NPM global packages list.
          - eslint
          - eslint-config-airbnb
          - eslint-config-google

Author

👤 Alexander Danilenko

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2022 Alexander Danilenko.
This project is MIT licensed.


This README was generated with ❤️ by readme-md-generator