add role nodejs
This commit is contained in:
parent
51c5330e36
commit
0153384d76
1 changed files with 18 additions and 0 deletions
18
roles/nodejs/tasks/main.yml
Normal file
18
roles/nodejs/tasks/main.yml
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
---
|
||||||
|
- name: ensure apt key for nodejs is present
|
||||||
|
apt_key:
|
||||||
|
state: present
|
||||||
|
id: 68576280
|
||||||
|
url: "https://deb.nodesource.com/gpgkey/nodesource.gpg.key"
|
||||||
|
|
||||||
|
- name: ensure nodejs apt repo is present
|
||||||
|
apt_repository:
|
||||||
|
state: present
|
||||||
|
repo: "deb https://deb.nodesource.com/node_8.x stretch main"
|
||||||
|
update_cache: yes
|
||||||
|
filename: nodesource
|
||||||
|
|
||||||
|
- name: install nodejs package
|
||||||
|
package:
|
||||||
|
name: nodejs
|
||||||
|
state: present
|
Loading…
Reference in a new issue