Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .ansible-lint
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ exclude_paths:
- .markdownlint.yaml
- examples/roles/
mock_roles:
- linux-system-roles.template
- linux-system-roles.trustee_attestation_server
supported_ansible_also:
- "2.14.0"
2 changes: 1 addition & 1 deletion .github/workflows/ansible-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: Install tox, tox-lsr
run: |
set -euxo pipefail
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.16.0"
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.17.0"

- name: Convert role to collection format
id: collection
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ansible-managed-var-comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
- name: Install tox, tox-lsr
run: |
set -euxo pipefail
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.16.0"
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.17.0"
- name: Run ansible-plugin-scan
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ansible-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
- name: Install tox, tox-lsr
run: |
set -euxo pipefail
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.16.0"
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.17.0"

- name: Convert role to collection format
run: |
Expand Down
17 changes: 10 additions & 7 deletions .github/workflows/qemu-kvm-integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
- { image: "centos-9", env: "qemu-ansible-core-2-16" }
- { image: "centos-10", env: "qemu-ansible-core-2-17" }
- { image: "fedora-42", env: "qemu-ansible-core-2-19" }
- { image: "fedora-43", env: "qemu-ansible-core-2-19" }
- { image: "fedora-43", env: "qemu-ansible-core-2-20" }
- { image: "leap-15.6", env: "qemu-ansible-core-2-18" }

# container
Expand All @@ -41,9 +41,9 @@ jobs:
# - { image: "centos-10", env: "container-ansible-core-2-17" }
- { image: "centos-10-bootc", env: "container-ansible-core-2-17" }
- { image: "fedora-42", env: "container-ansible-core-2-17" }
- { image: "fedora-43", env: "container-ansible-core-2-19" }
- { image: "fedora-43", env: "container-ansible-core-2-20" }
- { image: "fedora-42-bootc", env: "container-ansible-core-2-17" }
- { image: "fedora-43-bootc", env: "container-ansible-core-2-19" }
- { image: "fedora-43-bootc", env: "container-ansible-core-2-20" }

env:
TOX_ARGS: "--skip-tags tests::infiniband,tests::nvme,tests::scsi"
Expand Down Expand Up @@ -110,7 +110,7 @@ jobs:
python3 -m pip install --upgrade pip
sudo apt update
sudo apt install -y --no-install-recommends git ansible-core genisoimage qemu-system-x86
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.16.0"
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.17.0"

# HACK: Drop this when moving this workflow to 26.04 LTS
- name: Update podman to 5.x for compatibility with bootc-image-builder's podman 5
Expand Down Expand Up @@ -175,10 +175,10 @@ jobs:
if: steps.check_platform.outputs.supported && startsWith(matrix.scenario.env, 'container')
run: |
set -euo pipefail
# HACK: debug.py/profile.py setup is broken
export LSR_CONTAINER_PROFILE=false
export LSR_CONTAINER_PRETTY=false
rc=0
# we cannot skip these on the first test
export SKIP_REQUIREMENTS=false
export SKIP_CALLBACK_PLUGINS=false
for t in tests/tests_*.yml; do
if tox -e ${{ matrix.scenario.env }} -- --image-name ${{ matrix.scenario.image }} $t > ${t}.log 2>&1; then
echo "PASS: $(basename $t)"
Expand All @@ -188,6 +188,9 @@ jobs:
mv "${t}.log" "${t}-FAIL.log"
rc=1
fi
# we can skip these on subsequent runs
export SKIP_REQUIREMENTS=true
export SKIP_CALLBACK_PLUGINS=true
done
exit $rc

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ jobs:
tf_scope: private
api_key: ${{ secrets.TF_API_KEY_RH }}
update_pull_request_status: false
tmt_plan_filter: "tag:playbooks_parallel,template"
tmt_plan_filter: "tag:playbooks_parallel,trustee_attestation_server"

- name: Set final commit status
uses: myrotvorets/set-commit-status-action@master
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/weekly_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ name: Weekly CI trigger
on: # yamllint disable-line rule:truthy
workflow_dispatch:
schedule:
- cron: 0 0 * * 6
- cron: 30 23 * * 6
env:
BRANCH_NAME: weekly-ci
COMMIT_MESSAGE: "ci: This PR is to trigger periodic CI testing"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Role Name

