Andrew Schoen [Tue, 10 Jan 2017 22:57:58 +0000 (16:57 -0600)]
purge-cluster: do not include ceph-osd and ceph-common defaults for osds
When purging OSDs we do not need to include these defaults as nothing in
the following tasks uses them. Also, it has the side effect of
overwriting any variables defined in group_vars files that are relative
to the inventory you are using with the default values. That behavior
was causing the CI tests to fail.
Andrew Schoen [Tue, 10 Jan 2017 22:56:07 +0000 (16:56 -0600)]
tests: copy purge-cluster.yml to root of ceph-ansible
There is an Ansible bug which makes the playbook fail when we are
running a playbook from the non-git root directory. The real problem is
that the ansible.cfg is not honoured and we are including variable from
roles/<role>/defaults/main.yml
The fix is too copy the purge cluster playbook on the git root directory
and execute it.
Ken Dreyer [Thu, 5 Jan 2017 21:29:53 +0000 (14:29 -0700)]
ceph-common: always include release.yml
Prior to this change, a playbook run with '--tags' or '--skip-tags'
would fail, because the ceph-common role would not include the
release.yml task, and this file defines critical things like
ceph_release.
Thanks Andrew Schoen <aschoen@redhat.com> for help with the fix.
Andrew Schoen [Thu, 22 Dec 2016 19:47:22 +0000 (13:47 -0600)]
purge-cluster: get journal partitions after zapping osd disks
In my testing zapping the osd disks deleted the journal
partitions, making the 'zap ceph journal partitions' task fail because
the partitions it found previously do not exist anymore.
This moves the task that finds the journal partitions after 'zap osd disks'
to catch any partitions ceph-disk might have missed.
Sébastien Han [Mon, 2 Jan 2017 10:16:03 +0000 (11:16 +0100)]
mon: only put mon initial key in mon kv when cephx is enabled
Task put initial mon keyring in mon kv store from
ceph-mon/tasks/ceph_keys.yml is failing when cephx is disabled. The root
cause is that variable monitor_keyring is not populated by any task from
deploy_monitors.yml.
Fixes: #1211 Signed-off-by: Sébastien Han <seb@redhat.com>
Sébastien Han [Fri, 16 Dec 2016 13:53:14 +0000 (14:53 +0100)]
docker: only use systemd to manage containers
Prior to this patch we had several ways to runs containers, we could use
ansible's docker module on some distro and on containers distros we were
using systemd. We strongly believe threating containers as services with
systemd is the right approach so this patch generalizes to all the
distros. These days most of the distros are running systemd so it's fair
assumption.
Sébastien Han [Fri, 16 Dec 2016 10:42:17 +0000 (11:42 +0100)]
mon: add the initial mon keyring to the mon store
Once we have our first monitor up and running we need to add it to the
monitor store as a safety measure. Just in case the local file gets
deleted and you need to add a new monitor. Now you can retrieve this key
like this:
ceph config-key get initial_mon_keyring > initial_mon_keyring.txt
Sébastien Han [Fri, 16 Dec 2016 10:36:42 +0000 (11:36 +0100)]
common: do not become root on local task
There is no need to become root on local_action. This will event trigger
an error on some systems as it will try to run a sudo command. If the
current user does not have passwordless sudo, Ansible will fail. Anyway
using the current user is perfectly fine and no elevation privilege is
needed.
Logan V [Thu, 14 Jul 2016 19:27:03 +0000 (14:27 -0500)]
Add support for Keystone v3 API
The Keystone v2 APIs are deprecated and scheduled to be removed in
Q release of Openstack. This adds support for configuring RGW to
use the current Keystone v3 API.
Logan V [Thu, 14 Jul 2016 19:09:31 +0000 (14:09 -0500)]
Add a switch to disable nss PKI database initialization
The PKI keys are used to decrypt the Keystone revocation list when
PKI tokens are used. When UUID or Fernet token providers are used in
Keystone, PKI certs may not exist, so we now accommodate this scenario
by allowing the operator to disable the PKI tasks.
Logan V [Mon, 11 Jul 2016 12:52:11 +0000 (07:52 -0500)]
Add support for Keystone user authentication with RGW
Jewel added support for user/pass authentication with Keystone,
allowing deployers to disable Keystone admin token as required
for production deployments.
This implements configuration for the new RGW Keystone user/pass
authentication feature added in Jewel.
See docs here: http://docs.ceph.com/docs/master/radosgw/keystone/
Sébastien Han [Tue, 6 Dec 2016 10:20:23 +0000 (11:20 +0100)]
test: add cluster name support test scenario
We need to test the cluster name support in this CI as well. This
commit might be prone to debate because it tests 2 things in a single
scenario. We first test our ability to deploy a cluster AND the cluster
name support. However it's easier to do it this way and will reduce the
amount of time for testingg. If we don't do this we will have a
duplicate those 2 existing tests into new ones 'only' to test the
cluster name support.
common: do not regenerate initial mon keyring if cluster exists
This commit solves the situation where you lost your fetch directory and
you are running ansible against an existing cluster. Since no fetch
directory is present the file containing the initial mon keyring
doesn't exist so we are generating a new one.
Sébastien Han [Wed, 14 Dec 2016 18:03:04 +0000 (19:03 +0100)]
common: remove uncessary conditions and spell red hat entirely
We do not need to run another condition for 'ceph_rhcs' since the
include we came from already has it, so we are already inside this
condition.
We also spell red hat entirely instead of rh and we remove capital
letters.
Andrew Schoen [Wed, 14 Dec 2016 15:13:55 +0000 (09:13 -0600)]
ensure site.yml.sample always gathers facts and installs python2
Then avoids an issue where if you're using tags to run the playbook then
no facts are gathered, resulting in subsequent tasks failing that depend
on them.
Ken Dreyer [Mon, 12 Dec 2016 21:20:47 +0000 (14:20 -0700)]
Makefile: improve version detection
Prior to this change, if there was a stray tag in the repository that
did not start with a "v", the Makefile would still try to use that tag
as a version tag when constructing the RPMs.
Only use the tags that start with "v", in this case.
Casey Bodley [Fri, 9 Dec 2016 15:41:54 +0000 (10:41 -0500)]
ceph-common: remove libcephfs1 from debian_ceph_packages
in hammer, ceph-common depended on libcephfs (indirectly, via
python-cephfs). this is no longer the case in jewel or later, so it can
be removed from debian_ceph_packages
Sébastien Han [Fri, 9 Dec 2016 13:51:35 +0000 (14:51 +0100)]
common: do not run tasks in main.yml, use include
For readibility and clarity we do not run any tasks directly in the
main.yml file. This file should only contain include, which helps us
later to apply conditionnals if we want to.
Sébastien Han [Tue, 6 Dec 2016 16:28:30 +0000 (17:28 +0100)]
docker: consolidate ceph-ansible and ceph-docker varible
This commit re-uses some of the existing ceph-ansible variables for a
containirzed deployment. There is no reasons why we should add new
variables for the containerized deployment.