Sha256: 597f129f4bab8b1cdfa01487a2355c346b48138ce60fbc141c12a808c9385469

Contents?: true

Size: 860 Bytes

Versions: 51

Compression:

Stored size: 860 Bytes

Contents

---
- name: Ensure apt-transport-https is installed.
  apt: name=apt-transport-https state=present

- name: Add Nodesource apt key.
  apt_key:
    url: https://keyserver.ubuntu.com/pks/lookup?op=get&fingerprint=on&search=0x1655A0AB68576280
    id: "68576280"
    state: present

- name: Add NodeSource repositories for Node.js.
  apt_repository:
    repo: "{{ item }}"
    state: present
  with_items:
    - "deb https://deb.nodesource.com/node_{{ nodejs_version }} {{ ansible_distribution_release }} main"
    - "deb-src https://deb.nodesource.com/node_{{ nodejs_version }} {{ ansible_distribution_release }} main"
  register: node_repo

- name: Update apt cache if repo was added.
  apt: update_cache=yes
  when: node_repo.changed

- name: Ensure Node.js and npm are installed.
  apt: "name=nodejs={{ nodejs_version|regex_replace('x', '') }}* state=present"

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
subspace-1.0.5 ansible/roles/nodejs/tasks/main.yml
subspace-1.0.4 ansible/roles/nodejs/tasks/main.yml
subspace-1.0.3 ansible/roles/nodejs/tasks/main.yml
subspace-1.0.2 ansible/roles/nodejs/tasks/main.yml
subspace-1.0.1 ansible/roles/nodejs/tasks/main.yml
subspace-1.0.0 ansible/roles/nodejs/tasks/main.yml
subspace-0.6.17 ansible/roles/nodejs/tasks/main.yml
subspace-0.6.16 ansible/roles/nodejs/tasks/main.yml
subspace-0.6.15 ansible/roles/nodejs/tasks/main.yml
subspace-0.5.15 ansible/roles/nodejs/tasks/main.yml
subspace-0.5.14 ansible/roles/nodejs/tasks/main.yml