use node role instead of task #3
|
@ -2,4 +2,5 @@
|
||||||
|
|
||||||
- hosts: hubot
|
- hosts: hubot
|
||||||
roles:
|
roles:
|
||||||
|
- node
|
||||||
- hubot
|
- hubot
|
||||||
|
|
|
@ -9,6 +9,9 @@ You can deploy test instance using `Vagrantfile` attached to the role.
|
||||||
|
|
||||||
`ansible-playbook -b Playbooks/hubot.yml`
|
`ansible-playbook -b Playbooks/hubot.yml`
|
||||||
|
|
||||||
|
## Playbook
|
||||||
|
The playbook includes node role and deploys entire stack needed to run hubot. Additional role is also available in the Ansible roles repos in git.
|
||||||
|
|
||||||
|
|
||||||
## XMPP
|
## XMPP
|
||||||
Each new bot is created as a linux user with in its home path. It needs its own xmpp account.
|
Each new bot is created as a linux user with in its home path. It needs its own xmpp account.
|
||||||
|
|
|
@ -3,9 +3,7 @@
|
||||||
#HUBOT DEFAULT VARIABLES
|
#HUBOT DEFAULT VARIABLES
|
||||||
# used for hubot bots
|
# used for hubot bots
|
||||||
|
|
||||||
hubot_nodejs_version: '14'
|
nodejs_version: '18'
|
||||||
hubot_apt:
|
|
||||||
- nodejs
|
|
||||||
|
|
||||||
hubot_list:
|
hubot_list:
|
||||||
- hubot_name: myhubot1
|
- hubot_name: myhubot1
|
||||||
|
|
|
@ -1,18 +0,0 @@
|
||||||
---
|
|
||||||
|
|
||||||
- name: '[INSTALLDEPS] - Add Nodesource apt key.'
|
|
||||||
apt_key:
|
|
||||||
url: https://keyserver.ubuntu.com/pks/lookup?op=get&fingerprint=on&search=0x1655A0AB68576280
|
|
||||||
id: "68576280"
|
|
||||||
state: present
|
|
||||||
|
|
||||||
- name: '[INSTALLDEPS] - Add repository for nodejs'
|
|
||||||
apt_repository:
|
|
||||||
repo: deb https://deb.nodesource.com/node_{{ hubot_nodejs_version }}.x {{ ansible_distribution_release }} main
|
|
||||||
state: present
|
|
||||||
filename: 'nodesource'
|
|
||||||
|
|
||||||
- name: '[INSTALLDEPS] - Install dependencies'
|
|
||||||
apt:
|
|
||||||
name: "{{ hubot_apt }}"
|
|
||||||
update_cache: yes
|
|
|
@ -3,9 +3,6 @@
|
||||||
- name: Add user
|
- name: Add user
|
||||||
include_tasks: user.yml
|
include_tasks: user.yml
|
||||||
|
|
||||||
- name: Install and configure npm and nodejs
|
|
||||||
include_tasks: installdeps.yml
|
|
||||||
|
|
||||||
- name: Generate hubot instance
|
- name: Generate hubot instance
|
||||||
include_tasks: createhubot.yml
|
include_tasks: createhubot.yml
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue