anope

- supernets anope source code & configuration
git clone git://git.acid.vegas/anope.git
Log | Files | Refs | Archive | README

MODULES (5008B)

      1 Anope Modules
      2 -------------
      3 
      4 1) Introduction
      5 2) Installation
      6 3) Usage
      7 4) Usage Example
      8 5) More Modules
      9 6) Support
     10 7) Information for Developers
     11 8) Modules Repository
     12 
     13 1) Introduction
     14 
     15     Anope 1.6 onwards supports external modules. External modules are pieces
     16     of code that can be attached to a running Anope process dynamically. These
     17     modules can serve several purposes, and perform all kind of operations to
     18     enhance your network.
     19 
     20 2) Installation
     21 
     22     1. If modules are supported by your system, they will be configured
     23        automatically when you run ./Config. The modules will be installed
     24        to the modules directory in your data path (by default this will
     25        be ~/services/data/modules).
     26 
     27     2. Compile Anope as usual using ./Config. The "make" process will now
     28        compile module support into Anope, and compile the default sample
     29        modules, and any other module located in the modules folder or any
     30        of its sub-directories, eg. modules/extra.
     31 
     32     3. Install Anope as usual. The "make install" process will place the
     33        compiled modules in their runtime location, making them available
     34        for loading.
     35 
     36     4. Start or restart services to make use of the new Anope executable.
     37        Note that you do not need to restart to load new or changed modules,
     38        only to make use of a new Anope executable.
     39 
     40 3) Usage
     41 
     42     All module manipulation commands are done through OperServ. These are:
     43 
     44        MODLOAD     Load a module
     45        MODRELOAD   Reload a module
     46        MODUNLOAD   Un-Load a module
     47        MODLIST     List loaded modules
     48        MODINFO     Info about a loaded module
     49 
     50     Access to the above commands require the operserv/modload and modlist
     51     permissions. Refer to operserv.example.conf.
     52 
     53     You can also load (and pre-load) Modules automatically by loading them
     54     on startup. To do so, edit any one of the configuration files (you may
     55     want to use modules.conf for third-party/extra modules, or a config
     56     file relevant to the *Serv your module operates on, eg. hostserv.conf),
     57     and use the following method to load a module on startup or reload:
     58         module { name="hs_modname" }
     59 
     60 4) Usage Example
     61 
     62     /msg OperServ modload ns_identify
     63     -OperServ- Module ns_identify loaded
     64 
     65     /msg OperServ modinfo ns_identify
     66     -OperServ- Module: ns_identify Version: 1.9.7 Author: Anope loaded: Jun 17 18:43:08 2012 BST (2 minutes ago)
     67     -OperServ-    Providing service: nickserv/identify
     68     -OperServ-    Command ID on NickServ is linked to nickserv/identify
     69     -OperServ-    Command IDENTIFY on NickServ is linked to nickserv/identify
     70 
     71     /msg OperServ modreload ns_identify
     72     -OperServ- Module ns_identify reloaded
     73 
     74     /msg OperServ modunload ns_identify
     75     -OperServ- Module ns_identify unloaded
     76 
     77     /msg NickServ IDENTIFY
     78     -NickServ- Unknown command identify. "/msg NickServ HELP" for help.
     79     NOTE: Doing the above, with the command still existing in a config file,
     80           will result in a log message, similar to the following:
     81           <@NickServ> Command IDENTIFY exists on me, but its service nickserv/identify was not found!
     82 
     83     * Note that the name of the module source file is "ns_identify.cpp", yet we
     84       load and reference the module as "ns_identify" only. By naming convention
     85       modules have an abbreviated service name they attach to (hs_ for
     86       HostServ, cs_ for ChanServ, etc) followed by a descriptive keyword.
     87 
     88 5) More Modules
     89 
     90     You can download more useful modules from https://modules.anope.org/. Just
     91     grab the module file (usually with a .cpp extension). Place the module
     92     file in your modules (anope-1.9.x/modules/third) folder; although any of
     93     the other folders within the modules directory will work.
     94 
     95     The new modules need to be compiled and installed before you can make
     96     use of them:
     97 
     98     1. Make sure you're in the main source directory. (usually anope-1.X.XX/)
     99     2. Run ./Config to find and configure modules, then `cd build`.
    100     3. Run `make` to compile Anope, and any modules.
    101     4. Run `make install` to copy the compiled binaries to the ~/services/
    102        directory.
    103 
    104     You can now use /msg OperServ MODLOAD to load the new modules.
    105 
    106 6) Support
    107 
    108     The Anope team is not responsible or liable for any unofficial module
    109     (i.e. anything other than what was released with the Anope package).
    110 
    111     Use modules at your own risk, and make sure you get them from a
    112     reputable source. You might get module support by contacting the module
    113     author, posting on our online forum, or maybe on our #anope channel
    114     at /server irc.anope.org.
    115 
    116 7) Information for Developers
    117 
    118     There are a number of useful documents on the Anope Wiki. The Anope Wiki
    119     can be reached at:
    120 
    121     * https://wiki.anope.org/
    122 
    123 8) Modules Repository
    124 
    125     You can find modules at https://modules.anope.org/
    126 
    127     These modules are 3rd party and as such are not supported by the Anope Team.
    128     Contact the Module Author directly with problems, not the Anope Team.