54 Commits

Author SHA1 Message Date
Javier Pena
5f15e05704 Separate api and registry packages for Red Hat
Starting in Kilo, Red Hat-based platforms are using separate
glance-api and glance-registry packages (for an example, see
http://trunk.rdoproject.org/f21/current/).

Change-Id: I3ad476846d7dec3ca612e5b0d20b21b8577f4af0
2015-04-10 18:07:12 +02:00
Matt Fischer
81a9c1acb1 Fix API/Registry ensure for Ubuntu
On Ubuntu the API and Registry are separate packages so we need an
package_ensure for each.

Change-Id: I02dcca223f57392e7b4c82806a2c0d48d301d4aa
2015-04-10 08:29:43 -06:00
Emilien Macchi
ec48075eca api: change default pipeline
Setting up cache requires ops to be aware of how cache works in Glance
and the fact they'll need more space on disk. It can be dangerous when
using shared storage (Ceph for example).

This patch aims to default to 'keystone' without cachemanagement
anymore.

This is not backward compatible, so if the deployer is not overriding
this parameter, Glance API won't manage the cache anymore.

Change-Id: Ibac35501658b2ba79081cbc7a53245d4a4eb7839
2015-03-17 15:45:46 -04:00
Sebastien Badia
dbe297b056 spec: updates for rspec-puppet 2.x and rspec 3.x
This patch aim to update our specs test in order to work with the rspec-puppet release
2.0.0, in the mean time, we update rspec syntax in order to be prepared
for rspec 3.x move.

In details:

  * Use shared_examples "a Puppet::Error" for puppet::error tests
  * Convert 'should' keyword to 'is_expected.to' (prepare rspec 3.x)
  * Fix spec tests for rspec-puppet 2.0.0
  * Upgrade and pin rspec-puppet from 1.0.1 to 2.0.0
  * Clean Gemfile (remove over-specificication of runtime deps of puppetlabs_spec_helper)

Change-Id: Ibd0333dc3c0959e846edfbad51fb48e8dfb8fbe9
Card: https://trello.com/c/eHXc1Ryd/4-investigate-the-necessary-change-to-be-rspec-puppet-2-0-0-compliant
2015-02-25 05:37:44 +01:00
Jenkins
4ccd0981a1 Merge "Add openstack tag to glance packages" 2015-02-09 21:17:17 +00:00
Matt Fischer
2dff962a65 Support identity_uri
This patch adds the ability to set a new identity_uri parameter.
It also deprecates the old auth_host, auth_port, auth_protocol,
and auth_admin_prefix parameters. Logic is in place so that
users of the deprecated settings should have a smooth upgrade
process and get deprecation warnings until they adopt the
new settings.

Change-Id: Id72991da18dd1f467a7683f8f450e157da64f969
Closes-Bug: #1391235
2015-02-05 15:20:26 +00:00
Matt Fischer
cbf3326184 Add openstack tag to glance packages
Change-Id: Ifbc41027c11f62342397d7e60e71080336c3418e
Partial-Bug: #1391209
2015-02-05 15:20:18 +00:00
Jenkins
390cd7787e Merge "Service Validation for Glance-API" 2014-12-23 03:37:35 +00:00
Emilien Macchi
2fa0df1e3b Service Validation for Glance-API
As an option, validate Glance API service with a default or custom
command, and if the service is up and running, create a Puppet Anchor

Change-Id: Id713d32d1dc34a15e93adb89c18d3471145e6ffe
2014-12-08 18:43:09 -05:00
Jenkins
99eea1138f Merge "Remove deprecated parameters" 2014-11-26 08:02:52 +00:00
Mathieu Gagné
e16f86e37c Remove deprecated parameters
* glance::api::sql_connection (deprecated since 4.1.0)
* glance::api::sql_idle_timeout (deprecated since 4.1.0)
* glance::registry::sql_connection (deprecated since 4.1.0)
* glance::registry::sql_idle_timeout (deprecated since 4.1.0)

Change-Id: Ibfe4e1a0a9f2f9f79b3fc76ef6a93ce429f72ed4
2014-11-25 13:50:46 -05:00
Emilien Macchi
908a62b2b9 Update [glance_store] section in glance config for Juno
Use new parameters for Juno like it's documented here:
http://docs.openstack.org/trunk/config-reference/content/glance-conf-changes-master.html
* Use [glance_store] section
* Update prefix when needed

Partial-Bug: #1391099

Change-Id: I096b16c33c493270422113e0107a100f967debc6
2014-11-14 19:30:39 +01:00
Jenkins
a33a9d6250 Merge "policy.json: Allow one to manage them from the puppet module" 2014-11-09 11:26:49 +00:00
Colleen Murphy
a97bf99479 Add parameter to set os_region_name in glance config
When https://review.openstack.org/#/c/125231/ was merged, the glance
providers became dependent on the DEFAULT/os_region_name parameter in
the glance configs, but the module had no way to set that parameter.
This caused the providers to fail.

This patch adds the parameter to glance::api so that the user can
control the value. It also removes functionality of the os_region_name
in glance::backend::cinder. While it would be better to deprecate this
parameter first and remove its functionality in a later release, there
is no clean way to do this and avoid a duplicate definition error.

An alternative to rapidly removing this functionality from
glance::backend::cinder would be modifying the glance parent provider
to make the DEFAULT/os_region_name glance config optional.

Change-Id: I075224acb9da2bb547d437b08cf6fccfed655d5c
2014-10-31 16:23:19 -07:00
Yanis Guenane
c90a835953 policy.json: Allow one to manage them from the puppet module
This commit allow a deployer to manage the policies via this module
It relies on augeas to change only the policy needed. The init takes
a hash of policies and apply them.

Change-Id: I6ee27a1c4c26c73f5954e6462097fb5ed4dbb7ea
2014-10-22 11:08:41 -04:00
Jenkins
09c71e6076 Merge "Add manage_service feature" 2014-09-29 04:25:09 +00:00
Martin Magr
da217a13f5 Add manage_service feature
puppet-glance lacks of disabling service managing. This patch adds
$manage_service parameter to relevant classes.

Change-Id: I222b1a3318f5163f6ad1e39cbb8be10c440ab99f
Closes-bug: #1359823
2014-09-17 14:30:37 +02:00
Jenkins
6d1c8b9e3d Merge "Migrate mysql backend to use openstacklib::db::mysql" 2014-09-03 03:27:17 +00:00
Colleen Murphy
dbcb82fa36 Migrate mysql backend to use openstacklib::db::mysql
Implements: blueprint commmon-openstack-database-resource
Change-Id: I03bd33d7c78ea69702650688c28e9d0b7cac2911
2014-08-14 08:45:41 -07:00
Jenkins
a432119ff6 Merge "Hide secrets from puppet logs" 2014-08-04 17:00:18 +00:00
Soren Hansen
c3a25eac47 Use 2.2 as the default mysql_module
Change-Id: I5ec545b62ef8ac5371ca567a8a00f5ba535efceb
2014-07-16 18:45:39 +05:30
Stefano Zilli
a0c5c271ef Hide secrets from puppet logs
Currently secrets like rabbit_password or admin_password are displayed in
puppet logs when changed. This commit changes glance_*_config and
glance_*_ini types adding a new parameter that triggers obfuscation of
the values in puppet logs.

Change-Id: I31f974a9afadef42939ee092ecba3b8f4333bb8b
Closes-Bug: #1328448
2014-07-12 02:42:13 +02:00
Liping Mao
7f439210b1 Glance registry protocol should be configurable
registry_client_protocol can't be configure in puppet now.
The default value is "http". It should be configurable.

Change-Id: I526c0892d123067362ea1b18cb8c21526a860981
Closes-bug: #1266988
2014-06-24 10:50:43 +08:00
Emilien Macchi
8156a87cd0 Deprecate old SQL parameters
SQL configuration has changed in Havana.
This patch aims to deprecate old parameters and configure using the
right way.

Change-Id: I6a800d51294ae23636636a8d1c6ccad192f45d4e
Signed-off-by: Emilien Macchi <emilien.macchi@enovance.com>
2014-05-08 15:25:06 +02:00
Emilien Macchi
5eb145b1c5 api: add image_cache_dir parameter
Without image_cache_dir parameter, Glance API can't start.
Default value is set to /var/lib/glance/image-cache.

Change-Id: I1cfcbf0021cfae187d9c8d78a16b18de29c97b4a
Signed-off-by: Emilien Macchi <emilien.macchi@enovance.com>
2014-05-07 22:27:36 +00:00
Benedikt Trefzer
394661ec4a support separate registry/api packages
on Debian plattforms there are separate packages
for glance registry and glance api. This allows
you to install api/registry on different servers.

If the packages for registry and api are the same,
(as it is the case for RedHat plattform)
the package is installed in ::glance class.
If the packages differs (as for Debian plattform),
installation of packages is done in
registry/api classes.

Additionaly this patch adds a test for unsupported
plattforms.

Change-Id: I8d4b74e8c8ad2dd7e6e2ad175326f36ff818c108
2014-04-15 21:50:35 +02:00
Xingchao Yu
e08774a281 Add known_stores option in class glance::api
In glance-api, if you use known_stores's default value and didn't use
all of the stores listed in known_stores, then glance-api service will
throw an error to point out which store missing, see more description
in related bug link.
This patchset adds known_stores option in glance::api, so that users
can configure it by their own needs.

Change-Id: If08254f419d182b82cc50137383985834f40a6fd
Closes-bug: #1259403
2014-04-11 15:32:23 +08:00
Michael Chapman
4aa86af2fc Add support for puppetlabs-mysql 2.2
Puppetlabs-mysql has been rewritten to be much
cleaner. This patch adds a new parameter for the
glance mysql class allowing users to use the new
version. Previous behavior will continue as normal
when using the old version (0.9)

Change-Id: Icdc787e325f3e86572f6930f1ab8c3d5291e67c9
2014-03-22 02:12:28 +11:00
Benedikt Trefzer
e866507782 set ssl options for glance-api
lets you set the ssl cert, key, ca for secure api
connection.

Change-Id: Ie82a46eeca27897363273aab5e58fcf6f6fe1ae0
backport: havana
2014-03-19 08:16:46 +01:00
Jenkins
31ced75334 Merge "Add ability to purge config" 2014-03-10 15:57:51 +00:00
Michael Chapman
c629376782 Add ability to purge config
This patch adds paramters to the api and registry
classes that allows the respective config files to
be purged.

This is needed when running in a configuration that
is contrary to the defaults for the platform packager,
such as rabbitmq on RDO

Change-Id: I9f8664b2098bd41b9a98eac095bfec8493ed1254
2014-02-23 18:28:55 +11:00
Sebastien Badia
1d5a298f41 Add log_dir param. by default and allow users to disable it
* add log_dir param (and configure it to /var/log/glance) by default.
  * fix log_file missing setting on glance::registry
  * allow users to disable log_dir and log_file with « false » argument.

Change-Id: I0689fa15199e69cf16ff306050776d150365a09c
Closes-bug: #1282296
2014-02-20 13:55:46 +01:00
Sebastien Badia
715216c3dc Add availability to configure show_image_direct_url
This commit:
  - Add the show_image_direct_url parameter (default to false)
  - Fix spelling errors in documentation
  - Fix documentation format (use puppetdoc)
  - Add missing documentation about params

Change-Id: I8e5cb36c19ffa4ae726642a55d8fab5c6cea07b5
Co-Authored-By: Emilien Macchi <emilien.macchi@enovance.com>
2014-02-03 10:23:46 +01:00
Jenkins
a1b2406c9c Merge "Add syslog support to the glance module" 2013-09-03 14:10:54 +00:00
Dan Bode
3fe2895a71 Change keystone tenant and user default
Currently, the default auth tenant and user for
glance are set to admin. This is not only
inconsistent with the rest of the modules (where
the tenant defaults to services and the user defaults
to the name of the service: ie: glance), it
is also inconsistent with the glance::keystone::auth
class.

This patch changes the defaults to services and glance
for both the api and registry service.

Change-Id: I3bd6390183c88213ec4bc289ca6be6f2d9c8bdd2
2013-08-30 18:09:23 -07:00
Francois Deppierraz
a79c191681 Add syslog support to the glance module
Change-Id: Ibe3a22a996016d1a80efb69fd7d401d1834d011b
2013-08-28 14:40:43 +02:00
Dan Prince
adcb347abd Add default auth_uri setting for auth token.
The latest keystoneclient code now gives a Warning if auth_uri
isn't explicitly specified.

Change-Id: I0feb52f7a9140ea750254f80b6a3e6855b25f1d3
2013-08-27 15:45:11 -04:00
Jenkins
ffbe1c566f Merge "Allow blank keystone flavor in glance configs" 2013-06-25 07:24:53 +00:00
Simon Sellar
a633d9f59a Allow blank keystone flavor in glance configs
Blank keystone flavor now allowed in api.pp and registry.pp
Pipeline config logically separate from keystone config (pipeline can
be set even if auth_type is not defined.)
Added rspec tests.

Change-Id: Ic4fbff44242459f504cd14ef18915b2efac2d032
Fixes: bug #1190475
2013-06-18 09:59:42 +09:30
Maru Newby
b144d4e6c5 Fix misnamed protocol param in glance-api.conf
* keystone_authtoken/protocol => auth_protocol

Change-Id: I47ba3eb584255e666f787b53d4668b74a575982f
2013-06-14 10:56:57 -04:00
François Charlier
dc98e9bb58 Add support for auth_admin_prefix in glance
Add support for auth_admin_prefix in glance::registry, glance::api & in
the glance provider.

Change-Id: I646c621f0a42cd987bc409b17066f8ac13556883
2013-06-11 17:26:28 +02:00
Mathieu Gagné
b04232aecb Use boolean instead of string
Change-Id: Ie508c5f6a98277b650307a1782ce3fde9d2bca1e
2013-05-09 23:12:33 -04:00
Derek Higgins
3ade42f65e Allow paste deploy flavor to be passed for glance api
Some users may want to pass in one of
keystone, keystone+caching or keystone+cachemanagement
depending on their caching needs

Change-Id: Ia13cc2f1d8ec43074b114edf1b2366b85ca77aa0
2013-04-26 05:51:59 -04:00
Dan Bode
6c77769c8e remove auth_url param
This commit removes the auth_url class param

I search of glance's source code indicates that this
parameter is not used anywhere except by something in the
tools directory.
2012-10-31 10:39:12 -07:00
Dan Bode
7c396acd66 remove password defaults
This commit removes the password defaults.

Users should not rely on password defaults.
2012-10-14 12:36:13 -07:00
Dan Bode
e6216be659 fix unit tests 2012-10-14 00:23:20 -07:00
Eugene Kirpichov
0f98eb07ba Customizable auth_url, not hardwired to 127.0.0.1 2012-08-21 17:53:20 -07:00
Dan Bode
1fb892afd7 Add enabled parameter to glance services.
This commit adds the parameter enabled to both glance::api
as well as glance::registry.

Setting enabled to false ensures that the service is not running
and that the db schema is not create/migrated.

This flag is being added to all nova services to allow the deployment
of the openstack controller in active-passive for HA.
2012-06-18 10:14:53 -07:00
root
38622827fe This commit fixes spec test failures that were caused by
using RI's version of the concat module.

It introduces a custom fact concat_basedir that can determine
where the vardir is for a particular agent.

This commits adds that fact to unit tests that are validating
the resuling fragment files.
2012-05-08 14:38:55 -07:00
Dan Bode
a7a96af75e Fix broken tests
I had previously checked in some broken tests that
resulted from the updating the concat fragments names
to ensure uniqueness between services (eg, choosing
fragment names like HEADER were causing
duplicate resource errors, these have been prefixed
with the service name glance-api to ensure uniqueness)

This commit updates the tests so that they work for
this previous commit (oops!)
2012-04-03 10:03:08 -07:00