Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3789925
D1931.id4878.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D1931.id4878.diff
View Options
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
+{%- 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 %}
diff --git a/roles/viperserv/eggdrop/files/rc/eggdrop b/roles/viperserv/eggdrop/files/rc/eggdrop
--- a/roles/viperserv/eggdrop/files/rc/eggdrop
+++ b/roles/viperserv/eggdrop/files/rc/eggdrop
@@ -86,7 +86,7 @@
eggdrop_chdir=${eggdrop_basedir}
home_directory=$(getent passwd $eggdrop_user | cut -d: -f6)
-eggdrop_env="HOME=$home_directory PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:$home_directory/bin"
+eggdrop_env="LC_ALL=en_US.UTF-8 MM_CHARSET=UTF-8 LANG=en_US.UTF-8 HOME=$home_directory PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:$home_directory/bin"
pidfile=$eggdrop_pidfile
command_args="$eggdrop_conf"
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 28, 03:59 (21 h, 15 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2268323
Default Alt Text
D1931.id4878.diff (2 KB)
Attached To
Mode
D1931: Allow eggdrops to connect to nickserv at runtime
Attached
Detach File
Event Timeline
Log In to Comment