[![ansible-lint.yml](https://github.com/linux-system-roles/template/actions/workflows/ansible-lint.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/ansible-lint.yml) [![ansible-test.yml](https://github.com/linux-system-roles/template/actions/workflows/ansible-test.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/ansible-test.yml) [![codespell.yml](https://github.com/linux-system-roles/template/actions/workflows/codespell.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/codespell.yml) [![markdownlint.yml](https://github.com/linux-system-roles/template/actions/workflows/markdownlint.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/markdownlint.yml) [![qemu-kvm-integration-tests.yml](https://github.com/linux-system-roles/template/actions/workflows/qemu-kvm-integration-tests.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/qemu-kvm-integration-tests.yml) [![shellcheck.yml](https://github.com/linux-system-roles/template/actions/workflows/shellcheck.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/shellcheck.yml) [![tft.yml](https://github.com/linux-system-roles/template/actions/workflows/tft.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/tft.yml) [![tft_citest_bad.yml](https://github.com/linux-system-roles/template/actions/workflows/tft_citest_bad.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/tft_citest_bad.yml) [![woke.yml](https://github.com/linux-system-roles/template/actions/workflows/woke.yml/badge.svg)](https://github.com/linux-system-roles/template/actions/workflows/woke.yml)
[![ansible-lint.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/ansible-lint.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/ansible-lint.yml) [![ansible-test.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/ansible-test.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/ansible-test.yml) [![codespell.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/codespell.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/codespell.yml) [![markdownlint.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/markdownlint.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/markdownlint.yml) [![qemu-kvm-integration-tests.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/qemu-kvm-integration-tests.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/qemu-kvm-integration-tests.yml) [![shellcheck.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/shellcheck.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/shellcheck.yml) [![tft.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/tft.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/tft.yml) [![tft_citest_bad.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/tft_citest_bad.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/tft_citest_bad.yml) [![woke.yml](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/woke.yml/badge.svg)](https://github.com/linux-system-roles/trustee_attestation_server/actions/workflows/woke.yml)

![template](https://github.com/linux-system-roles/template/workflows/tox/badge.svg)

Expand Down
8 changes: 4 additions & 4 deletions contributing.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Contributing to the template Linux System Role
# Contributing to the trustee_attestation_server Linux System Role

## Where to start

Expand All @@ -12,12 +12,12 @@ This has all of the common information that all role developers need:
* How to create git commits and submit pull requests

**Bugs and needed implementations** are listed on
[Github Issues](https://github.com/linux-system-roles/template/issues).
[Github Issues](https://github.com/linux-system-roles/trustee_attestation_server/issues).
Issues labeled with
[**help wanted**](https://github.com/linux-system-roles/template/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22)
[**help wanted**](https://github.com/linux-system-roles/trustee_attestation_server/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22)
are likely to be suitable for new contributors!

**Code** is managed on [Github](https://github.com/linux-system-roles/template), using
**Code** is managed on [Github](https://github.com/linux-system-roles/trustee_attestation_server), using
[Pull Requests](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/about-pull-requests).

## Running CI Tests Locally
Expand Down
6 changes: 3 additions & 3 deletions plans/README-plans.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Introduction CI Testing Plans

Linux System Roles CI runs [tmt](https://tmt.readthedocs.io/en/stable/index.html) test plans in [Testing farm](https://docs.testing-farm.io/Testing%20Farm/0.1/index.html) with the [tft.yml](https://github.com/linux-system-roles/template/blob/main/.github/workflows/tft.yml) GitHub workflow.
Linux System Roles CI runs [tmt](https://tmt.readthedocs.io/en/stable/index.html) test plans in [Testing farm](https://docs.testing-farm.io/Testing%20Farm/0.1/index.html) with the [tft.yml](https://github.com/linux-system-roles/trustee_attestation_server/blob/main/.github/workflows/tft.yml) GitHub workflow.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick (typo): Consider capitalizing "Farm" in "Testing Farm" to match the official service name.

The official name is "Testing Farm" with both words capitalized. Please update the link text accordingly.

Suggested change
Linux System Roles CI runs [tmt](https://tmt.readthedocs.io/en/stable/index.html) test plans in [Testing farm](https://docs.testing-farm.io/Testing%20Farm/0.1/index.html) with the [tft.yml](https://github.com/linux-system-roles/trustee_attestation_server/blob/main/.github/workflows/tft.yml) GitHub workflow.
Linux System Roles CI runs [tmt](https://tmt.readthedocs.io/en/stable/index.html) test plans in [Testing Farm](https://docs.testing-farm.io/Testing%20Farm/0.1/index.html) with the [tft.yml](https://github.com/linux-system-roles/trustee_attestation_server/blob/main/.github/workflows/tft.yml) GitHub workflow.


The `plans/test_playbooks_parallel.fmf` plan is a test plan that runs test playbooks in parallel on multiple managed nodes.
`plans/test_playbooks_parallel.fmf` is generated centrally from `https://github.com/linux-system-roles/.github/`.
Expand All @@ -16,7 +16,7 @@ The `plans/test_playbooks_parallel.fmf` plan does the following steps:
2. Does the required preparation on systems.
3. For the given role and the given PR, runs the general test from [test.sh](https://github.com/linux-system-roles/tft-tests/blob/main/tests/general/test.sh).

The [tft.yml](https://github.com/linux-system-roles/template/blob/main/.github/workflows/tft.yml) workflow runs the above plan and uploads the results to our Fedora storage for public access.
The [tft.yml](https://github.com/linux-system-roles/trustee_attestation_server/blob/main/.github/workflows/tft.yml) workflow runs the above plan and uploads the results to our Fedora storage for public access.
This workflow uses Testing Farm's Github Action [Schedule tests on Testing Farm](https://github.com/marketplace/actions/schedule-tests-on-testing-farm).

## Running Tests
Expand Down Expand Up @@ -47,7 +47,7 @@ You can run tests locally with the `tmt try` cli or remotely in Testing Farm.
$ TESTING_FARM_API_TOKEN=<your_api_token> \
testing-farm request --pipeline-type="tmt-multihost" \
--plan-filter="tag:playbooks_parallel" \
--git-url "https://github.com/<my_user>/template" \
--git-url "https://github.com/<my_user>/trustee_attestation_server" \
--git-ref "<my_branch>" \
--compose CentOS-Stream-9 \
-e "SYSTEM_ROLES_ONLY_TESTS=tests_default.yml" \
Expand Down
2 changes: 1 addition & 1 deletion plans/test_playbooks_parallel.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ provision:
environment:
# ensure versions are strings!
SR_ANSIBLE_VER: "2.17"
SR_REPO_NAME: template
SR_REPO_NAME: trustee_attestation_server
SR_PYTHON_VERSION: "3.12"
SR_ONLY_TESTS: "" # tests_default.yml
SR_TEST_LOCAL_CHANGES: true
Expand Down
8 changes: 4 additions & 4 deletions tests/vars/rh_distros_vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@
# file is playbooks/templates/tests/vars/rh_distros_vars.yml
---
# Ansible distribution identifiers that the role treats like RHEL
__template_rh_distros:
__trustee_attestation_server_rh_distros:
- AlmaLinux
- CentOS
- RedHat
- Rocky

# Same as above but includes Fedora
__template_rh_distros_fedora: "{{ __template_rh_distros + ['Fedora'] }}"
__trustee_attestation_server_rh_distros_fedora: "{{ __trustee_attestation_server_rh_distros + ['Fedora'] }}"

# Use this in conditionals to check if distro is Red Hat or clone
__template_is_rh_distro: "{{ ansible_facts['distribution'] in __template_rh_distros }}"
__trustee_attestation_server_is_rh_distro: "{{ ansible_facts['distribution'] in __trustee_attestation_server_rh_distros }}"

# Use this in conditionals to check if distro is Red Hat or clone, or Fedora
__template_is_rh_distro_fedora: "{{ ansible_facts['distribution'] in __template_rh_distros_fedora }}"
__trustee_attestation_server_is_rh_distro_fedora: "{{ ansible_facts['distribution'] in __trustee_attestation_server_rh_distros_fedora }}"