Projekt

Allgemein

Profil

Installation Ubuntu 1404 2 LTS » Historie » Version 1

G. Richardson, 03.07.2015 08:34

1 1 G. Richardson
h1. Installation Ubuntu 14.04.2 LTS
2
3
* kivitendo 3.2.1
4
* Postgres 9.3
5
* Apache 2.4.7
6
7
Basierierend auf Anleitung
8
https://www.kivitendo.de/doc/html/ch02s02.html
9
10
h2. Ubuntu vorbereiten
11
12
> sudo su -
13
> apt-get install apache2 libarchive-zip-perl libclone-perl \
14
> libconfig-std-perl libdatetime-perl libdbd-pg-perl libdbi-perl \
15
> libemail-address-perl  libemail-mime-perl libfcgi-perl libjson-perl \
16
> liblist-moreutils-perl libnet-smtp-ssl-perl libnet-sslglue-perl \
17
> libparams-validate-perl libpdf-api2-perl librose-db-object-perl \
18
> librose-db-perl librose-object-perl libsort-naturally-perl \
19
> libstring-shellquote-perl libtemplate-perl libtext-csv-xs-perl \
20
> libtext-iconv-perl liburi-perl libxml-writer-perl libyaml-perl \
21
> libimage-info-perl libgd-gd2-perl \
22
> libfile-copy-recursive-perl postgresql
23
> apt-get install build-essential
24
> cpan HTML::Restrict
25
26
h2. kivitendo per git installieren
27
28
> apt-get install git
29
30
> cd /usr/local/src/
31
> git clone https://github.com/kivitendo/kivitendo-erp.git
32
> cd kivitendo-erp/
33
> git checkout release-3.2.1
34
> ./scripts/installation_check.pl
35
36
> mkdir webdav
37
> chown -R www-data users spool webdav
38
> chown www-data templates users
39
> cp config/kivitendo.conf.default config/kivitendo.conf
40
> apt-get install vim
41
> vim config/kivitendo.conf
42
<pre>
43
[authentication]
44
admin_password = admin123
45
46
[authentication/database]
47
host     = 127.0.0.1
48
port     = 5432
49
db       = kivitendo_auth
50
user     = postgres
51
password =
52
53
</pre>
54
55
h2. Postgres konfigurieren
56
Datenbank konfigurieren, passwortloser Zugriff für lokalen Zugriff
57
58
> vim /etc/postgresql/9.3/main/pg_hba.conf
59
<pre>
60
local   all             postgres                                peer
61
local   all             all                                     peer
62
host    all             all             127.0.0.1/32            trust
63
host    all             all             ::1/128                 reject
64
</pre>
65
66
> service postgres reload
67
68
Zugriff testen:
69
> psql -U postgres -h 127.0.0.1 -p 5432
70
71
h2. Apache konfigurieren
72
> vim /etc/apache2/sites-available/default-ssl.conf
73
<pre>
74
AddHandler fcgid-script .fpl
75
AliasMatch ^/kivitendo-erp/[^/]+\.pl /usr/local/src/kivitendo-erp/dispatcher.fpl
76
Alias       /kivitendo-erp/          /usr/local/src/kivitendo-erp/
77
FcgidMaxRequestLen 10485760
78
79
<Directory /usr/local/src/kivitendo-erp>
80
  AllowOverride All
81
  Options ExecCGI Includes FollowSymlinks
82
  Require all granted
83
</Directory>
84
85
<DirectoryMatch /usr/local/src/kivitendo-erp/users>
86
  Order Deny,Allow
87
  Deny from All
88
</DirectoryMatch>
89
</pre>
90
91
> apt-get install libapache2-mod-fcgid
92
> a2enmod ssl
93
> a2enmod fcgid
94
> a2ensite default-ssl
95
> service apache2 reload
96
97
h2. kivitendo starten
98
99
https://localhost/kivitendo-erp/
100
101
102
h2. Backup
103
104
@#!/bin/bash
105
for i in datenbankname kivitendo_auth;
106
  do pg_dump -U postgres -h 127.0.0.1 $i > /backup/kivitendo/`date +%A`-$i.sql
107
done
108
pg_dumpall -U postgres -h 127.0.0.1  >  /backup/kivitendo/`date +%A`-dumpall.sql@