Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit 8ed1a17e authored by Jean-François HOVINNE's avatar Jean-François HOVINNE
Browse files

chore: Set dependency as optional, update readme (fixes #10)

parent f79582a8
No related branches found
Tags 1.0.4
1 merge request!10chore: Set dependency as optional, update readme (fixes #10)
ECGALAXY nodejs ECGALAXY nodejs
======================= ===============
Ansible role that installs Node.js. Ansible role that installs Node.js.
Requirements Requirements
------------ ------------
None. - On Ubuntu, the `gpg-agent` command, which can be provided by `ecgalaxy.common_packages`.
Role Variables Role Variables
-------------- --------------
- `nodejs_version`: Sets the Node.js version to install ("12.x", "13.x", "14.x", "15.x", etc.).
- `nodejs_version` - Set the version of Node.js to install ("12.x", "13.x", "14.x", "15.x", etc.). Version numbers from Nodesource: https://github.com/nodesource/distributions. Version numbers from Nodesource: https://github.com/nodesource/distributions.
Dependencies Dependencies
------------ ------------
- ecgalaxy.common_packages - optional: ecgalaxy.bootstrap
- optional: ecgalaxy.common_packages
Example Playbook Example Playbook
---------------- ----------------
- hosts: all - hosts: all
roles: roles:
- ecgalaxy.bootstrap
- ecgalaxy.common_packages
- ecgalaxy.nodejs - ecgalaxy.nodejs
One-liner
---------
bash <(curl -s https://code.europa.eu/-/snippets/1/raw/main/ansible-role.sh) ecgalaxy.nodejs
See [ansible-role](https://code.europa.eu/-/snippets/1) for instructions.
Please verify the script integrity first.
License License
------- -------
......
...@@ -22,5 +22,4 @@ galaxy_info: ...@@ -22,5 +22,4 @@ galaxy_info:
- nodejs - nodejs
- npm - npm
- yarn - yarn
dependencies: dependencies: []
- role: ecgalaxy.common_packages
--- ---
- name: Prepare - name: Prepare
hosts: all hosts: all
tasks: roles:
- name: Update apt cache - role: ecgalaxy.bootstrap
ansible.builtin.apt: update_cache=yes cache_valid_time=600 - role: ecgalaxy.common_packages
when: ansible_os_family == 'Debian'
changed_when: false
environment: environment:
http_proxy: "{{ lookup('env', 'http_proxy') }}" http_proxy: "{{ lookup('env', 'http_proxy') }}"
https_proxy: "{{ lookup('env', 'https_proxy') }}" https_proxy: "{{ lookup('env', 'https_proxy') }}"
......
--- ---
- ecgalaxy.bootstrap
- ecgalaxy.common_packages - ecgalaxy.common_packages
--- ---
- name: Prepare - name: Prepare
hosts: all hosts: all
tasks: roles:
- name: Update apt cache - role: ecgalaxy.bootstrap
ansible.builtin.apt: update_cache=yes cache_valid_time=600 - role: ecgalaxy.common_packages
when: ansible_os_family == 'Debian'
changed_when: false
environment: environment:
http_proxy: "{{ lookup('env', 'http_proxy') }}" http_proxy: "{{ lookup('env', 'http_proxy') }}"
https_proxy: "{{ lookup('env', 'https_proxy') }}" https_proxy: "{{ lookup('env', 'https_proxy') }}"
......
--- ---
- ecgalaxy.bootstrap
- ecgalaxy.common_packages - ecgalaxy.common_packages
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment