healthcheck middleware adds a /healthcheck url that allows
unauthenticated access to provide a simple check when running
octavia-api behind a load balancer
https://docs.openstack.org/oslo.middleware/latest/reference/healthcheck_plugins.html
Co-authored-by: Michael Johnson <johnsomor@gmail.com>
Change-Id: I10db6226750f7b7c703067d2ab82eea3a9875112
Currently we only allow argv parameters to be passed into our wsgi
app. This means that some wsgi wrappers (such as pbr's script)
may not allow the octavia API to accept parameters such as
--config-file.
This patch attempts to pull in the sys.argv if none was passed into
the wsgi setup_app method.
Change-Id: I67cf32aac8aa8d8123ec8ca1ab433ff23fb1ffa2
This sets up the HTTPProxyToWSGI middleware in front of Octavia API. The
purpose of this middleware is to set up the request URL correctly in
the case there is a proxy (For instance, a loadbalancer such as HAProxy)
in front of Octavia API.
So, when TLS connections are terminated at the proxy, and one tries to
get the versions from the '/' resource from Octavia API, one will notice
that the protocol is incorrect; It will show 'http' instead of 'https'.
So this middleware handles such cases.
The HTTPProxyToWSGI is off by default and needs to be enabled via a
configuration value.
It can be enabled with the option in octavia.conf:
[oslo_middleware]
enable_proxy_headers_parsing=True
Story: 2005105
Task: 29732
Change-Id: I276188530a83598ed75560f02ed9d80ce9afca2f
This patch adds Cloud Auditing Data Federation (CADF) auditing support to the
Octavia API. This is implemented using the keystonemiddleware audit filter.
Change-Id: I87a7e15171dfaf28b6ed97ca71d4423d18fbdbea
The provider drivers should be initialized at init, to allow configuration
validation, as well as allowing the drivers to perform actions at init.
Change-Id: Iaa6c4cbc65aa24f2c9bc53878226bd2e4b9ba694
Also, create a section for API settings `api_settings` and move some
related settings there.
This patch also enables the configuration settings to be logged
when the api process is started if debug is True.
Change-Id: I31671789d186c4b8a775cc12a414acd2d439512d
Make the octavia.api.app module work with web servers running on WSGI.
Take uwsgi for an example:
uwsgi --socket /tmp/octavia.sock \
--pythonpath /home/devstack/octavia/octavia/api \
--module "app:setup_app()" \
--pidfile /tmp/octavia.pid --vacuum \
--daemonize /var/log/octavia/octavia.log
Change-Id: I3282da1191965e8d83c8bf74ef1a1285673a6987
Added hacking check to ensure not to use xrange. Also,
fixed issues with EoF missing newline [W391].
Change-Id: Iba8d240c042e46cb34eb6ed057534d62efb6f903
Closes-Bug: #1538118
Setup executable to use wsgiref.simple_server
Simple setup of pecan
Defined controllers that define the API resources
Implemented all controllers to manipulate database and send to handler
Added repository methods required for creating multiple items in one transaction
Defined a few API exceptions based of wsme exceptions
Defined the wsme types that define the resource response and request bodies
Defined an abstract handler that all handlers should subclass
Defined a simple handler that is responsible for sending to controller
Added some wsme type tests
Implements: bp/operator-api
Change-Id: I0d91934db47a6e45f0c9ac22089f8689957bd239