summaryrefslogtreecommitdiffstats
path: root/roles/openshift_cli
Commit message (Collapse)AuthorAgeFilesLines
* Move more plugins to lib_utilsMichael Gugino2018-01-102-205/+2
| | | | | | | This commit continues moving plugins into lib_utils. This commit does not move any plugins for add-on roles such as logging and metrics.
* Properly cast crio boolean variables to boolMichael Gugino2018-01-081-1/+1
| | | | | | | | | | | Variables that are specifically booleans should be cast to bool. This is because users may sometimes pass them as string values. This is particularly prevalent when using ini-style inventories. Affected-by: https://github.com/ansible/ansible/issues/34591 Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1531592
* Remove openshift.common.{is_atomic|is_containerized}Michael Gugino2017-12-201-4/+4
| | | | | We set these variables using facts in init, no need to duplicate the logic all around the codebase.
* Relocate filter plugins to lib_utilsMichael Gugino2017-12-181-0/+1
| | | | | | | | | | | | | | This commit relocates filter_plugings to lib_utils, changes the namespacing to prevent unintended use of older versions that may be present in filter_plugins/ directory on existing installs. Add lib_utils to meta depends for roles Also consolidate some plugins into lib_utils from various other areas. Update rpm spec, obsolete plugin rpms.
* Deprecate using Ansible tests as filtersRussell Teague2017-12-141-2/+2
|
* Ensure that clients are version boundScott Dodson2017-12-121-1/+1
|
* Remove openshift.common.service_typeMichael Gugino2017-12-071-1/+1
| | | | | | | | This commit removes openshift.common.service_type in favor of openshift_service_type. This commit also removes r_openshift_excluder_service_type from plays in favor of using the role's defaults.
* Remove all uses of openshift.common.admin_binaryScott Dodson2017-12-071-2/+5
| | | | Replace with `oc adm`
* Implement container runtime roleMichael Gugino2017-12-013-8/+5
|
* retry package operationsLuke Meyer2017-11-301-0/+4
| | | | | | When a package install/update fails due to network blips or other spotty availability, retry it. If the failure is a real failure (e.g. package is really not there) it still fails after 3 tries (Ansible default).
* Remove openshift.common.cli_imageMichael Gugino2017-11-271-4/+4
| | | | | This commit removes openshift.common.cli_image in favor of openshift_cli_image.
* Fix system_images_registry variableMichael Gugino2017-11-222-2/+7
| | | | Simplify the logic for this variable.
* container_binary_sync: Remove atomic prefix from imageSteve Milner2017-11-071-1/+28
| | | | Signed-off-by: Steve Milner <smilner@redhat.com>
* cli: use the correct name for the master system containerGiuseppe Scrivano2017-10-231-2/+2
| | | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* cli: do not pull again the image when using DockerGiuseppe Scrivano2017-10-231-3/+6
| | | | | | | | When CRI-O is used and the CLI image is already pulled into Docker then use it also for copying the CLI files to the host instead of pulling it once again in the ostree storage. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* Remove openshift-commonMichael Gugino2017-09-061-1/+0
| | | | | | | | | Most of this role's purpose was to set facts. The vast majority of these facts were simply redefining user-supplied variables. This commit also removes various artifacts leftover from previous versions, as well as variables that seem to be entirely unused.
* Merge pull request #5214 from giuseppe/rename_crio_variableScott Dodson2017-08-291-1/+1
|\ | | | | crio: rename openshift_docker_use_crio to openshift_use_crio
| * cri-o: rename openshift_docker_use_crio to openshift_use_crioGiuseppe Scrivano2017-08-251-1/+1
| | | | | | | | | | | | | | It is confusing to have _docker_ in the name, since they are two different backends. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | Remove near-meta role openshift_cli_factsMichael Gugino2017-08-251-1/+1
|/ | | | | | | | openshift_cli_facts only runs a single task, and otherwise the only existence is to serve as a link in the dependency chain towards openshift_facts. This commit flattens openshift_cli into one role.
* bug: container_binary_sync no longer moves upon symlinksSteve Milner2017-08-151-0/+5
| | | | | | | | | | | | | | | | | With origin 1.5, /usr/local/bin/oc was a symlink to /usr/local/bin/openshift. During the container_binary_sync updated versions of both binaries are copied to the host. First openshift is copied to /usr/local/bin/openshift followed by copying oc to /usr/local/bin/oc. Since oc is a symlink back to /usr/local/bin/openshift the end result was everything linked to oc. This change adds a check before copying a binary. If the destination is a symlink then said symlink is removed before copying the new binary over. Fixed #4965 Reference: https://github.com/openshift/openshift-ansible/issues/4965
* cli_image: do not require Docker when using CRI-OGiuseppe Scrivano2017-08-032-25/+83
| | | | | | Use atomic to copy the CLI binaries to the host. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* Remove vim configuration from Python filesRodolfo Carvalho2017-05-091-2/+0
| | | | | | | In a project where contributors are free to use whatever editor they want and we have linting tools that verify the proper formatting of Python files, it should not be required to have a vim-specific line in Python files.
* update tests and flake8/pylint fixesJason DeTiberus2016-11-291-3/+3
|
* Refactor to use Ansible package moduleRussell Teague2016-11-171-2/+2
| | | | | The Ansible package module will call the correct package manager for the underlying OS.
* Switch from "oadm" to "oc adm" and fix bug in binary sync.Devan Goodwin2016-10-191-1/+6
| | | | | | | | Found bug syncing binaries to containerized hosts where if a symlink was pre-existing, but pointing to the wrong destination, it would not be corrected. Switched to using oc adm instead of oadm.
* Skip the docker role in early upgrade stages.Devan Goodwin2016-09-291-0/+1
| | | | | | | | This improves the situation further and prevents configuration changes from accidentally triggering docker restarts, before we've evacuated nodes. Now in two places, we skip the role entirely, instead of previous implementation which only skipped upgrading the installed version. (which did not catch config issues)
* Copy openshift binaries instead of using wrapper script.Devan Goodwin2016-07-213-44/+135
| | | | | | | | | | | | | | For containerized masters, we previously create a wrapper script to run the docker CLI image and clean up afterward, but this approach is much slower than having the binary on the native system. Instead we now use an ansible module to handle the logic of syncing the various OpenShift binaries and symlinks for client tools out onto the host. The module will correctly report changed if modifications were needed. Substantial speed improvement for containerized installs which requires many openshift/oc commands.
* Stop reporting changes when docker pull is already up to date.Devan Goodwin2016-07-201-0/+2
|
* Merge remote-tracking branch 'upstream/master' into upgrade33Devan Goodwin2016-07-141-0/+3
|\
| * Move the bash completion into the cli role. Only add when not containerizedTim Bielawa2016-07-141-0/+4
| |
* | Remove all debug used during devel of openshift_version.Devan Goodwin2016-07-081-3/+0
| |
* | More version fixes.Devan Goodwin2016-06-161-1/+1
| |
* | Always populate openshift_image_tag and openshift_pkg_version.Devan Goodwin2016-06-151-2/+1
| | | | | | | | | | Allows the use of arbitrary tags, precise control over containers and rpms, and likely mixed environments.
* | Merge branch 'master' into upgrade33Devan Goodwin2016-06-102-3/+7
|\ \ | |/
| * Fix Docker 1.10 problems with empty tags and trailing :Devan Goodwin2016-06-062-4/+8
| | | | | | | | | | | | | | | | | | | | Docker 1.10 is no longer tolerant of commands like "docker pull myimage:" when we do not have an image tag in play. Adjust all occurrences with one that only includes the : if a version is defined. Adjust the containerized CLI wrappers for a similar problem.
* | Refactor openshift_version behavior.Devan Goodwin2016-05-301-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Very early in playbooks we must init the openshift_version for each host. First we determine it for the master, logic now is pushed into the openshift_docker role which we run only on first master via openshift_cli. Facts are reloaded leaving us with a first master with openshift.common.version fact we can then re-use on all other hosts. The correct version of docker should be installed as well. We then set openshift_version for all other hosts by re-using the master fact.
* | Work towards determining openshift_version when unspecified.Devan Goodwin2016-05-251-0/+1
| | | | | | | | | | | | | | openshift_docker role was largely useless now, but also almost did what we needed. (deps ordering still needs to be changed) Remove defaulting of openshift_version.
* | Set openshift_version in config playbooks for first master.Devan Goodwin2016-05-253-7/+3
| | | | | | | | | | | | | | Starting to remove openshift.docker.openshift_version fact usage. openshift_version should no longer contain a leading 'v' for containerized installs, just a version number.
* | Debug output.Devan Goodwin2016-05-251-0/+6
|/
* Fix 'recursive loop detected in template string' for upgrading variable.Andrew Butcher2016-05-161-1/+1
|
* Do not upgrade containers to latest avail during a normal config run.Devan Goodwin2016-05-121-1/+1
|
* The openshift_docker role must set the version facts for containerized installsBrenton Leanhardt2016-04-141-1/+1
| | | | | | QE found that for fresh installs we were basing the docker version facts of the images that could be pulled prior to configuring /etc/sysconfig/docker. This is an edge case but something we need to fix.
* Merge pull request #1695 from brenton/bz1323123Brenton Leanhardt2016-04-061-0/+0
|\ | | | | Fixing bugs 1322788 and 1323123
| * Bug 1322788 - The IMAGE_VERSION wasn't added to atomic-openshift-master-api ↵Brenton Leanhardt2016-04-011-0/+0
| | | | | | | | and atomic-openshift-master-controllers
* | Downgrade to docker 1.8.2 if installing OSE < 3.2Scott Dodson2016-04-051-1/+0
|/
* Bug 1320829 - Ensure docker installed for factsJason DeTiberus2016-03-312-7/+2
| | | | | | - gather facts requiring docker only if docker is present and running - Update reference to etcd role in playbooks/common/openshift-etcd/config.yml to use openshift_etcd
* Move common common facts to openshift_factsJason DeTiberus2016-03-152-2/+2
| | | | | | | - Prevents roles that need common facts from needing to require openshift_common, which pulls in the openshift binary. - Add dependency on openshift_facts to os_firewall, since it uses openshift.common facts
* Docker role refactorJason DeTiberus2016-03-142-6/+7
| | | | | | | | | | | | | | | - refactors the docker role to push generic config into docker role and wrap openshift specific variables into an openshift_docker role and it's dependent openshift_docker_facts role - adds support for setting --confirm-def-push flag (Resolves https://github.com/openshift/openshift-ansible/issues/1014) - moves docker related facts from common/node roles to a new docker role - renames cli_docker_* role varialbes to openshift_docker-* (maintaining backward compatibility) - update role dependencies to pull in openshift_docker conditionally based on is_containerized - remove playbooks/common/openshift-docker since the docker role is now conditionally included
* reverting back to pre-pulling the master imageBrenton Leanhardt2016-03-081-0/+5
|
* Support openshift_image_tagBrenton Leanhardt2016-03-072-1/+3
| | | | | | | | | | | | | This is the containerized openshift_pkg_version equivalent. Originally I was hoping to reuse openshift_pkg_version for containerized installs but the fact that it's very coupled to yum made that pretty ugly. However, I did opt to rely on the previously existing 'openshift_version' variable. Containerized and RPM installs can both use that variable and it will be set appropriately if either openshift_pkg_version or openshift_image_tag are set. I suspect someday containerized installs will be the only option and I didn't can to have thinkgs like openshift_pkg_version and openshift_image_tag in the playbooks anymore the necessary.