12 Commits

Author SHA1 Message Date
Nguyen Van Duc
4e6d741889 Replace port 35357 with 5000 for "auth_url"
Based on the change in Keystone Install Guide [1],
this patch replace port 35357 with 5000 for "auth_url".

For more details, please check similar changes which have been done
on other projects: Nova [2], Neutron [3], Cinder [4], Glance [5].

[1] https://review.openstack.org/#/c/541857
[2] https://review.openstack.org/#/c/562812
[3] https://review.openstack.org/#/c/566491
[4] https://review.openstack.org/#/c/565464
[5] https://review.openstack.org/#/c/558932

Change-Id: Idaf125a35d36d82b6861930ccb6b9c1dc9231eaf
2018-07-18 15:17:02 +07:00
Thomas Goirand
2a127fed38 Restore OS_IDENTITY_API_VERSION=3 by default
Not having OS_IDENTITY_API_VERSION breaks completely Debian. Revert to
the previous default.

Change-Id: Iac78c461859680ce8d641b9f6dc43e634be57c05
2018-05-09 13:07:36 +02:00
Matthias Bastian
6d369703bb Set optional API version-related environment vars
If OSC's default values for API versions are not suitable, this change
allows overriding them using environment variables.
This applies to the compute, network, image, volume, identity and object
services.

Change-Id: I5447be16d71a3baa4224dae222d710be9d49b759
2018-04-24 16:13:06 +02:00
Matthias Bastian
80cf00dffe Set OS_INTERFACE and OS_ENDPOINT_TYPE in auth file
OSC does not use service-specific environment variables for choosing
endpoints. It requires a common OS_INTERFACE variable that is used for
--os-interface.
OS_ENDPOINT_TYPE is the analog for older service-specific clients and is
used for --os-endpoint-type.

Change-Id: I5dd8de00e72631d578cf7e0b7028705a5cda1ddb
2018-02-01 19:05:40 +01:00
Emilien Macchi
67a21c9a8d authfile: fix OS_IDENTITY_API_VERSION
In a previous commit (I did, mea culpa), I set IDENTITY_API_VERSION
while we should use OS_IDENTITY_API_VERSION.

Change-Id: I625adb5d8ef1898bd9a44a76a09b3f985146c96c
2016-02-16 17:25:07 -05:00
Emilien Macchi
ba4161b468 auth file: default urls to keystone v3
Keystone v3 status is CURRENT [1] while v2.0 is SUPPORTED [2].
A lot of work has been done in puppet-keystone to use v3 API by default,
even if we can still run v2.0.

This patch:

* add new parameter and set IDENTITY_API_VERSION to 3 by default
* change urls for v3 endpoints by default
* change tenant_name parameter to undef by default
* change project_name parameter to 'openstack' by default
* change project_domain and user_domain parameters to 'default' by
  default

It's a non-backward compatible change, for the users who don't set the
values that have been changed.
Though they can still override the default and switching back to
v2.0 if needed.

[1] http://developer.openstack.org/api-ref-identity-v3.html
[2] http://developer.openstack.org/api-ref-identity-v2.html

Change-Id: If97d24e627ff5ff688f5fb634221a29a98f0ae90
2016-02-15 15:02:54 -05:00
Colleen Murphy
b21b30b18a Add project_name parameter for auth_file
With keystone v3, the term 'tenant' is deprecated in favor of the term
'project'. Clients using the v3 API (including the puppet providers)
will only look for 'project' and not 'tenant'. This patch adds
$project_name as a parameter to openstack_extras::auth_file. It
defaults to undef and only appears in the openrc file if it is being
used. This follows the pattern set by $project_domain and $user_domain,
which will only be set if the user actively chooses to use them. This
doesn't change how $tenant_name is set.

Change-Id: Idc3b938e37b792636ec7c2702bf8429467b78d66
2016-01-29 16:33:19 -08:00
Matthew J Black
364abe6647 Added v3 domain env variables
The current authfile class does not currently specify domains
and if someone is using v3 api, it will fail with messages
about a domain not being specified. This change exposes two new
parameters to specify domain for project and user that are both
defaulted to false. When they're specified they will add two
env vars in openrc.

Change-Id: I4ed3d440e2171e0220e307363e1b7595127dadc7
Closes-Bug: 1534901
2016-01-16 08:49:31 -05:00
Gael Chamoulaud
e005145df1 Fix RSpec 3.x syntax
* 41 conversions
    from: it { should ... }
      to: it { is_expected.to ... }

* 5 conversions
    from: it { should_not ... }
      to: it { is_expected.to_not ... }

Change-Id: I143aec9fa309b4bbd664fa205b044131cfadc03b
Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
2015-09-14 09:53:00 +02:00
Emilien Macchi
6cb5b076f3 auth_file: allow to change the path
Default path is /root/openrc. Some use-cases might want to change the
path.

Change-Id: I2e37e3e968f6885916c5632fc60368fca04cd434
2015-06-22 23:37:42 -04:00
Bogdan Dobrelya
433cf87127 Fix verify_contents issue
Replace 'subject' to 'catalogue'.
Related rspec-puppet bug
https://tickets.puppetlabs.com/browse/MODULES-1514

Closes bug: #1420207

Change-Id: If398e02e5911ed1b8e177102a58be75742eccb49
Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
2015-02-10 11:07:07 +01:00
Michael Chapman
67dfb62e4d Add auth file from openstack repo
This commit adds the openrc templating that was
in the old openstack repository, with some changes
to the parameter names to match those in the file itself.

Change-Id: I979ea227c93153c15ea78c0c47b9c94843a314af
2014-12-29 22:43:32 +11:00