forked from shinken-solutions/shinken
-
Notifications
You must be signed in to change notification settings - Fork 0
/
FOR_PACKAGERS
88 lines (55 loc) · 2.95 KB
/
FOR_PACKAGERS
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
=== THANKS :) ====
Hi,
First of all: THANKS for trying to make a package of Shinken :)
I try to make the setup.py useful to you. It will install the shinken
library to the classic python way (in site-package).
=== Requirements ===
You will need Python >=2.6
You will need the pycurl lib too. It must already have a package. If not, take it from pypi (easy_install)
=== First install, to skip the install script ===
* Create a user account and a group for shinken on your system (not necessary if using install script)::
useradd --user-group shinken
usermod --lock shinken
Install
-------
In fact you can install the application by using the `setup.py` script.
No compilation is needed!
`setup.py` will install the shinken library in the python path, create the
`/etc/shinken` and `/var/lib/shinken` directory (you can change them in
the `setup.cfg` file before launching `setup.py`). You will
need the `python-setuptools` package for it. Then just run::
sudo python setup.py install --install-scripts=/usr/bin/
Update
------
For this way you can launch ::
sudo python setup.py update --install-scripts=/usr/bin/
Remove
------
There is a script called clean.sh in the source directory for this task.
It contains relative paths so it should be run from within the source dir.
Beware, it will delete all Shinken related files!
Running
-------
The `setup.py` installs some `init.d` scripts, let's use them::
/etc/init.d/shinken-scheduler start
/etc/init.d/shinken-poller start
/etc/init.d/shinken-reactionner start
/etc/init.d/shinken-broker start
/etc/init.d/shinken-arbiter start
=== Create the Package ===
****** IN ORDER TO USER THE --ROOT FORTHE BUILDROOT, YOU MUST USE THE SETUPPACKAGE.PY isntead of the setup..py *******
You can change the place you want to put etc and var in the file setup_parameters.cfg. You can also change
the owner of theses dir (and ALL files in them) in this file.
But WARNING (bis): if you set a --root (example =/tmp/something) it will not update the owner of the /etc and /var directory (calling with a --root is for having all files to create a package, so you don't need changing owners).
Example when you call:
python setuppackage.py install --root=/tmp/something --record=INSTALLED_FILES --install-scripts=/usr/bin
(no trailing / for install_scripts)
You get all files to package in the file INSTALLED_FILES (and only the /tmp/moncul is changed, so it's ok for your system ;)).
The setup.py will also generate the bin/default/shinken file that will be install in /etc/default/shinken. In it, you get
all variables used by the init.d scripts. It will generate the etc and var directory with the values you give in the setup cfg file.
With the python lib + etc + var it should be ok :)
I don't know what more you need exactly, so please ask in the mailing list at
https://lists.sourceforge.net/lists/listinfo/shinken-devel
or directly via my email: naparuba@gmail.com
And again: thanks a lot, a tool without package is nothing :)
Jean