diff options
author | Yanis Guenane <yanis@guenane.org> | 2020-03-11 15:08:57 +0100 |
---|---|---|
committer | AlanCoding <arominge@redhat.com> | 2020-04-17 02:55:59 +0200 |
commit | 541b9607f52a5fd2e071019416386b2917d5192e (patch) | |
tree | 67f63756a643b5aa9edea1ac3c37dcf63a3d1cf3 | |
parent | Merge pull request #6735 from wenottingham/true-is-relative (diff) | |
download | awx-541b9607f52a5fd2e071019416386b2917d5192e.tar.xz awx-541b9607f52a5fd2e071019416386b2917d5192e.zip |
Collections: Adding a requirements.yml file
-rw-r--r-- | MANIFEST.in | 1 | ||||
-rw-r--r-- | Makefile | 6 | ||||
-rw-r--r-- | installer/roles/image_build/templates/Dockerfile.j2 | 2 | ||||
-rw-r--r-- | requirements/collections_requirements.yml | 5 | ||||
-rw-r--r-- | tools/docker-compose/Dockerfile | 3 |
5 files changed, 16 insertions, 1 deletions
diff --git a/MANIFEST.in b/MANIFEST.in index 3c687ce2da..53e1d8eebd 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -10,6 +10,7 @@ recursive-include awx/playbooks *.yml recursive-include awx/lib/site-packages * recursive-include awx/plugins *.ps1 recursive-include requirements *.txt +recursive-include requirements *.yml recursive-include config * recursive-include docs/licenses * recursive-exclude awx devonly.py* @@ -209,7 +209,11 @@ requirements_awx: virtualenv_awx requirements_awx_dev: $(VENV_BASE)/awx/bin/pip install -r requirements/requirements_dev.txt -requirements: requirements_ansible requirements_awx +requirements_collections: + mkdir -p $(COLLECTION_BASE) + ansible-galaxy collection install -r requirements/collections_requirements.yml -p $(COLLECTION_BASE) + +requirements: requirements_ansible requirements_awx requirements_collections requirements_dev: requirements_awx requirements_ansible_py3 requirements_awx_dev requirements_ansible_dev diff --git a/installer/roles/image_build/templates/Dockerfile.j2 b/installer/roles/image_build/templates/Dockerfile.j2 index 3ec1d91f55..b9b5d5e4fd 100644 --- a/installer/roles/image_build/templates/Dockerfile.j2 +++ b/installer/roles/image_build/templates/Dockerfile.j2 @@ -74,8 +74,10 @@ ADD requirements/requirements_ansible.txt \ requirements/requirements.txt \ requirements/requirements_tower_uninstall.txt \ requirements/requirements_git.txt \ + requirements/collections_requirements.yml \ /tmp/requirements/ RUN cd /tmp && VENV_BASE="/var/lib/awx/venv" make requirements_awx requirements_ansible_py3 +RUN cd /tmp && COLLECTION_BASE="/var/lib/awx/vendor/inventory_collections" make requirements_collections COPY {{ awx_sdist_file }} /tmp/{{ awx_sdist_file }} RUN echo "{{ awx_version }}" > /var/lib/awx/.tower_version && \ diff --git a/requirements/collections_requirements.yml b/requirements/collections_requirements.yml new file mode 100644 index 0000000000..6e4f78fd26 --- /dev/null +++ b/requirements/collections_requirements.yml @@ -0,0 +1,5 @@ +--- +collections: + - name: awx.awx + version: 9.2.0 + source: https://galaxy.ansible.com diff --git a/tools/docker-compose/Dockerfile b/tools/docker-compose/Dockerfile index 4611247231..1f8b290e64 100644 --- a/tools/docker-compose/Dockerfile +++ b/tools/docker-compose/Dockerfile @@ -92,9 +92,12 @@ ADD requirements/requirements.txt \ requirements/requirements_dev.txt \ requirements/requirements_ansible_uninstall.txt \ requirements/requirements_tower_uninstall.txt \ + requirements/collections_requirements.yml \ /tmp/requirements/ RUN mkdir -p /venv && chmod g+w /venv RUN cd /tmp && VENV_BASE="/venv" make requirements_dev +RUN mkdir -p /vendor/inventory_collections && chmod g+w /vendor/inventory_collections +RUN cd /tmp && COLLECTION_BASE="/vendor/inventory_collections" make requirements_collections # Use the distro provided npm to bootstrap our required version of node RUN npm install -g n && n 10.15.0 && dnf remove -y nodejs |