Skip to content

[chore][ansible] Fix failing Windows tests #6246

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

Merged
merged 7 commits into from
May 23, 2025
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
13 changes: 13 additions & 0 deletions .github/workflows/ansible.yml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,19 @@ jobs:
url=$( echo "$json" | jq -r ".versions[] | select(.version == \"${box_version}\") | .providers[] | select(.name == \"virtualbox\") | .url" )
wget -nv -O /tmp/vagrant.box $url

- name: Clean VirtualBox cache
run: |
# Related issues:
# https://bbs.archlinux.org/viewtopic.php?id=298056
# https://forums.virtualbox.org/viewtopic.php?t=112438
# https://forums.virtualbox.org/viewtopic.php?t=112481
echo "3" | sudo tee /proc/sys/vm/drop_caches
echo "1" | sudo tee /proc/sys/vm/drop_caches

- name: free after clean cache
run: |
free -h

Copy link
Contributor

Choose a reason for hiding this comment

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

Nit;
Shall we add a debug flag to display this info if needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought about it but I'm thinking of keeping it for now. My thought process is that with flaky failures we ideally want this output when it fails, as it may pass the next time when it's run with debugging.

I'd be happy to remove in the future if it's too much noise or use a debug flag if you disagree 👍

- name: Run Molecule tests.
run: molecule --debug -v --base-config ./molecule/config/windows.yml test -s ${{ matrix.scenario }} -p ${{ matrix.distro }}
env:
Expand Down
14 changes: 7 additions & 7 deletions deployments/ansible/molecule/config/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ driver:
name: virtualbox
platforms:
- name: "2016"
box: cdaf/WindowsServer
box_version: ${MOLECULE_VAGRANT_BOX_VERSION:-2022.09.01}
box: StefanScherer/windows_2016
box_version: ${MOLECULE_VAGRANT_BOX_VERSION:-2019.02.14}
box_url: ${MOLECULE_VAGRANT_BOX_URL}
cpus: 2
memory: 4096
memory: 8192
provider_options:
gui: false
linked_clone: true
Expand All @@ -29,11 +29,11 @@ platforms:
- "winrm.retry_limit = 50"
- "winrm.retry_delay = 10"
- name: "2019"
box: gusztavvargadr/windows-server-2019-standard
box_version: ${MOLECULE_VAGRANT_BOX_VERSION:-1809.0.2312}
box: StefanScherer/windows_2019
box_version: ${MOLECULE_VAGRANT_BOX_VERSION:-2021.05.15}
box_url: ${MOLECULE_VAGRANT_BOX_URL}
cpus: 2
memory: 4096
memory: 8192
provider_options:
gui: false
linked_clone: true
Expand All @@ -43,7 +43,7 @@ platforms:
box_version: ${MOLECULE_VAGRANT_BOX_VERSION:-2102.0.2312}
box_url: ${MOLECULE_VAGRANT_BOX_URL}
cpus: 2
memory: 4096
memory: 8192
provider_options:
gui: false
linked_clone: true
Expand Down