Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Run containers on ubuntu #1260

Draft
wants to merge 11 commits into
base: master
Choose a base branch
from

Commits on Jul 22, 2024

  1. utils: Rewrite run-tests.sh to use functions and extenal scripts

    To modify Azure tests and depend on shell scripts and pytest instead
    of molecule, the run-tests.sh script has been rewritten to depend on
    bash functions and on a bash script that prepare and start a testing
    container.
    
    This patch adds a new script, 'utils/setup_test_container.sh' that
    can be used to start a new container, using either podman or docker,
    based on the available ansible-freeipa images. The new container can
    then be used to run ansible-freeipa tests against it.
    
    Also the following files with bash functions were added, and are
    used by both scripts:
    
        utils/shansible: Functions to run playbooks in the container
        utils/shcontainer: Functions to setup/run a container
        utils/shfun: Generic shell helper functions (e.g.: log)
    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    2f8280e View commit details
    Browse the repository at this point in the history
  2. tests: Allow to set Python interpreter to be used by Ansible

    On some systems it is required or desired to run Ansible with a specific
    Python interpreter. This patch allows the selection of the Python binary
    to use for the pytest playbook tests by setting the environment variable
    IPA_PYTHON_PATH. Set it the the full path of the Python interpreter.
    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    4b43c3b View commit details
    Browse the repository at this point in the history
  3. upstream ci: Remove 'molecule' from tests.

    This patch removes 'molecule' as a dependency for tests, by using the
    scripts under `utils` to setup the environment.
    
    By not using molecule, we have more flexibility on using either docker
    or podman as the container engine, and makes it easy to reproduce the
    environment on different distros, allowing for a more consistent error
    reproduction off Azure.
    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    5678fd5 View commit details
    Browse the repository at this point in the history
  4. ci lint: Allow ShellCheck to test source-d scripts.

    As the scripts 'utils/run-tests.sh' and 'utils/setup_test_container.sh'
    use some scripts as function libraries, this change forces shellcheck to
    also verify those scripts.
    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    745cd10 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    8302fe9 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2cefdbf View commit details
    Browse the repository at this point in the history
  7. Remove log limit.

    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    bbc72cc View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    f182e74 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    b973448 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    c5aba73 View commit details
    Browse the repository at this point in the history
  11. Disable podman log.

    rjeffman committed Jul 22, 2024
    Configuration menu
    Copy the full SHA
    e7f3f88 View commit details
    Browse the repository at this point in the history