Remove inventory and vault scripts (#2696)

* Remove inventory and vault scripts.

* Remove foreman inventory script tests.
This commit is contained in:
Felix Fontein 2021-06-19 15:06:58 +02:00 committed by GitHub
commit 08f7ad06be
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
78 changed files with 2 additions and 12854 deletions

View file

@ -1,3 +0,0 @@
shippable/cloud/group1
cloud/foreman
needs/file/scripts/inventory/foreman.py

View file

@ -1,10 +0,0 @@
#!/usr/bin/env bash
# Wrapper to use the correct Python interpreter and support code coverage.
REL_SCRIPT="../../../../scripts/inventory/foreman.py"
ABS_SCRIPT="$("${ANSIBLE_TEST_PYTHON_INTERPRETER}" -c "import os; print(os.path.abspath('${REL_SCRIPT}'))")"
# Make sure output written to current directory ends up in the temp dir.
cd "${OUTPUT_DIR}"
python.py "${ABS_SCRIPT}" "$@"

View file

@ -1,50 +0,0 @@
#!/usr/bin/env bash
set -euo pipefail
export FOREMAN_HOST="${FOREMAN_HOST:-localhost}"
export FOREMAN_PORT="${FOREMAN_PORT:-8080}"
export FOREMAN_INI_PATH="${OUTPUT_DIR}/foreman.ini"
############################################
# SMOKETEST WITH SIMPLE INI
############################################
cat > "$FOREMAN_INI_PATH" <<FOREMAN_INI
[foreman]
url = http://${FOREMAN_HOST}:${FOREMAN_PORT}
user = ansible-tester
password = secure
ssl_verify = False
use_reports_api = False
FOREMAN_INI
# use ansible to validate the return data
ansible-playbook -i foreman.sh test_foreman_inventory.yml --connection=local
RC=$?
if [[ $RC != 0 ]]; then
echo "foreman inventory script smoketest failed"
exit $RC
fi
############################################
# SMOKETEST WITH NON-ASCII INI
############################################
cat > "$FOREMAN_INI_PATH" <<FOREMAN_INI
[foreman]
url = http://${FOREMAN_HOST}:${FOREMAN_PORT}
user = ansible-tester
password = secure
ssl_verify = False
group_prefix = Ľuboš_
FOREMAN_INI
# use ansible to validate the return data
ansible-playbook -i foreman.sh test_foreman_inventory.yml --connection=local
RC=$?
if [[ $RC != 0 ]]; then
echo "foreman inventory script non-ascii failed"
exit $RC
fi

View file

@ -1,7 +0,0 @@
- name: check the foreman inventory script result size and attributes
hosts: localhost
gather_facts: False
tasks:
- assert:
that:
- "{{ groups['all']|length > 900 }}"