Category:Finance
/trunk
LedgerSMB is the primary accounting system we work with. Currently we use the 1.2 series in production. We are looking forward to 1.3 stabilizing, and plan to add on modules (payroll, custom material processing, etc) once it does.
Meanwhile here are install notes to put on a bare machine, basically a log of our demo instance. Note that you need to be quite careful about who has access to the raw data through phpPgAdmin (or any physical/shell access to the box) if you want to control access to the data.
Install on clean Ubuntu Gutsy
We're currently installing tagged versions from Subversion, rather than dealing with tarballs/etc. Works nearly the same on 6.06LTS (Dapper server).Steps from the shell:
sudo apt-get install libapache2-mod-php5 postgresql-8.1 perl apache2 subversion phppgadmin build-essential
sudo mkdir /usr/local/ledgersmb
cd /usr/local/ledgersmb
svn co https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/tags/1.2.12/ .
sudo apt-get installcat dists/deb/required_debs.txt
(accept most default cpan setups, aside from picking a location/mirror)
- sudo cpan install Config::Std
sudo apt-get install libmodule-build-perl libconfig-std-perl libclass-std-perl # .deb instead of cpan
- sudo cpan install Class::Std
sudo su - postgres
- sudo cpan install Module::Build
createuser --no-superuser --createdb --no-createrole \
-U postgres --pwprompt --encrypted ledgersmb
exit
sudo useradd ledgersmb
sudo passwd -l ledgersmb
sudo su - ledgersmb
createdb -U ledgersmb -O ledgersmb ledgersmb
psql -U ledgersmb -d ledgersmb -f /usr/local/ledgersmb/sql/Pg-central.sql
psql -U ledgersmb -d ledgersmb
UPDATE users_conf SET password = md5('mypassword') WHERE id = 1;
\qexit
sudo su - postgres
psql -U postgres -d ledgersmb
ALTER ROLE postgres PASSWORD 'mypassword';
\qexit
cd /usr/local/ledgersmb
cp ledgersmb.conf.default ledgersmb.conf
vi /usr/local/ledgersmb/ledgersmb.confsh configure_apache.sh
- update the [globaldb] appropriately
- Update apache:
www-data
- Which user does your web server run as?
/etc/apache2/sites-available/
- Where do we copy the ledgersmb-httpd.conf file to?
perl Build.PL
sudo vi /etc/postgresql/8.1/main/postgresql.conf
sudo /etc/init.d/postgresql-8.1 start
- change line to listen on localhost
- also change port to 5432
./Build test
sudo apt-get install libmodule-build-perl libconfig-std-perl
- output: Failed 2/6 test scripts, 66.67% okay. 37/1308 subtests failed, 97.17% okay.
sudo a2ensite ledgersmb-httpd.conf
sudo apache2ctl -t
sudo apache2ctl graceful
Then add users via the webui, strait from the readme:
Create Datasets and Users
=========================
- Create Datasets:
Browse to:
http://hostname/ledgersmb/admin.pl
login with 'MYPASSWORD'
Create dataset(s) with:
User: ledgersmb
Password: MYPASSWORDSuperuser: postgres
Password: (postgres password)Create one dataset (a postgresql datatabase) for each separate
company which will use LedgerSMB for accounting, e.g.:ledgeracme
ledgerbigco
(...)
2) Create User(s) pointing to specific datasets:Browse to:
http://hostname/ledgersmb/admin.pl
login with 'MYPASSWORD'
Create user(s) pointing to a specific dataset (ledgeracme, etc.)
with database login information:User: ledgersmb
Password: MYPASSWORDCongratulations, you have installed and configured LedgerSMB 1.2
Notes:
- Postgres 8.3 is not yet supported. 8.1 is currently recommended.
- We're installing as a regular user, and editing files directly through the file system. The web server user needs to be able to read and execute the appropriate files, because it currently runs under CGI.