As we are not maintaining sample config file in the repo now,
the checkconfig can be removed since it's always generated from
the code.
Change-Id: I5bfd7c5cbb048a71864fac4fcfebb940529f87f1
This change will add how to create windows images article
in portgroup docs. these images will support to create port
bounding through ironic services.
This feature has tested on Fujitsu servers successfully.
Change-Id: I1ce941a16f080fce1699d8629a7e12a2c2d83ade
Bashate introduces a new error, E044, which attempts to
identify any questionable conditionals that would be
incorrectly using bracketing. That being said, it is
modeled on keeping the design simple, and errors on more
condensed lines where conditionals are included.
Since we don't need this, and the case where it is erroring
is invalid as the test is overly simple, lets ignore it.
Change-Id: Ie46dcd6cd6100f3c7e35c2c817828e45bd6b7921
The 'releasenotes' gate job does not run our tox section. This allowed a
releasenote to land that had a filename in an incorrect format because
it was not created with 'reno new'.
Move the running of 'tools/check-releasenotes.py' to the pep8 section
and whitelist the releasenote that got merged.
Change-Id: Id5bd8e0cbc9186c89f682224088a8f23998d59c3
This adds the healthcheck middleware from oslo, configurable via the
[healthcheck]/enabled option. This middleware adds a status check at
`/healthcheck`.
This is useful for load balancers to determine if a service is up (and
add or remove it from rotation), or for monitoring tools to see the
health of the server.
This endpoint is unauthenticated, as not all load balancers or
monitoring tools support authenticating with a health check endpoint.
Change-Id: I7929d5f4502c3f84b1cf30526c94a458081a6a29
Closes-Bug: #1748515
We now use the project openstack/ironic-tempest-plugin to store our
tempest plugin. All content from the ironic_tempest_plugin/ directory
has been ported to that project.
We no longer want to have the plugin content stored here so we delete
it.
Remove check in tools/flake8wrap.sh that prevented changes to the
ironic_tempest_plugin/ directory.
Change-Id: I700bd7b71472fa91f6bc02aebc055584df08e0ef
Add a check to the PEP8 test to prevent changes to the
ironic_tempest_plugin/ directory.
This will be removed when we remove the ironic_tempest_plugin/
directory.
Change-Id: I3cdbb39ebc661652ff9ceba5f3115ac26667953b
This patch does the following:
* Adds a configuration folder to contain automated generated config
files for Ironic.
* Adds `oslo_config.sphinxconfiggen` to the extensions list.
* Adds `oslo_policy.sphinxpolicygen` to the extensions list.
* Adds ironic-policy-generator.conf
This is important for Ironic to be included in the list of services
on https://docs.openstack.org/pike/configuration/
Change-Id: I51a7204ce00be2588e427c1951e8be7dc7a22647
Closes-bug: #1706176
This patch does the following:
* Adds osprofiler wsgi middleware
This middleware is used for 2 things:
- It checks that person who wants to trace is trusted and knows
secret HMAC key.
- It starts tracing in case of proper trace headers
and adds first wsgi trace point, with info about HTTP request.
* Adds initialization of osprofiler at start of service
- Initialize and set an oslo.messaging based notifier instance
to osprofiler, which will be used to send notifications to Ceilometer.
* Traces HTTP/RPC/DB API calls and SQL requests
NOTE to test this patch:
1) Make the following changes in localrc to configure DevStack to enable
OSProfiler:
enable_plugin panko https://git.openstack.org/openstack/panko
enable_plugin ceilometer https://git.openstack.org/openstack/ceilometer
enable_plugin osprofiler https://git.openstack.org/openstack/osprofiler
# Enable the following services
CEILOMETER_NOTIFICATION_TOPICS=notifications,profiler
ENABLED_SERVICES+=,ceilometer-acompute,ceilometer-acentral
ENABLED_SERVICES+=,ceilometer-anotification,ceilometer-collector
ENABLED_SERVICES+=,ceilometer-alarm-evaluator,ceilometer-alarm-notifier
ENABLED_SERVICES+=,ceilometer-api
NOTE: the order of enabling plugins matters.
2) Run stack.sh. Once DevStack environment is setup, enable profiler options
in ironic.conf and restart ironic services:
[profiler]
enabled = true
hmac_keys = SECRET_KEY
trace_sqlalchemy = true
3) Use openstackclient and run baremetal command with
--os-profile SECRET_KEY
[--profile can be used, but it is deprecated.]
For example, the following will cause the <trace-id> to be printed
after node list:
$ openstack --os-profile SECRET_KEY baremetal node list
.....
.....
Trace ID: <trace-id>
Display trace with command:
osprofiler trace show --html <trace-id>
4) The trace results can be saved using this command:
$ osprofiler trace show --html <trace-id> --out trace.html
OSprofiler spec: https://review.openstack.org/#/c/103825/
Co-Authored-By: Tovin Seven <vinhnt@vn.fujitsu.com>
Co-Authored-By: Hieu LE <hieulq@vn.fujitsu.com>
Partial-Bug: #1560704
Change-Id: Icd3d7c62cf7442de8a77fc67f119ae9b03725f02
Add simple script to setup mysql and postgresql databases, this script
can be run by users during testing and will be run by CI systems for
specific setup before running unit tests. This is exactly what is
currently done by OpenStack CI in project-config.
This allows to change in project-config the python-db jobs to
python-jobs since python-jobs will call this script initially.
See also
http://lists.openstack.org/pipermail/openstack-dev/2016-November/107784.html
Update devref for this.
Needed-By: I58c1d37d620ca058a4c2127e329d8d21b391965f
Change-Id: Id21d3481f7b4929c40c7351e6321d9ba5ad078b8
In addition to the normal bare-metal console logs that devstack
generates, create a "no ansi" version of the log that will be easier to
view/parse when viewing the logfiles.
Change-Id: Ic321db38f694d82362a6b1be91f891a06fb18c11
Before bashate was only running on the devstack/ directory. Have it
now run on the entire project for *.sh files.
Fix issues detected by bashate.
Also check the files:
devstack/files/hooks/qemu
devstack/lib/ironic
These files were located by doing:
$ find openstack/ironic/ -not \( -type d -name .?\* -prune \) \
-type f -not -name '*.sh' | xargs file | grep -i "shell script"
Change-Id: I238b7ab650781143fe8231e01250ab56120ff94f
This change adds initial metrics for Ironic based on new support in
ironic-lib. Emits timing metrics for basic Ironic API calls.
Bumps ironic-lib to 2.0.0 in requirements to add metrics support, as
well as adding ironic_lib.metrics and ironic_lib.metrics_statds to
ironic-config-generator.conf to get them in the sample config, which
is also regenerated.
Change-Id: Ic35802e4cd11763ebbedb8ddc28f7e8dc535cc2f
Partial-bug: #1526219
oslo_config provide a utility for generating sample config files,
which provide more detail about opts, like Minimum/Maximum value
and Allowed values.
So drop Ironic's "generate_sample.sh" which was copied from
oslo-incubator long time ago.
Add a new entry point "ironic" under oslo.config.opts namespace to
explore config options to oslo-config-generator.
After this patch, new config options of Ironic code should register
with ironic/conf/opts.py. New external libraries should
register with tools/config/ironic-config-generator.conf
There is a bug #1554657 with oslo-config about deprecated_group.
This bug have impact of some configs from keystonemiddleware
and oslo.messaging in ironic.conf.sample
So currently, deprecated option should always add the deprecated_group
even it didn't alter the group, otherwise the deprecated group value will
be 'DEFAULT'.
Update etc/ironic/ironic.conf.sample via running 'tox -egenconfig'.
Closes-Bug: #1564195
Change-Id: If7721e98e69b6f54f1ee04a07477396b86583371
This updates the state machine diagram and documentation to indicate
which transitions are initiated by API requests versus the ones that
are internally done by the conductor. Stable states are highlighted
a bit.
Change-Id: I1a2de81b14696286f1da47c06374ad235962c849
Closes-Bug: #1527316
This makes tox use a simple wrapper around flake8 like
Nova, which can be told to restrict the check to only
files changed in the current command. This can be invoked
in a simple manner with 'tox -epep8 -- -HEAD'. Since most
commits only touch a handful of files, this will usually
be far faster than checking all source files.
To check an entire branch for bisectability it can be
automated via
git rebase -i master -x 'tox -epep8 -- -HEAD'
Change-Id: I75b1cfe3198b1217f8b25877714a4af47ae7069f
This patch allows flake8 to run against the scripts under tools/ and
devstack/tools directories.
It also fix the current pep8 errors where it's needed.
Change-Id: I3f447564dd528c6efdee10a4a13f1ff1d7e1c3b1
In order to easily determine the file type of the scripts in
devstack/tools/ironic/scripts directory, this patch is adding the
correspoding extension to each script.
Change-Id: Ifb53b768b7a3b38561031c92c279fa520e289b3d
Apparently # is treated as a comment inside the string and as
consequence the rest of the command gets stripped. This patch drops
those comments from the bashate command.
This patch also moves the bashate command to its own script under
tools/.
Change-Id: Ic44bb64419ca1465f69c91fd579e8c84d69f84b8
Closes-Bug: #1527562
The disk partitioner related code from ironic/common/disk_partitioner.py
and ironic/drivers/modules/deploy_utils.py is being moved to ironic-lib.
The code in ironic needs to be removed and use ironic-lib to perform
disk related activities.
Change-Id: I7b1b1d8b45b947a7b5715f3c6ab49d84e84b6b90
Add posibility to configure the API to service requests via HTTPS instead
of HTTP using native ssl from oslo.service wsgi.
New options was added:
* enable_ssl_api - turn on ssl support;
Options defined in oslo.service for configure certs:
* ca_file - ca certificate file to use to verify connecting clients;
* cert_file - certificate file to use when starting the server securely;
* key_file - private key file to use when starting the server securely;
Closes-bug: #1430213
Change-Id: Id4b84d83f9aa6c7f898b3b9b59158d5b1a00e159
This refactors map_color() so that it returns a dictionary, instead
of the callers (of that method) doing that work.
Change-Id: I55a808d889fd3818c1f262dcab7af9ffa8c6e557
MODULEPATH is apparently a well known variable from environment-modules
package and was causing the sample configuration generation to fail.
Change-Id: Ie9f1896c9480aa371c99a316511b172e92f52824
Closes-Bug: #1437904
oslo.config.generator has been removed from olso-incubator so
we need to adopt it in order to generated up-to-date config
files.
Changes introduced:
- Move config/generator.py from openstack.common to ironic.common
- Update config generator to use new style list_opts discovery
- Split _print_opt function to reduce complexity and pass pep8 tests
Change-Id: I397504bf0604a86082f26e46952720117611f3a8
Instead of requiring manual understanding of how to generate
the states diagram, add an explicit virtualenv that can be
used to create and generate that docs diagram (and replace the
existing file with it).
Change-Id: I1738da9bf08bfda9b9be01489e8456569a31709e
Add oslo.policy and oslo.concurrency to oslo config generator extra
libraries to retrieve config options
Update oslo_incubator service module
Update oslo_incubator versionutils with new list_opts discovery
Change-Id: I5558f6f9f708b1643ebd6c8b2a213a1fae582a50
Fixes the following error by correctly quoting the header:
Warning: syntax error in line 1 near 'states'
Change-Id: I94fa3b18d355c68674b16f128e477aba8e1b542e
Adding keystonemiddleware.authtoken as extra libraries
to register its missing options, like admin_user.
Update sample conf by running 'tools/config/generate_sample.sh'
Closes-Bug: #1430115
Change-Id: Ic8666dc4a3a6b7c5855afb2929d8b14ebe21ca52
The default format is png (and not svg) so we should
note that instead of having svg mentioned (this was
leftover from the clone of this from taskflow which
does default to svg).
Change-Id: I108857ecc606ed2c12e0d5b460a8e72eb95af740
Add a tool (derived from taskflow's similar tool)
that can turn the state machine defined in ironic
into a dot diagram.
This diagram is much easier to look at then trying
to mentally create a similar diagram; this makes it
easier to see issues and to visualize the state machines
valid states and transitions.
For this change we need to add back in the state machine
__iter__ method so that we can correctly iterate over the
states and transitions (and events that will cause those
transitions).
Change-Id: I9da09f65a46617aa1c837ae0fc71350276df8bea
auth_token middleware in python-keystoneclient is deprecated and has
been moved to the keystonemiddleware repo.
This patch updates Ironic to use the new keystonemiddleware package.
Change-Id: Ifb48996867f9f51c4dbedde0e0d9476c2d2818b4
Closes-Bug: #1342274
Update the openstack.common modules from oslo.incubator
to have a current copy needed to start using new released
oslo libraries.
Change-Id: I60ea98b3381cbbc3d2905af224792ee68b423825
oslo.db library has been graduated from oslo-incubator,
so now we can use it instead of ironic.openstack.common.db.* code.
Co-Authored-By: Ghe Rivero <ghe.rivero@hp.com>
Implements: blueprint oslo.db
Change-Id: I250050a7dbd8735ba3af954223b54eabae793f59
The oslo.messaging library takes the existing RPC code from oslo and
wraps it in a sane API with well defined semantics around which we can
make a commitment to retain compatibility in future.
The patch is large and hard to be split into different patches, but the
changes can be summarized as:
* Remove openstack/common/{rpc, notifier, log_handler} modules dependency
(superceded by oslo.messaging)
* New config option `conductor.workers_pool_size` add to determine the
size of the workers greenthread pool.
* PeriodicService class refactored and renamed to RPCService, all periodic
tasks methods were moved to the ConductorManager class leaving RPCService
class to be resposable for setting up and starting the RPCServer from
oslo.messaging only.
* In oslo.messaging, a request context is expected to be a dict so the
method RequestContext.{to,from}_dict() was updated/added to the module.
* The allowed_rpc_exception_modules configuration option is replaced
by an allowed_remote_exmods get_transport() parameter. This is not
something that users ever need to configure, but it is something each
project using oslo.messaging needs to be able to customize.
* New common/rpc.py module added to wrap the global messaging state. It
also contains transport aliases for backwards compatibility with IceHouse
rpc_backend configuration values.
blueprint: oslo-messaging
Change-Id: I454e8898baed002a1cddb9eb76492ae9c2f1212b
Import the Nova "ironic" driver from the Nova review queue.
This Nova driver will not be present in the Icehouse release of Nova,
but is required for Ironic functionality and can be installed as an
out-of-tree driver.
Co-Author: Lucas Alvares Gomes <lucasagomes@gmail.com>
Co-Author: Devananda van der Veen <devananda.vdv@gmail.com>
Change-Id: I3351dee1a4b2dfb50317ce85dffe8012f0feca6c