blob: 3c77f4d793c663f3b90ab82d6c8451503b964547 [file] [log] [blame]
Dean Troyer0986a7b2014-10-29 22:08:13 -05001=============
2Configuration
3=============
Sean M. Collins09e550c2014-10-21 11:40:08 -04004
Ian Wienand815db162015-08-06 10:25:45 +10005.. contents::
6 :local:
7 :depth: 1
8
Sean M. Collins09e550c2014-10-21 11:40:08 -04009local.conf
Sean Dague07d7e5b2014-11-17 07:10:14 -050010==========
Sean M. Collins09e550c2014-10-21 11:40:08 -040011
Ian Wienanda35391e2015-08-10 13:53:40 +100012DevStack configuration is modified via the file ``local.conf``. It is
13a modified INI format file that introduces a meta-section header to
14carry additional information regarding the configuration files to be
15changed.
16
17A sample is provided in ``devstack/samples``
Sean M. Collins09e550c2014-10-21 11:40:08 -040018
19The new header is similar to a normal INI section header but with double
20brackets (``[[ ... ]]``) and two internal fields separated by a pipe
dieterly7c7679e2015-09-18 15:10:48 -060021(``|``). Note that there are no spaces between the double brackets and the
22internal fields. Likewise, there are no spaces between the pipe and the
23internal fields:
Sean M. Collins09e550c2014-10-21 11:40:08 -040024::
25
dieterly7c7679e2015-09-18 15:10:48 -060026 '[[' <phase> '|' <config-file-name> ']]'
Sean M. Collins09e550c2014-10-21 11:40:08 -040027
28where ``<phase>`` is one of a set of phase names defined by ``stack.sh``
29and ``<config-file-name>`` is the configuration filename. The filename
30is eval'ed in the ``stack.sh`` context so all environment variables are
31available and may be used. Using the project config file variables in
32the header is strongly suggested (see the ``NOVA_CONF`` example below).
33If the path of the config file does not exist it is skipped.
34
35The defined phases are:
36
37- **local** - extracts ``localrc`` from ``local.conf`` before
38 ``stackrc`` is sourced
39- **pre-install** - runs after the system packages are installed but
40 before any of the source repositories are installed
41- **install** - runs immediately after the repo installations are
42 complete
43- **post-config** - runs after the layer 2 services are configured and
44 before they are started
45- **extra** - runs after services are started and before any files in
46 ``extra.d`` are executed
YAMAMOTO Takashi961643e2015-07-31 13:45:27 +090047- **post-extra** - runs after files in ``extra.d`` are executed
Sean M. Collins09e550c2014-10-21 11:40:08 -040048
49The file is processed strictly in sequence; meta-sections may be
50specified more than once but if any settings are duplicated the last to
51appear in the file will be used.
52
53::
54
55 [[post-config|$NOVA_CONF]]
56 [DEFAULT]
57 use_syslog = True
58
59 [osapi_v3]
60 enabled = False
61
62A specific meta-section ``local|localrc`` is used to provide a default
63``localrc`` file (actually ``.localrc.auto``). This allows all custom
64settings for DevStack to be contained in a single file. If ``localrc``
Ian Wienand7cd16ce2016-04-08 09:40:56 +100065exists it will be used instead to preserve backward-compatibility.
Sean M. Collins09e550c2014-10-21 11:40:08 -040066
67::
68
69 [[local|localrc]]
70 FIXED_RANGE=10.254.1.0/24
71 ADMIN_PASSWORD=speciale
72 LOGFILE=$DEST/logs/stack.sh.log
73
74Note that ``Q_PLUGIN_CONF_FILE`` is unique in that it is assumed to
75*NOT* start with a ``/`` (slash) character. A slash will need to be
76added:
77
78::
79
80 [[post-config|/$Q_PLUGIN_CONF_FILE]]
81
82Also note that the ``localrc`` section is sourced as a shell script
Juan Antonio Osorio Roblesfe6dccb2014-11-28 13:12:14 +020083fragment and MUST conform to the shell requirements, specifically no
Sean M. Collins09e550c2014-10-21 11:40:08 -040084whitespace around ``=`` (equals).
85
Ian Wienand7cd16ce2016-04-08 09:40:56 +100086openrc
87======
88
89``openrc`` configures login credentials suitable for use with the
90OpenStack command-line tools. ``openrc`` sources ``stackrc`` at the
91beginning (which in turn sources the ``localrc`` section of
92``local.conf``) in order to pick up ``HOST_IP`` and/or ``SERVICE_HOST``
93to use in the endpoints. The values shown below are the default values.
94
95OS\_PROJECT\_NAME (OS\_TENANT\_NAME)
96 Keystone has
97 standardized the term *project* as the entity that owns resources. In
98 some places references still exist to the previous term
99 *tenant* for this use. Also, *project\_name* is preferred to
100 *project\_id*. OS\_TENANT\_NAME remains supported for compatibility
101 with older tools.
102
103 ::
104
105 OS_PROJECT_NAME=demo
106
107OS\_USERNAME
108 In addition to the owning entity (project), OpenStack calls the entity
109 performing the action *user*.
110
111 ::
112
113 OS_USERNAME=demo
114
115OS\_PASSWORD
116 Keystone's default authentication requires a password be provided.
117 The usual cautions about putting passwords in environment variables
118 apply, for most DevStack uses this may be an acceptable tradeoff.
119
120 ::
121
122 OS_PASSWORD=secret
123
124HOST\_IP, SERVICE\_HOST
125 Set API endpoint host using ``HOST_IP``. ``SERVICE_HOST`` may also
126 be used to specify the endpoint, which is convenient for some
127 ``local.conf`` configurations. Typically, ``HOST_IP`` is set in the
128 ``localrc`` section.
129
130 ::
131
132 HOST_IP=127.0.0.1
133 SERVICE_HOST=$HOST_IP
134
135OS\_AUTH\_URL
136 Authenticating against an OpenStack cloud using Keystone returns a
137 *Token* and *Service Catalog*. The catalog contains the endpoints
138 for all services the user/tenant has access to - including Nova,
139 Glance, Keystone and Swift.
140
141 ::
142
143 OS_AUTH_URL=http://$SERVICE_HOST:5000/v2.0
144
145KEYSTONECLIENT\_DEBUG, NOVACLIENT\_DEBUG
146 Set command-line client log level to ``DEBUG``. These are commented
147 out by default.
148
149 ::
150
151 # export KEYSTONECLIENT_DEBUG=1
152 # export NOVACLIENT_DEBUG=1
153
154
155
James Polley5f2eb6d2015-03-30 17:36:26 +1100156.. _minimal-configuration:
157
Sean M. Collins09e550c2014-10-21 11:40:08 -0400158Minimal Configuration
Sean Dague07d7e5b2014-11-17 07:10:14 -0500159=====================
Sean M. Collins09e550c2014-10-21 11:40:08 -0400160
161While ``stack.sh`` is happy to run without a ``localrc`` section in
162``local.conf``, devlife is better when there are a few minimal variables
163set. This is an example of a minimal configuration that touches the
164values that most often need to be set.
165
166- no logging
167- pre-set the passwords to prevent interactive prompts
168- move network ranges away from the local network (``FIXED_RANGE`` and
169 ``FLOATING_RANGE``, commented out below)
170- set the host IP if detection is unreliable (``HOST_IP``, commented
171 out below)
172
173::
174
175 [[local|localrc]]
Balagopal7ed812c2016-03-01 04:43:31 +0000176 ADMIN_PASSWORD=secret
Sean M. Collins09e550c2014-10-21 11:40:08 -0400177 DATABASE_PASSWORD=$ADMIN_PASSWORD
178 RABBIT_PASSWORD=$ADMIN_PASSWORD
179 SERVICE_PASSWORD=$ADMIN_PASSWORD
Sean M. Collins09e550c2014-10-21 11:40:08 -0400180 #FIXED_RANGE=172.31.1.0/24
181 #FLOATING_RANGE=192.168.20.0/25
182 #HOST_IP=10.3.4.5
183
184If the ``*_PASSWORD`` variables are not set here you will be prompted to
185enter values for them by ``stack.sh``.
186
187The network ranges must not overlap with any networks in use on the
188host. Overlap is not uncommon as RFC-1918 'private' ranges are commonly
189used for both the local networking and Nova's fixed and floating ranges.
190
191``HOST_IP`` is normally detected on the first run of ``stack.sh`` but
192often is indeterminate on later runs due to the IP being moved from an
Juan Antonio Osorio Roblesfe6dccb2014-11-28 13:12:14 +0200193Ethernet interface to a bridge on the host. Setting it here also makes it
Sean M. Collins09e550c2014-10-21 11:40:08 -0400194available for ``openrc`` to set ``OS_AUTH_URL``. ``HOST_IP`` is not set
195by default.
196
Brian Haley180f5eb2015-06-16 13:14:31 -0400197``HOST_IPV6`` is normally detected on the first run of ``stack.sh`` but
198will not be set if there is no IPv6 address on the default Ethernet interface.
199Setting it here also makes it available for ``openrc`` to set ``OS_AUTH_URL``.
200``HOST_IPV6`` is not set by default.
201
Ian Wienanda35391e2015-08-10 13:53:40 +1000202Historical Notes
203================
Ian Wienand7d5be292015-08-10 13:39:17 +1000204
Ian Wienanda35391e2015-08-10 13:53:40 +1000205Historically DevStack obtained all local configuration and
206customizations from a ``localrc`` file. In Oct 2013 the
207``local.conf`` configuration method was introduced (in `review 46768
208<https://review.openstack.org/#/c/46768/>`__) to simplify this
209process.
Ian Wienand7d5be292015-08-10 13:39:17 +1000210
Ian Wienand815db162015-08-06 10:25:45 +1000211Configuration Notes
212===================
213
214.. contents::
215 :local:
Sean M. Collins09e550c2014-10-21 11:40:08 -0400216
Ian Wienand7cd16ce2016-04-08 09:40:56 +1000217Service Repos
218-------------
219
220The Git repositories used to check out the source for each service are
221controlled by a pair of variables set for each service. ``*_REPO``
222points to the repository and ``*_BRANCH`` selects which branch to
223check out. These may be overridden in ``local.conf`` to pull source
224from a different repo for testing, such as a Gerrit branch
225proposal. ``GIT_BASE`` points to the primary repository server.
226
227 ::
228
229 NOVA_REPO=$GIT_BASE/openstack/nova.git
230 NOVA_BRANCH=master
231
232To pull a branch directly from Gerrit, get the repo and branch from
233the Gerrit review page:
234
235 ::
236
237 git fetch https://review.openstack.org/p/openstack/nova refs/changes/50/5050/1 && git checkout FETCH_HEAD
238
239 The repo is the stanza following ``fetch`` and the branch is the
240 stanza following that:
241
242 ::
243
244 NOVA_REPO=https://review.openstack.org/p/openstack/nova
245 NOVA_BRANCH=refs/changes/50/5050/1
246
247
Sean Dague07d7e5b2014-11-17 07:10:14 -0500248Installation Directory
249----------------------
250
Ian Wienand815db162015-08-06 10:25:45 +1000251The DevStack install directory is set by the ``DEST`` variable. By
252default it is ``/opt/stack``.
253
254By setting it early in the ``localrc`` section you can reference it in
255later variables. It can be useful to set it even though it is not
256changed from the default value.
Sean M. Collins09e550c2014-10-21 11:40:08 -0400257
258 ::
259
260 DEST=/opt/stack
261
Ian Wienand815db162015-08-06 10:25:45 +1000262Logging
263-------
264
265Enable Logging
266~~~~~~~~~~~~~~
267
268By default ``stack.sh`` output is only written to the console where it
269runs. It can be sent to a file in addition to the console by setting
270``LOGFILE`` to the fully-qualified name of the destination log file. A
271timestamp will be appended to the given filename for each run of
272``stack.sh``.
273
274 ::
275
276 LOGFILE=$DEST/logs/stack.sh.log
277
278Old log files are cleaned automatically if ``LOGDAYS`` is set to the
279number of days of old log files to keep.
280
281 ::
282
283 LOGDAYS=1
284
285The some of the project logs (Nova, Cinder, etc) will be colorized by
286default (if ``SYSLOG`` is not set below); this can be turned off by
287setting ``LOG_COLOR`` to ``False``.
288
289 ::
290
291 LOG_COLOR=False
292
293Logging the Service Output
294~~~~~~~~~~~~~~~~~~~~~~~~~~
295
296DevStack will log the ``stdout`` output of the services it starts.
297When using ``screen`` this logs the output in the screen windows to a
298file. Without ``screen`` this simply redirects stdout of the service
299process to a file in ``LOGDIR``.
300
301 ::
302
303 LOGDIR=$DEST/logs
304
Markus Zoellerc30657d2015-11-02 11:27:46 +0100305Note the use of ``DEST`` to locate the main install directory; this
306is why we suggest setting it in ``local.conf``.
Ian Wienand815db162015-08-06 10:25:45 +1000307
308Enabling Syslog
309~~~~~~~~~~~~~~~
310
311Logging all services to a single syslog can be convenient. Enable
312syslogging by setting ``SYSLOG`` to ``True``. If the destination log
313host is not localhost ``SYSLOG_HOST`` and ``SYSLOG_PORT`` can be used
yangyapeng01cf55a2015-10-29 13:21:29 -0400314to direct the message stream to the log host.
Ian Wienand815db162015-08-06 10:25:45 +1000315
316 ::
317
318 SYSLOG=True
319 SYSLOG_HOST=$HOST_IP
320 SYSLOG_PORT=516
321
Ian Wienand7d5be292015-08-10 13:39:17 +1000322
Ian Wienanda35391e2015-08-10 13:53:40 +1000323Example Logging Configuration
324~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
325
326For example, non-interactive installs probably wish to save output to
327a file, keep service logs and disable color in the stored files.
328
329 ::
330
331 [[local|localrc]]
332 DEST=/opt/stack/
333 LOGDIR=$DEST/logs
334 LOGFILE=$LOGDIR/stack.sh.log
335 LOG_COLOR=False
336
Ian Wienand7d5be292015-08-10 13:39:17 +1000337Database Backend
338----------------
339
340Multiple database backends are available. The available databases are defined
341in the lib/databases directory.
Markus Zoellerc30657d2015-11-02 11:27:46 +0100342``mysql`` is the default database, choose a different one by putting the
343following in the ``localrc`` section:
Ian Wienand7d5be292015-08-10 13:39:17 +1000344
345 ::
346
347 disable_service mysql
348 enable_service postgresql
349
Markus Zoellerc30657d2015-11-02 11:27:46 +0100350``mysql`` is the default database.
Ian Wienand7d5be292015-08-10 13:39:17 +1000351
352RPC Backend
353-----------
354
355Support for a RabbitMQ RPC backend is included. Additional RPC
356backends may be available via external plugins. Enabling or disabling
357RabbitMQ is handled via the usual service functions and
358``ENABLED_SERVICES``.
359
360Example disabling RabbitMQ in ``local.conf``:
361
362::
Markus Zoellerc30657d2015-11-02 11:27:46 +0100363
Ian Wienand7d5be292015-08-10 13:39:17 +1000364 disable_service rabbit
365
366
367Apache Frontend
368---------------
369
370The Apache web server can be enabled for wsgi services that support
371being deployed under HTTPD + mod_wsgi. By default, services that
372recommend running under HTTPD + mod_wsgi are deployed under Apache. To
373use an alternative deployment strategy (e.g. eventlet) for services
374that support an alternative to HTTPD + mod_wsgi set
375``ENABLE_HTTPD_MOD_WSGI_SERVICES`` to ``False`` in your
376``local.conf``.
377
378Each service that can be run under HTTPD + mod_wsgi also has an
379override toggle available that can be set in your ``local.conf``.
380
381Keystone is run under Apache with ``mod_wsgi`` by default.
382
383Example (Keystone)
384
385::
386
387 KEYSTONE_USE_MOD_WSGI="True"
388
389Example (Nova):
390
391::
392
393 NOVA_USE_MOD_WSGI="True"
394
395Example (Swift):
396
397::
398
399 SWIFT_USE_MOD_WSGI="True"
400
Oleksii Chuprykova6928102015-06-11 08:56:58 -0400401Example (Heat):
402
403::
404
405 HEAT_USE_MOD_WSGI="True"
406
Ian Wienand7d5be292015-08-10 13:39:17 +1000407
Anton Arefiev651cb1a2015-09-01 10:55:20 +0300408Example (Cinder):
409
410::
411
412 CINDER_USE_MOD_WSGI="True"
413
Ian Wienand7d5be292015-08-10 13:39:17 +1000414
Sean Dague07d7e5b2014-11-17 07:10:14 -0500415Libraries from Git
416------------------
417
Ian Wienand815db162015-08-06 10:25:45 +1000418By default devstack installs OpenStack server components from git,
419however it installs client libraries from released versions on pypi.
420This is appropriate if you are working on server development, but if
421you want to see how an unreleased version of the client affects the
422system you can have devstack install it from upstream, or from local
423git trees by specifying it in ``LIBS_FROM_GIT``. Multiple libraries
424can be specified as a comma separated list.
Sean Dague07d7e5b2014-11-17 07:10:14 -0500425
426 ::
427
428 LIBS_FROM_GIT=python-keystoneclient,oslo.config
429
Dean Troyer5686dbc2015-03-09 14:27:51 -0500430Virtual Environments
431--------------------
432
Ian Wienand815db162015-08-06 10:25:45 +1000433Enable the use of Python virtual environments by setting ``USE_VENV``
434to ``True``. This will enable the creation of venvs for each project
435that is defined in the ``PROJECT_VENV`` array.
Dean Troyer5686dbc2015-03-09 14:27:51 -0500436
Ian Wienand815db162015-08-06 10:25:45 +1000437Each entry in the ``PROJECT_VENV`` array contains the directory name
438of a venv to be used for the project. The array index is the project
439name. Multiple projects can use the same venv if desired.
Dean Troyer5686dbc2015-03-09 14:27:51 -0500440
441 ::
442
443 PROJECT_VENV["glance"]=${GLANCE_DIR}.venv
444
Ian Wienand815db162015-08-06 10:25:45 +1000445``ADDITIONAL_VENV_PACKAGES`` is a comma-separated list of additional
446packages to be installed into each venv. Often projects will not have
447certain packages listed in its ``requirements.txt`` file because they
448are 'optional' requirements, i.e. only needed for certain
449configurations. By default, the enabled databases will have their
450Python bindings added when they are enabled.
Dean Troyer5686dbc2015-03-09 14:27:51 -0500451
Ian Wienand815db162015-08-06 10:25:45 +1000452 ::
Sean Dague07d7e5b2014-11-17 07:10:14 -0500453
Ian Wienand815db162015-08-06 10:25:45 +1000454 ADDITIONAL_VENV_PACKAGES="python-foo, python-bar"
Sean M. Collins09e550c2014-10-21 11:40:08 -0400455
Sean M. Collins09e550c2014-10-21 11:40:08 -0400456
457A clean install every time
Sean Dague07d7e5b2014-11-17 07:10:14 -0500458--------------------------
459
Ian Wienand815db162015-08-06 10:25:45 +1000460By default ``stack.sh`` only clones the project repos if they do not
461exist in ``$DEST``. ``stack.sh`` will freshen each repo on each run if
462``RECLONE`` is set to ``yes``. This avoids having to manually remove
463repos in order to get the current branch from ``$GIT_BASE``.
Sean M. Collins09e550c2014-10-21 11:40:08 -0400464
465 ::
466
467 RECLONE=yes
468
Chris Dentebdd9ac2015-03-04 12:35:14 +0000469Upgrade packages installed by pip
470---------------------------------
471
Ian Wienand815db162015-08-06 10:25:45 +1000472By default ``stack.sh`` only installs Python packages if no version is
473currently installed or the current version does not match a specified
474requirement. If ``PIP_UPGRADE`` is set to ``True`` then existing
475required Python packages will be upgraded to the most recent version
476that matches requirements.
Chris Dentebdd9ac2015-03-04 12:35:14 +0000477
478 ::
479
480 PIP_UPGRADE=True
481
John Huaa4693b52015-08-06 13:53:35 +0100482Guest Images
483------------
484
485Images provided in URLS via the comma-separated ``IMAGE_URLS``
486variable will be downloaded and uploaded to glance by DevStack.
487
488Default guest-images are predefined for each type of hypervisor and
489their testing-requirements in ``stack.sh``. Setting
490``DOWNLOAD_DEFAULT_IMAGES=False`` will prevent DevStack downloading
491these default images; in that case, you will want to populate
492``IMAGE_URLS`` with sufficient images to satisfy testing-requirements.
493
494 ::
495
496 DOWNLOAD_DEFAULT_IMAGES=False
497 IMAGE_URLS="http://foo.bar.com/image.qcow,"
498 IMAGE_URLS+="http://foo.bar.com/image2.qcow"
499
Rafael Folcof0131e12015-09-23 12:55:02 -0500500
501Instance Type
502-------------
503
504``DEFAULT_INSTANCE_TYPE`` can be used to configure the default instance
505type. When this parameter is not specified, Devstack creates additional
506micro & nano flavors for really small instances to run Tempest tests.
507
508For guests with larger memory requirements, ``DEFAULT_INSTANCE_TYPE``
509should be specified in the configuration file so Tempest selects the
510default flavors instead.
511
512KVM on Power with QEMU 2.4 requires 512 MB to load the firmware -
513`QEMU 2.4 - PowerPC <http://wiki.qemu.org/ChangeLog/2.4>`__ so users
514running instances on ppc64/ppc64le can choose one of the default
515created flavors as follows:
516
517 ::
518
519 DEFAULT_INSTANCE_TYPE=m1.tiny
520
521
John Davidge21529a52014-06-30 09:55:11 -0400522IP Version
Brian Haley180f5eb2015-06-16 13:14:31 -0400523----------
524
Ian Wienand815db162015-08-06 10:25:45 +1000525``IP_VERSION`` can be used to configure DevStack to create either an
Sean Daguedb48db12016-04-06 08:09:31 -0400526IPv4, IPv6, or dual-stack self service project data-network by with
527either ``IP_VERSION=4``, ``IP_VERSION=6``, or ``IP_VERSION=4+6``
Ian Wienand815db162015-08-06 10:25:45 +1000528respectively. This functionality requires that the Neutron networking
529service is enabled by setting the following options:
John Davidge21529a52014-06-30 09:55:11 -0400530
531 ::
532
533 disable_service n-net
534 enable_service q-svc q-agt q-dhcp q-l3
535
Ian Wienand815db162015-08-06 10:25:45 +1000536The following optional variables can be used to alter the default IPv6
537behavior:
John Davidge21529a52014-06-30 09:55:11 -0400538
539 ::
540
541 IPV6_RA_MODE=slaac
542 IPV6_ADDRESS_MODE=slaac
543 FIXED_RANGE_V6=fd$IPV6_GLOBAL_ID::/64
544 IPV6_PRIVATE_NETWORK_GATEWAY=fd$IPV6_GLOBAL_ID::1
545
Ian Wienand815db162015-08-06 10:25:45 +1000546*Note*: ``FIXED_RANGE_V6`` and ``IPV6_PRIVATE_NETWORK_GATEWAY`` can be
547configured with any valid IPv6 prefix. The default values make use of
548an auto-generated ``IPV6_GLOBAL_ID`` to comply with RFC4193.
Brian Haley180f5eb2015-06-16 13:14:31 -0400549
Ian Wienand815db162015-08-06 10:25:45 +1000550Service Version
551~~~~~~~~~~~~~~~
552
553DevStack can enable service operation over either IPv4 or IPv6 by
554setting ``SERVICE_IP_VERSION`` to either ``SERVICE_IP_VERSION=4`` or
555``SERVICE_IP_VERSION=6`` respectively.
556
557When set to ``4`` devstack services will open listen sockets on
558``0.0.0.0`` and service endpoints will be registered using ``HOST_IP``
559as the address.
560
561When set to ``6`` devstack services will open listen sockets on ``::``
562and service endpoints will be registered using ``HOST_IPV6`` as the
563address.
564
565The default value for this setting is ``4``. Dual-mode support, for
566example ``4+6`` is not currently supported. ``HOST_IPV6`` can
567optionally be used to alter the default IPv6 address
Brian Haley180f5eb2015-06-16 13:14:31 -0400568
569 ::
570
571 HOST_IPV6=${some_local_ipv6_address}
John Davidge21529a52014-06-30 09:55:11 -0400572
Ian Wienand7d5be292015-08-10 13:39:17 +1000573Multi-node setup
574~~~~~~~~~~~~~~~~
Sean M. Collins09e550c2014-10-21 11:40:08 -0400575
Ian Wienand7d5be292015-08-10 13:39:17 +1000576See the :doc:`multi-node lab guide<guides/multinode-lab>`
Sean M. Collins09e550c2014-10-21 11:40:08 -0400577
Ian Wienand7d5be292015-08-10 13:39:17 +1000578Projects
579--------
Sean M. Collins09e550c2014-10-21 11:40:08 -0400580
Ian Wienand7d5be292015-08-10 13:39:17 +1000581Neutron
582~~~~~~~
Sean M. Collins09e550c2014-10-21 11:40:08 -0400583
Ian Wienand7d5be292015-08-10 13:39:17 +1000584See the :doc:`neutron configuration guide<guides/neutron>` for
585details on configuration of Neutron
Sean M. Collins09e550c2014-10-21 11:40:08 -0400586
Sean M. Collins09e550c2014-10-21 11:40:08 -0400587
Ian Wienand7d5be292015-08-10 13:39:17 +1000588Swift
589~~~~~
590
591Swift is disabled by default. When enabled, it is configured with
592only one replica to avoid being IO/memory intensive on a small
593VM. When running with only one replica the account, container and
594object services will run directly in screen. The others services like
595replicator, updaters or auditor runs in background.
596
Markus Zoellerc30657d2015-11-02 11:27:46 +0100597If you would like to enable Swift you can add this to your ``localrc``
Ian Wienand7d5be292015-08-10 13:39:17 +1000598section:
599
600::
601
602 enable_service s-proxy s-object s-container s-account
603
604If you want a minimal Swift install with only Swift and Keystone you
Markus Zoellerc30657d2015-11-02 11:27:46 +0100605can have this instead in your ``localrc`` section:
Ian Wienand7d5be292015-08-10 13:39:17 +1000606
607::
608
609 disable_all_services
610 enable_service key mysql s-proxy s-object s-container s-account
611
612If you only want to do some testing of a real normal swift cluster
613with multiple replicas you can do so by customizing the variable
Markus Zoellerc30657d2015-11-02 11:27:46 +0100614``SWIFT_REPLICAS`` in your ``localrc`` section (usually to 3).
Ian Wienand7d5be292015-08-10 13:39:17 +1000615
616Swift S3
617++++++++
618
Markus Zoellerc30657d2015-11-02 11:27:46 +0100619If you are enabling ``swift3`` in ``ENABLED_SERVICES`` DevStack will
Ian Wienand7d5be292015-08-10 13:39:17 +1000620install the swift3 middleware emulation. Swift will be configured to
621act as a S3 endpoint for Keystone so effectively replacing the
Markus Zoellerc30657d2015-11-02 11:27:46 +0100622``nova-objectstore``.
Ian Wienand7d5be292015-08-10 13:39:17 +1000623
624Only Swift proxy server is launched in the screen session all other
Markus Zoellerc30657d2015-11-02 11:27:46 +0100625services are started in background and managed by ``swift-init`` tool.
Ian Wienand7d5be292015-08-10 13:39:17 +1000626
627Heat
628~~~~
629
Markus Zoellerc30657d2015-11-02 11:27:46 +0100630Heat is disabled by default (see ``stackrc`` file). To enable it
631explicitly you'll need the following settings in your ``localrc``
Ian Wienand7d5be292015-08-10 13:39:17 +1000632section
633
634::
635
636 enable_service heat h-api h-api-cfn h-api-cw h-eng
637
638Heat can also run in standalone mode, and be configured to orchestrate
639on an external OpenStack cloud. To launch only Heat in standalone mode
Markus Zoellerc30657d2015-11-02 11:27:46 +0100640you'll need the following settings in your ``localrc`` section
Ian Wienand7d5be292015-08-10 13:39:17 +1000641
642::
643
644 disable_all_services
645 enable_service rabbit mysql heat h-api h-api-cfn h-api-cw h-eng
646 HEAT_STANDALONE=True
647 KEYSTONE_SERVICE_HOST=...
648 KEYSTONE_AUTH_HOST=...
649
650Tempest
651~~~~~~~
652
653If tempest has been successfully configured, a basic set of smoke
654tests can be run as follows:
655
656::
657
658 $ cd /opt/stack/tempest
659 $ tox -efull tempest.scenario.test_network_basic_ops
660
661By default tempest is downloaded and the config file is generated, but the
662tempest package is not installed in the system's global site-packages (the
663package install includes installing dependences). So tempest won't run
664outside of tox. If you would like to install it add the following to your
665``localrc`` section:
666
667::
668
669 INSTALL_TEMPEST=True
670
671
672Xenserver
673~~~~~~~~~
674
675If you would like to use Xenserver as the hypervisor, please refer to
Markus Zoellerc30657d2015-11-02 11:27:46 +0100676the instructions in ``./tools/xen/README.md``.
Ian Wienand7d5be292015-08-10 13:39:17 +1000677
678Cells
679~~~~~
680
681`Cells <http://wiki.openstack.org/blueprint-nova-compute-cells>`__ is
682an alternative scaling option. To setup a cells environment add the
Markus Zoellerc30657d2015-11-02 11:27:46 +0100683following to your ``localrc`` section:
Ian Wienand7d5be292015-08-10 13:39:17 +1000684
685::
686
687 enable_service n-cell
688
689Be aware that there are some features currently missing in cells, one
690notable one being security groups. The exercises have been patched to
691disable functionality not supported by cells.
692
693Cinder
694~~~~~~
695
696The logical volume group used to hold the Cinder-managed volumes is
697set by ``VOLUME_GROUP``, the logical volume name prefix is set with
698``VOLUME_NAME_PREFIX`` and the size of the volume backing file is set
699with ``VOLUME_BACKING_FILE_SIZE``.
700
701 ::
702
703 VOLUME_GROUP="stack-volumes"
704 VOLUME_NAME_PREFIX="volume-"
705 VOLUME_BACKING_FILE_SIZE=10250M
706
707
708Keystone
709~~~~~~~~
710
711Multi-Region Setup
712++++++++++++++++++
713
714We want to setup two devstack (RegionOne and RegionTwo) with shared
715keystone (same users and services) and horizon. Keystone and Horizon
716will be located in RegionOne. Full spec is available at:
717`<https://wiki.openstack.org/wiki/Heat/Blueprints/Multi_Region_Support_for_Heat>`__.
718
719In RegionOne:
720
721::
722
723 REGION_NAME=RegionOne
724
725In RegionTwo:
726
727::
henriquetrutaf2126222016-01-05 13:43:18 -0300728
Ian Wienand7d5be292015-08-10 13:39:17 +1000729 disable_service horizon
730 KEYSTONE_SERVICE_HOST=<KEYSTONE_IP_ADDRESS_FROM_REGION_ONE>
731 KEYSTONE_AUTH_HOST=<KEYSTONE_IP_ADDRESS_FROM_REGION_ONE>
732 REGION_NAME=RegionTwo
henriquetrutaf2126222016-01-05 13:43:18 -0300733
734Disabling Identity API v2
735+++++++++++++++++++++++++
736
737The Identity API v2 is deprecated as of Mitaka and it is recommended to only
738use the v3 API. It is possible to setup keystone without v2 API, by doing:
739
740::
741
742 ENABLE_IDENTITY_V2=False
Ian Wienand7cd16ce2016-04-08 09:40:56 +1000743
744Exercises
745~~~~~~~~~
746
747``exerciserc`` is used to configure settings for the exercise scripts.
748The values shown below are the default values. These can all be
749overridden by setting them in the ``localrc`` section.
750
751* Max time to wait while vm goes from build to active state
752
753 ::
754
755 ACTIVE_TIMEOUT==30
756
757* Max time to wait for proper IP association and dis-association.
758
759 ::
760
761 ASSOCIATE_TIMEOUT=15
762
763* Max time till the vm is bootable
764
765 ::
766
767 BOOT_TIMEOUT=30
768
769* Max time from run instance command until it is running
770
771 ::
772
773 RUNNING_TIMEOUT=$(($BOOT_TIMEOUT + $ACTIVE_TIMEOUT))
774
775* Max time to wait for a vm to terminate
776
777 ::
778
779 TERMINATE_TIMEOUT=30