cisagov / skeleton-ansible-role

A skeleton project for quickly getting a new cisagov Ansible role started.
Creative Commons Zero v1.0 Universal
7 stars 6 forks source link

Add `arm64` platforms to Molecule configuration #174

Closed jsf9k closed 5 months ago

jsf9k commented 9 months ago

๐Ÿ—ฃ Description

This pull request adds arm64 platforms to our Molecule testing.

๐Ÿ’ญ Motivation and context

We need to test our Ansible roles on arm64 so that we can migrate to Graviton instances.

๐Ÿงช Testing

Automated tests pass.

โœ… Pre-approval checklist

jsf9k commented 9 months ago

@mcdonnnj and @felddy - The systemd_enabled scenario succeeds locally on my Linux laptop, if I start with neither the amd64 nor the aarch64 geerlingguy/docker-debian11-ansible:latest Docker images in docker images. Do you know why it would be failing in GitHub Actions?

Note that I am running the tonistiigi/binfmt foo before running molecule test --scenario-name systemd_enabled.

(When I ran this on my local machine I ran molecule test --scenario-name systemd_enabled --destroy never followed by molecule login -s systemd_enabled --host debian11-systemd-amd64 and molecule login -s systemd_enabled --host debian11-systemd-aarch64. In both cases uname -m confirmed that the appropriate hardware was being used.)

jsf9k commented 8 months ago

I fixed the previous problem by setting up buildx before running the Molecule tests, and the tests now pass the first time (when no local version of the Docker image exists) just as they do on my local machine. Unfortunately, they fail the second time (when a local version of the Docker image exists) just as it does on my local machine.

jsf9k commented 6 months ago

Ah, right. I keep forgetting that every Ansible role is broken. :cry: