Differences between revisions 4 and 5
Revision 4 as of 2013-04-19 20:12:13
Size: 4185
Editor: xwuang
Comment: Add "Virtual Machine with Vagrant and Chef instructions" section.
Revision 5 as of 2013-04-19 22:31:11
Size: 2788
Editor: xwuang
Comment: remove build VM section from this page, it has moved to it's own page under development home
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
#pragma page-filename DEV/versions/15958220 #pragma page-filename DEV/versions/15564853
Line 69: Line 69:
=== Virtual Machine with Vagrant and Chef instructions ===

You can build a mailman3 development virtual machine with Vagrant and Chef-solo. The instructions, vagrantfiles, and mailman3 cookbooks are given at:

[[https://github.com/xuwang/mailman3-vbox|Build Mailman3 development virtual machines with Vagrant and Chef]]

Following mailman3 components will be installed on the virtual machine:

 * Mailman3 Core
 * init.d mailman service
 * Postfix hookup
 * Mailman3 test list
 * Mailman3 client
 * Mailman3 Postorius web interface
 * Apache2 mailman virtual host
You need [[http://docs.vagrantup.com/v2/getting-started/|Vagrant]] and [[https://www.virtualbox.org/|VirtualBox]] (not needed if for AWS EC2) to be installed on your working machine.
To build a local VM:
$ git clone [[https://github.com/xuwang/mailman3-vbox.git|https://github.com/xuwang/mailman3-vbox.git]]
$ cd [[https://github.com/xuwang/mailman3-vbox.git|m]]ailman3-vbox
$ cd vagrant
$ cp ./Vagrantfile.vbox Vagrantfile
$ vagrant up
Line 92: Line 70:
That's it. You can open postorius at [[http://localhost:8080|http://localhost:8080]],
 and you can login to postorius with admin/not-a-secret (you should change the default password in Vagrantfile)
<<BR>>
Or login in to the vm: 
$ vagrant ssh
To build a mailman3 box on AWS EC2, go to vagrant-aws and follow the instructions in README.md.



<<BR>>

By and large, setting up Mailman on a mac is the same as on linux, and you can use A 5 minute guide to get the Mailman web UI running.

However, the stock version of python does not work.  YOU WILL NEED TO INSTALL PYTHON FROM ANOTHER SOURCE.  Below are several possible ways to do this using macports, fink or homebrew.  YOU ONLY NEED TO FOLLOW ONE SET OF INSTRUCTIONS ON THIS PAGE.  Just make sure you have a version of python installed other than the mac default, and then make sure that it is the one being used.

Macports/Fink instructions

Install python 2.7.  The command is something like this for macports:

port install python27

And this for fink:

apt-get install python27

Make sure that the python you are using is this new version.  e.g. change the links in /usr/bin, edit your PATH so it comes first, etc.

Homebrew setup instructions

The below has you installing and using homebrew and virtualenv.  

$ ruby <(curl -fsSkL [[http://raw.github.com/mxcl/homebrew/go|raw.github.com/mxcl/homebrew/go]])
$ brew install python
$ echo "export PATH=/usr/local/share/python:$PATH" >> ~/.bash_profile
$ source ~/.bash_profile
$ brew install bazaar
$ pip install distribute

Install virtualenv and virtualenvrapper

$ pip install virtualenv
$ pip install virtualenvwrapper
$ echo "export WORKON_HOME=$HOME/.virtualenvs" >> ~/.bash_profile
$ echo "source `which virtualenvwrapper.sh`" >> ~/.bash_profile
$ export WORKON_HOME=$HOME/.virtualenvs
$ source virtualenvwrapper.sh ]] ></ac:plain-text-body>

Create the postortius virtual environment.

$ mkvirtualenv postorius
New python executable in postorius/bin/python
Installing setuptools............done.
Installing pip...............done.
virtualenvwrapper.user_scripts creating {your_home_directory}/.virtualenvs/postorius/bin/predeactivate
virtualenvwrapper.user_scripts creating {your_home_directory}/.virtualenvs/postorius/bin/postdeactivate
virtualenvwrapper.user_scripts creating {your_home_directory}/.virtualenvs/postorius/bin/preactivate
virtualenvwrapper.user_scripts creating {your_home_directory}/.virtualenvs/postorius/bin/postactivate
virtualenvwrapper.user_scripts creating {your_home_directory}/.virtualenvs/postorius/bin/get_env_details
(postorius) $

You should now see (postorius) before your prompt.

For setup on Windows, and more advanced setup, see the Virtualenvwrapper documentation: [[http://virtualenvwrapper.readthedocs.org/en/latest/install.html|http://virtualenvwrapper.readthedocs.org/en/latest/install.html]]


MailmanWiki: DEV/Mac Mailman development setup guide (last edited 2013-04-19 22:31:11 by xwuang)