Page MenuHomeDevCentral

D1931.id4877.diff
No OneTemporary

D1931.id4877.diff

diff --git a/pillar/viperserv/bots.sls b/pillar/viperserv/bots.sls
--- a/pillar/viperserv/bots.sls
+++ b/pillar/viperserv/bots.sls
@@ -29,6 +29,7 @@
- transfer
- filesys
- seen
+ nickserv: on
Wearg:
realname: RabbitMQ broker client
@@ -40,6 +41,7 @@
# startup components, with broker/Notifications
# dependencies
- Wearg/Time.tcl
+ nickserv: on
TC2:
realname: Tau Ceti Central
diff --git a/roles/viperserv/eggdrop/config.sls b/roles/viperserv/eggdrop/config.sls
--- a/roles/viperserv/eggdrop/config.sls
+++ b/roles/viperserv/eggdrop/config.sls
@@ -70,6 +70,7 @@
scripts: {{ bot['scripts'] }}
modules: {{ bot['modules'] | default([]) }}
runas: {{ bot['runas'] | default('viperserv') }}
+ nickserv: {{ bot['nickserv'] | default(False) }}
/srv/viperserv/{{ botname }}/motd:
file.managed:
diff --git a/roles/viperserv/eggdrop/files/eggdrop-bot.conf b/roles/viperserv/eggdrop/files/eggdrop-bot.conf
--- a/roles/viperserv/eggdrop/files/eggdrop-bot.conf
+++ b/roles/viperserv/eggdrop/files/eggdrop-bot.conf
@@ -43,9 +43,6 @@
set network freenode
set net-type 5
-set servers {
- chat.freenode.net:+6697
-}
# Main eggdrop settings common to all ViperServ bots
source core.conf
@@ -62,6 +59,26 @@
sql selectdb $sql(database)
sql2 selectdb $sql(database)
+# -------------------------------------------------------------
+# Base settings with scripts dependencies
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+# Dependencies
+source scripts/Core.tcl
+
+# Settings needing
+{% if nickserv %}
+set nickserv_password [registry get nickserv.$username.password]
+
+set servers {
+ chat.freenode.net:+6697:$usename:$nickserv_password
+}
+{% else %}
+set servers {
+ chat.freenode.net:+6697
+}
+{% endif %}
+
# -------------------------------------------------------------
# Eggdrop modules
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -74,7 +91,6 @@
# These scripts are provided by the rVIPER distribution.
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-source scripts/Core.tcl
source scripts/Tech.tcl
{% for script in scripts %}
source scripts/{{ script }}{% endfor %}

File Metadata

Mime Type
text/plain
Expires
Wed, Mar 5, 00:30 (5 h, 15 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2460404
Default Alt Text
D1931.id4877.diff (2 KB)

Event Timeline