root / docs / installation.rst @ 6283b4b4
History | View | Annotate | Download (5.2 kB)
1 | 457cb69b | Stavros Sachtouris | Installation |
---|---|---|---|
2 | 457cb69b | Stavros Sachtouris | ============ |
3 | 457cb69b | Stavros Sachtouris | |
4 | e96b3d4e | Stavros Sachtouris | This guide describes the standard installation process for kamaki, with the |
5 | e96b3d4e | Stavros Sachtouris | aspiration of covering as much cases as possible. Although kamaki was initially |
6 | e96b3d4e | Stavros Sachtouris | targeted to Linux/Unix-like users, it is quite straightforward to install and |
7 | abfaa6d9 | Vangelis Koukis | have it up and running in all platforms running Python 2.6 or 2.7. |
8 | 457cb69b | Stavros Sachtouris | |
9 | 5f5045b5 | Stavros Sachtouris | |
10 | 6283b4b4 | Vangelis Koukis | * Kamaki repository: `http://github.com/grnet/kamaki <http://github.com/grnet/kamaki>`_ |
11 | 2151584b | Stavros Sachtouris | |
12 | 6283b4b4 | Vangelis Koukis | * Kamaki at PyPI: `http://pypi.python.org/pypi/kamaki <https://pypi.python.org/pypi/kamaki>`_ |
13 | 8fbbaccc | Stavros Sachtouris | |
14 | e96b3d4e | Stavros Sachtouris | * Synnefo Linux packages: `http://apt.dev.grnet.gr <http://apt.dev.grnet.gr>`_ |
15 | 2151584b | Stavros Sachtouris | |
16 | 9360f398 | Stavros Sachtouris | Linux and Unix-like environments |
17 | 9360f398 | Stavros Sachtouris | -------------------------------- |
18 | 457cb69b | Stavros Sachtouris | |
19 | 7eda693f | Stavros Sachtouris | Debian: |
20 | 7eda693f | Stavros Sachtouris | ^^^^^^^ |
21 | ec3b8f78 | Stavros Sachtouris | |
22 | ec3b8f78 | Stavros Sachtouris | The following steps describe a command-line approach, but any graphic package manager can be used instead. |
23 | ec3b8f78 | Stavros Sachtouris | |
24 | 7eda693f | Stavros Sachtouris | * As root, append the following to */etc/apt/sources.list* :: |
25 | ec3b8f78 | Stavros Sachtouris | |
26 | e96b3d4e | Stavros Sachtouris | deb http://apt.dev.grnet.gr wheezy/ |
27 | e96b3d4e | Stavros Sachtouris | |
28 | e96b3d4e | Stavros Sachtouris | .. warning:: Debian Squeeze users may replace "wheezy" with "squeeze" |
29 | ec3b8f78 | Stavros Sachtouris | |
30 | 16d7b9ff | Stavros Sachtouris | * Make sure the GPG public key for the Synnefo repository is added: |
31 | ec3b8f78 | Stavros Sachtouris | |
32 | 7eda693f | Stavros Sachtouris | .. code-block:: console |
33 | ec3b8f78 | Stavros Sachtouris | |
34 | 7eda693f | Stavros Sachtouris | $ sudo curl https://dev.grnet.gr/files/apt-grnetdev.pub|apt-key add - |
35 | ec3b8f78 | Stavros Sachtouris | |
36 | 7eda693f | Stavros Sachtouris | otherwise *apt-get update* will produce GPG warnings. |
37 | ec3b8f78 | Stavros Sachtouris | |
38 | 7eda693f | Stavros Sachtouris | * Update the Debian sources: |
39 | ec3b8f78 | Stavros Sachtouris | |
40 | 7eda693f | Stavros Sachtouris | .. code-block:: console |
41 | ec3b8f78 | Stavros Sachtouris | |
42 | 7eda693f | Stavros Sachtouris | $ sudo apt-get update |
43 | ec3b8f78 | Stavros Sachtouris | |
44 | 7eda693f | Stavros Sachtouris | * Install kamaki: |
45 | ec3b8f78 | Stavros Sachtouris | |
46 | ec3b8f78 | Stavros Sachtouris | .. code-block:: console |
47 | ec3b8f78 | Stavros Sachtouris | |
48 | 7eda693f | Stavros Sachtouris | $ sudo apt-get install kamaki |
49 | ec3b8f78 | Stavros Sachtouris | |
50 | 7eda693f | Stavros Sachtouris | Ubuntu |
51 | 7eda693f | Stavros Sachtouris | ^^^^^^ |
52 | ec3b8f78 | Stavros Sachtouris | |
53 | abfaa6d9 | Vangelis Koukis | The following steps describe a command-line approach, but any graphic package |
54 | abfaa6d9 | Vangelis Koukis | manager can be used instead. |
55 | 7eda693f | Stavros Sachtouris | |
56 | 7eda693f | Stavros Sachtouris | * Let ppa take care of the repository configuration: |
57 | e3a1d743 | Stavros Sachtouris | |
58 | e3a1d743 | Stavros Sachtouris | .. code-block:: console |
59 | e3a1d743 | Stavros Sachtouris | |
60 | e3a1d743 | Stavros Sachtouris | $ sudo apt-get install python-software-properties |
61 | e3a1d743 | Stavros Sachtouris | $ sudo add-apt-repository ppa:grnet/synnefo |
62 | e3a1d743 | Stavros Sachtouris | |
63 | 7eda693f | Stavros Sachtouris | * Update the Debian sources: |
64 | ec3b8f78 | Stavros Sachtouris | |
65 | 7eda693f | Stavros Sachtouris | .. code-block:: console |
66 | ec3b8f78 | Stavros Sachtouris | |
67 | 7eda693f | Stavros Sachtouris | $ sudo apt-get update |
68 | ec3b8f78 | Stavros Sachtouris | |
69 | 7eda693f | Stavros Sachtouris | * Install kamaki: |
70 | ec3b8f78 | Stavros Sachtouris | |
71 | 7eda693f | Stavros Sachtouris | .. code-block:: console |
72 | ec3b8f78 | Stavros Sachtouris | |
73 | 7eda693f | Stavros Sachtouris | $ sudo apt-get install kamaki |
74 | ec3b8f78 | Stavros Sachtouris | |
75 | 4054c46d | Stavros Sachtouris | Install ansicolors (optional but recommended) |
76 | 4054c46d | Stavros Sachtouris | """"""""""""""""""""""""""""""""""""""""""""" |
77 | 8fbbaccc | Stavros Sachtouris | |
78 | 8fbbaccc | Stavros Sachtouris | .. code-block:: console |
79 | 8fbbaccc | Stavros Sachtouris | |
80 | 8fbbaccc | Stavros Sachtouris | $ sudo apt-get install python-ansicolors |
81 | 4054c46d | Stavros Sachtouris | |
82 | b3ba19ef | Stavros Sachtouris | |
83 | 8fbbaccc | Stavros Sachtouris | .. _installing-from-pypi-ref: |
84 | 5f5045b5 | Stavros Sachtouris | |
85 | 8fbbaccc | Stavros Sachtouris | Installing from pypi |
86 | 8fbbaccc | Stavros Sachtouris | ^^^^^^^^^^^^^^^^^^^^ |
87 | 457cb69b | Stavros Sachtouris | |
88 | 961e6040 | Stavros Sachtouris | Requirements |
89 | 961e6040 | Stavros Sachtouris | """""""""""" |
90 | 961e6040 | Stavros Sachtouris | |
91 | 961e6040 | Stavros Sachtouris | Essential: |
92 | 961e6040 | Stavros Sachtouris | |
93 | e96b3d4e | Stavros Sachtouris | * Python 2.6 or 2.7 [http://www.python.org] |
94 | 961e6040 | Stavros Sachtouris | * Python setuptools [http://pypi.python.org/pypi/setuptools] |
95 | 961e6040 | Stavros Sachtouris | |
96 | 961e6040 | Stavros Sachtouris | Optional: |
97 | 961e6040 | Stavros Sachtouris | |
98 | 961e6040 | Stavros Sachtouris | * VirtualEnv (python-virtualenv) [http://www.virtualenv.org] |
99 | 961e6040 | Stavros Sachtouris | |
100 | ec3b8f78 | Stavros Sachtouris | Setup a virtual enviroment (optional) |
101 | ec3b8f78 | Stavros Sachtouris | """"""""""""""""""""""""""""""""""""" |
102 | 5f5045b5 | Stavros Sachtouris | |
103 | 16d7b9ff | Stavros Sachtouris | Use virtualenv to setup kamaki and Synnefo services in a sandbox environment. |
104 | 2151584b | Stavros Sachtouris | |
105 | 2151584b | Stavros Sachtouris | .. code-block:: console |
106 | 2151584b | Stavros Sachtouris | |
107 | 2151584b | Stavros Sachtouris | $ virtualenv kamaki-env |
108 | 2151584b | Stavros Sachtouris | $ source kamaki-env/bin/activate |
109 | 2151584b | Stavros Sachtouris | |
110 | e96b3d4e | Stavros Sachtouris | A more detailed example of using virtual env can be found at the |
111 | e96b3d4e | Stavros Sachtouris | `snf-image-creator setup guide <http://www.synnefo.org/docs/snf-image-creator/latest/install.html#python-virtual-environment>`_ |
112 | 2151584b | Stavros Sachtouris | |
113 | ec3b8f78 | Stavros Sachtouris | Install kamaki |
114 | ec3b8f78 | Stavros Sachtouris | """""""""""""" |
115 | 2151584b | Stavros Sachtouris | |
116 | f5d9bc54 | Stavros Sachtouris | .. code-block:: console |
117 | e3a1d743 | Stavros Sachtouris | |
118 | 8fbbaccc | Stavros Sachtouris | $ pip install kamaki |
119 | 2151584b | Stavros Sachtouris | |
120 | 4054c46d | Stavros Sachtouris | Install ansicolors |
121 | 4054c46d | Stavros Sachtouris | """""""""""""""""" |
122 | 0d735aaf | Stavros Sachtouris | |
123 | 4054c46d | Stavros Sachtouris | The **ansicolors** package is not required for running kamaki, but it is |
124 | 4054c46d | Stavros Sachtouris | recommended as a user experience improvement. In specific, ansicolors |
125 | 4054c46d | Stavros Sachtouris | adds colors to kamaki responses. |
126 | 2151584b | Stavros Sachtouris | |
127 | 2151584b | Stavros Sachtouris | .. code-block:: console |
128 | 2151584b | Stavros Sachtouris | |
129 | 4054c46d | Stavros Sachtouris | $ pip install ansicolors |
130 | 0d735aaf | Stavros Sachtouris | |
131 | 0d735aaf | Stavros Sachtouris | |
132 | 5f5045b5 | Stavros Sachtouris | Mac OS X |
133 | 5f5045b5 | Stavros Sachtouris | -------- |
134 | 5f5045b5 | Stavros Sachtouris | |
135 | 2bd23362 | Stavros Sachtouris | Kamaki can be installed on Mac OS X systems, by following the steps |
136 | e96b3d4e | Stavros Sachtouris | at :ref:`installing-from-pypi-ref`. |
137 | 457cb69b | Stavros Sachtouris | |
138 | 457cb69b | Stavros Sachtouris | Windows |
139 | 457cb69b | Stavros Sachtouris | ------- |
140 | 457cb69b | Stavros Sachtouris | |
141 | e96b3d4e | Stavros Sachtouris | Kamaki can be installed on Windows by following the pypi method. Installing the |
142 | e96b3d4e | Stavros Sachtouris | requirements is a bit different than in other systems. |
143 | 8fbbaccc | Stavros Sachtouris | |
144 | 8fbbaccc | Stavros Sachtouris | The full process is detailed in the following: |
145 | 5c801047 | Stavros Sachtouris | |
146 | 5c801047 | Stavros Sachtouris | Requirements |
147 | 5c801047 | Stavros Sachtouris | ^^^^^^^^^^^^ |
148 | 5c801047 | Stavros Sachtouris | |
149 | 2813cdec | Stavros Sachtouris | * Python 2.7 (`Official versions <http://www.python.org/download>`_) |
150 | 5c801047 | Stavros Sachtouris | |
151 | b6a99832 | Stavros Sachtouris | * Setuptools (`Official versions and workarounds <http://pypi.python.org/pypi/setuptools>`_) |
152 | 5c801047 | Stavros Sachtouris | |
153 | 2bd23362 | Stavros Sachtouris | Users who have already set up python and setuptools (e.g., for |
154 | abfaa6d9 | Vangelis Koukis | another project) may skip Python and / or setuptools installation. |
155 | 5c801047 | Stavros Sachtouris | |
156 | abfaa6d9 | Vangelis Koukis | Install Python |
157 | 6539c700 | Stavros Sachtouris | ^^^^^^^^^^^^^^ |
158 | 5c801047 | Stavros Sachtouris | |
159 | e96b3d4e | Stavros Sachtouris | Download and run the Windows installer from |
160 | 2813cdec | Stavros Sachtouris | `here <http://www.python.org/download>`_ |
161 | 5c801047 | Stavros Sachtouris | |
162 | e96b3d4e | Stavros Sachtouris | Users should pick the installer that fits their windows version and machine |
163 | e96b3d4e | Stavros Sachtouris | architecture. |
164 | 5c801047 | Stavros Sachtouris | |
165 | abfaa6d9 | Vangelis Koukis | Add Python to windows path |
166 | 8fbbaccc | Stavros Sachtouris | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
167 | 5c801047 | Stavros Sachtouris | |
168 | abfaa6d9 | Vangelis Koukis | The following will allow users to run Python and Python scripts from command |
169 | e96b3d4e | Stavros Sachtouris | line. |
170 | 5c801047 | Stavros Sachtouris | |
171 | e96b3d4e | Stavros Sachtouris | * Select **System** from the Control Panel, select the **Advanced** tab, the |
172 | e96b3d4e | Stavros Sachtouris | **Environment Variables** button and then find the **PATH** (user or |
173 | e96b3d4e | Stavros Sachtouris | system) and **edit** |
174 | 5c801047 | Stavros Sachtouris | |
175 | b6a99832 | Stavros Sachtouris | * Without removing existing values, append the following to PATH:: |
176 | 5c801047 | Stavros Sachtouris | |
177 | e96b3d4e | Stavros Sachtouris | ;C:\Python27;C:\Python27\Scripts |
178 | 5c801047 | Stavros Sachtouris | |
179 | b6a99832 | Stavros Sachtouris | .. note:: Path values are separated by semicolons |
180 | 5c801047 | Stavros Sachtouris | |
181 | e96b3d4e | Stavros Sachtouris | .. warning:: In case of a different version, C:\\Python27 should be replaced |
182 | e96b3d4e | Stavros Sachtouris | with the actual python path in the system |
183 | 5c801047 | Stavros Sachtouris | |
184 | 5c801047 | Stavros Sachtouris | Install setuptools |
185 | 8fbbaccc | Stavros Sachtouris | ^^^^^^^^^^^^^^^^^^ |
186 | 5c801047 | Stavros Sachtouris | |
187 | e96b3d4e | Stavros Sachtouris | According to the corresponding |
188 | e96b3d4e | Stavros Sachtouris | `python org page <http://pypi.python.org/pypi/setuptools>`_, the setuptools |
189 | e96b3d4e | Stavros Sachtouris | installer doesn't currently work on 64bit machines. |
190 | 5c801047 | Stavros Sachtouris | |
191 | 2bd23362 | Stavros Sachtouris | * Users with 32-bit platforms should download and run the graphic |
192 | e96b3d4e | Stavros Sachtouris | installer |
193 | 5c801047 | Stavros Sachtouris | |
194 | 2bd23362 | Stavros Sachtouris | * Users with 64-bit platforms should download the |
195 | 2813cdec | Stavros Sachtouris | `ez_setup.py <https://bitbucket.org/pypa/setuptools/raw/bootstrap/ez_setup.py>`_ |
196 | 2813cdec | Stavros Sachtouris | script and install it from a command shell. In the following example, the |
197 | 2813cdec | Stavros Sachtouris | script was downloaded at C:\\Downloads:: |
198 | 5c801047 | Stavros Sachtouris | |
199 | e96b3d4e | Stavros Sachtouris | C:\> cd Downloads |
200 | e96b3d4e | Stavros Sachtouris | C:\Downloads\> python ez_setup.py |
201 | e96b3d4e | Stavros Sachtouris | ... |
202 | e96b3d4e | Stavros Sachtouris | Installation finished |
203 | e96b3d4e | Stavros Sachtouris | C:\Downloads\> |
204 | 5c801047 | Stavros Sachtouris | |
205 | 5c801047 | Stavros Sachtouris | Install kamaki |
206 | 8fbbaccc | Stavros Sachtouris | ^^^^^^^^^^^^^^ |
207 | 5c801047 | Stavros Sachtouris | |
208 | 8fbbaccc | Stavros Sachtouris | .. code-block:: console |
209 | 5c801047 | Stavros Sachtouris | |
210 | 98b03e18 | Stavros Sachtouris | $ easy_install kamaki |