From 577af3d973f86f24b1d9b541e42e86bc85b62c9b Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Mon, 20 Nov 2017 09:05:02 -0600 Subject: [PATCH] Remove ensure-reno role With everything switched to ensure-sphinx, this is no longer needed. Change-Id: I51a9b28e7d8519cce6c01aaa3060319120fb6a27 Depends-On: I2d0222225f4ae6c45d09f9352c256062e2535d63 --- roles/ensure-reno/README.rst | 10 ---- roles/ensure-reno/defaults/main.yaml | 1 - roles/ensure-reno/tasks/main.yaml | 73 ---------------------------- 3 files changed, 84 deletions(-) delete mode 100644 roles/ensure-reno/README.rst delete mode 100644 roles/ensure-reno/defaults/main.yaml delete mode 100644 roles/ensure-reno/tasks/main.yaml diff --git a/roles/ensure-reno/README.rst b/roles/ensure-reno/README.rst deleted file mode 100644 index a5fa64d6..00000000 --- a/roles/ensure-reno/README.rst +++ /dev/null @@ -1,10 +0,0 @@ -Ensure reno is installed - -**Role Variables** - -.. zuul:rolevar:: zuul_work_dir - :default: {{ zuul.project.src_dir }} - - Directory to operate in. Needed only for a little while until we have - projects migrated to not need to be installed just to generate - release notes. diff --git a/roles/ensure-reno/defaults/main.yaml b/roles/ensure-reno/defaults/main.yaml deleted file mode 100644 index 9739eb17..00000000 --- a/roles/ensure-reno/defaults/main.yaml +++ /dev/null @@ -1 +0,0 @@ -zuul_work_dir: "{{ zuul.project.src_dir }}" diff --git a/roles/ensure-reno/tasks/main.yaml b/roles/ensure-reno/tasks/main.yaml deleted file mode 100644 index 91e447d1..00000000 --- a/roles/ensure-reno/tasks/main.yaml +++ /dev/null @@ -1,73 +0,0 @@ -- name: Install gettext package - package: - name: gettext - state: present - become: yes - -- name: Check to see if the constraints file exists - stat: - path: "{{ constraints_file }}" - get_checksum: false - get_mime: false - get_md5: false - register: stat_results - when: constraints_file is defined - -- name: Fail if constraints file does not exist - fail: - msg: "Variable constraints_file is set but file does not exist." - when: - - constraints_file is defined - - not stat_results|skipped and not stat_results.stat.exists - -- name: Record file location - set_fact: - upper_constraints: "-c {{ constraints_file }}" - when: not stat_results|skipped and stat_results.stat.exists - -- name: Setup venv - shell: - chdir: '{{ zuul_work_dir }}' - executable: /bin/bash - cmd: | - set -e - set -x - - OPTIONAL_REQUIREMENTS_SOURCES=" - docs/requirements.txt - requirements.txt - test-requirements.txt - " - - UPPER_CONSTRAINTS="{{ upper_constraints }}" - # NOTE(dhellmann): Place the virtualenv in $HOME because - # that is where the build-releasenotes task expects to find it. - python -m virtualenv $HOME/.venv - VENV=$HOME/.venv/bin - $VENV/pip install sphinx $UPPER_CONSTRAINTS - $VENV/pip install openstackdocstheme $UPPER_CONSTRAINTS - $VENV/pip install reno $UPPER_CONSTRAINTS - - # Install from other optional sources, ignoring errors. - # TODO(jaegerandi): as below, these extra requirements are only - # for things like oslosphix which some releasenotes jobs still - # depend on. - for reqfile in $OPTIONAL_REQUIREMENTS_SOURCES; do - if [ -e $reqfile ] ; then - $VENV/pip install -r $reqfile $UPPER_CONSTRAINTS || true - fi - done - - # Optionally, install local requirements - if [ -e releasenotes/requirements.txt ] ; then - $VENV/pip install -r releasenotes/requirements.txt $UPPER_CONSTRAINTS - fi - # TODO(jaegerandi): Remove once all repos are fixed. - # Try installing current repo in case it needs to be available for - # example for version number calculation. Ignore any failures here. - if [ -f setup.cfg ] ; then - # NOTE(dhellmann): We do *NOT* use constraints here because - # that makes it impossible to install anything that is listed - # in the constraints list. - $VENV/pip install . || true - fi