Changeset 27:b1d527287347 in mailjam for docs/src/install.rst


Ignore:
Timestamp:
May 23, 2012, 6:32:54 PM (12 years ago)
Author:
Borja Lopez <borja@…>
Branch:
default
Phase:
public
Message:

Added more information to the README file

Updated the architecture scheme so it fits the renaming of the project
to mailjam

Fixed the search path for configuration files. Now it searches on /etc
first, /usr/local/etc then.

Added more docs regarding the installation, configuration and running
of each component

File:
1 edited

Legend:

Unmodified
Added
Removed
  • docs/src/install.rst

    r16 r27  
    22=========================
    33
     4Installing Mailjam is quite easy. If you have some experience installing
     5Python_ packages [1]_, you already know how to do it. Mailjam is a standard
     6Python_ package available on pypi_ [3]_ so just use your favourite tool
     7(pip_, easy_install_, etc) to intall it.
     8
     9Keep reading if you want to learn more about the different options/choices
     10you have when installing Mailjam.
     11
    412.. contents::
    513
     
    1422*2.6.x* too.
    1523
    16 Please, refer to your operating system package system documentation to learn
    17 more about how to install python.
     24Please, refer to your operating system documentation to learn more about how
     25to install python.
    1826
    1927.. _install_mailjam:
     
    2230-----------------------
    2331
     32You can install Mailjam using one of the available tools for installing Python_
     33packages, or you can install it from sources. Keep reading to learn more about
     34it.
     35
    2436.. _install_with_pip:
    2537
     
    2941You can install Mailjam using pip_::
    3042
    31   pip install -e https://bitbucket.org/codigo23/mailjam#egg=mailjam
    32 
    33 .. note::
    34 
    35    Mailjam has not been recorded/uploaded to pypi_ yet, so, in order to install
    36    it using pip you will have to provide the URL for the public Mailjam repo.
     43  pip install Mailjam
     44
     45.. note::
     46
     47   The previous command will install the latest release from pypi_. If you
     48   would like to install the latest *bleeding edge* sources (unstable code),
     49   you can do it using pip_ too::
     50
     51     pip install -e https://bitbucket.org/codigo23/mailjam#egg=mailjam
    3752
    3853.. _install_with_easy_install:
     
    4156+++++++++++++++++++++++++++++
    4257
    43 You can not install Mailjam using easy_install_ yet (until we do record/upload
    44 it to pypi)
     58You can install Mailjam using easy_install_::
     59
     60  easy_install Mailjam
    4561
    4662.. _install_inside_virtualenv:
     
    6682And, once the environment has been activated, use pip to install Mailjam::
    6783
    68   env$ pip install -e https://bitbucket.org/codigo23/mailjam#egg=mailjam
     84  env$ pip install Mailjam
     85
     86.. note::
     87
     88   Remember that you can install the latest *bleeding edge* version using
     89   pip_ too::
     90   
     91     env$ pip install -e https://bitbucket.org/codigo23/mailjam#egg=mailjam
    6992
    7093.. _install_from_sources:
     
    82105********
    83106
    84 **There are no releases yet**. You will have to install it from the repository.
    85 
    86 .. _install_from_repository:
    87 
    88 From repository
    89 ***************
    90 
    91 The source code of Mailjam is hosted in bitbucket_ [1]_. In order to grab
    92 the latest sources you need Mercurial_.
    93 
    94 To get a copy of the sources, just *clone* the repository::
    95 
    96   hg clone https://bitbucket.org/codigo23/mailjam mailjam-repo
    97 
    98 Then, go inside the *mailjam-repo* directory and run::
     107You can grab a copy of the latest release from pypi_:
     108
     109http://pypi.python.org/packages/source/m/mailjam/
     110
     111After downloaded, you have to unpack the sources::
     112
     113  tar -zxvvf mailjam-0.1.0.tar.gz
     114
     115This will create a directory called *mailjam-0.1.0*, go inside that directory
     116and run::
    99117
    100118  python setup.py install
     
    110128   This process will work inside a virtualenv_ too.
    111129
     130.. _install_from_repository:
     131
     132From repository
     133***************
     134
     135The source code of Mailjam is hosted in bitbucket_ [2]_. In order to grab
     136the latest sources you need Mercurial_.
     137
     138To get a copy of the sources, just *clone* the repository::
     139
     140  hg clone https://bitbucket.org/codigo23/mailjam mailjam-repo
     141
     142Then, go inside the *mailjam-repo* directory and run::
     143
     144  python setup.py install
     145
     146.. warning::
     147
     148   If you want to install it *system-wide*, probably you will need *root*
     149   privileges (check your OS documentation to learn more about how to get
     150   *root* privileges - for example using sudo_)
     151
     152.. note::
     153
     154   This process will work inside a virtualenv_ too.
     155
    112156.. _install_setting_up_mailjam:
    113157
     
    115159------------------
    116160
    117 TBW
     161In order to setup Mailjam, you will have to create the needed
     162:doc:`configuration files <configuration>`. Each component has its own
     163configuration file:
     164
     165- The :ref:`Mailjam daemon <overview_mailjam_daemon>` configuration file is
     166  :ref:`mailjam.conf <configuration_daemon>`
     167
     168- The :ref:`Mailjam MTA client <overview_mailjam_mta_client>` configuration
     169  file is :ref:`mailjam-mta.conf <configuration_mta_client>`
     170
     171- The :ref:`Mailjam CLI client <overview_mailjam_cli_client>` configuration
     172  file is :ref:`mailjam-cli.conf <configuration_cli_client>`
     173
     174Refer to each configuration file documentation to learn more about the different
     175settings you can customize.
     176
     177Each component will search for its configuration file in a list of predefined
     178locations, but you can override that behaviour using the *-c* parameter when
     179starting the component.
     180
     181.. note::
     182
     183   Mailjam will search for the config files, in order, through the following
     184   paths:
     185
     186   1. /etc/mailjam
     187
     188   2. /etc
     189
     190   3. /usr/local/etc/mailjam
     191
     192   4. /usr/local/etc
     193
     194   5. the *conf* directory within the sources (or the installed *egg* [4]_)
     195
     196For example, you can start the :ref:`overview_mailjam_daemon` passing
     197*/var/db/mailjam/mailjam.conf* as its configuration file::
     198
     199  mailjam-server -c /var/db/mailjam/mailjam.conf
     200
     201.. seealso::
     202
     203   :doc:`running` contains more information about how to run the different
     204   components.
     205
     206If you have installed Mailjam using pip_, easy_install_ or even from sources,
     207the setup process should have taken care of the configuration files, adding
     208a copy of the default files included in the sources to the default
     209destination.
     210
     211.. warning::
     212
     213   The default destination will be different based on your operating system.
     214   For example, in most linux servers it will copy the files to */etc/mailjam*,
     215   while in BSD servers it will copy the files to */usr/local/etc/mailjam*.
     216
     217.. seealso::
     218
     219   :doc:`Configuration files, settings and formats documentation <configuration>`
     220
    118221
    119222.. _install_running_mailjam:
     
    122225---------------
    123226
    124 TBW
     227In order to run a full Mailjam environment, you will have to start the different
     228components separately:
     229
     2301. :ref:`Start the daemon <running_daemon>`
     231
     2322. :ref:`Run the cli client and manage your mailing lists <running_cli_client>`
     233
     2343. :ref:`Add as much MTA clients as you need to your mail server<running_mta_client>`
     235
     236The daemon will have to be running all the time (it is the component responsible
     237for providing information to the clients). You will need the CLI client to add,
     238edit or delete mailing lists and each MTA client will be responsible to handle
     239incoming emails for each mailing list.
    125240
    126241.. _install_running_tests:
     
    129244-------------------------------
    130245
    131 TBW
     246Just in case you were wondering, **yes**, Mailjam code has some tests you can
     247run to check everything is ok and that the software should run smoothly on your
     248server(s).
     249
     250To run the tests, simply get a copy of the sources from our public repository::
     251
     252  hg clone https://bitbucket.org/codigo23/mailjam mailjam-repo
     253
     254then run the tests::
     255
     256  cd mailjam-repo && ./bin/run_tests
     257
    132258
    133259.. _Python: http://python.org
     
    140266.. _sudo: http://sudo.ws
    141267
    142 .. [1] https://bitbucket.org/codigo23/mailjam
     268.. [1] http://docs.python.org/tutorial/modules.html#packages
     269.. [2] https://bitbucket.org/codigo23/mailjam
     270.. [3] http://pypi.python.org/pypi/mailjam
     271.. [4] http://svn.python.org/projects/sandbox/trunk/setuptools/doc/formats.txt
Note: See TracChangeset for help on using the changeset viewer.