Problem with goldyfruit's Ansible Deployment

Hey guys,

I have a problem with installing Mycroft on an Raspberry Pi 4 via the Ansible Playbooks from @goldyfruit .
I followed this guide: Deploy Mycroft AI voice assistant on Raspberry Pi using Ansible | Opensource.com

I did the following steps:

  • Flash the 64-Bit Raspberry Pi OS (64-bit) (The normal one, neither Light nor Full)
  • activated ssh and tested it
  • set a password
  • installed Ansible on my Host and added the Playbooks and the roles
  • just copied the install-custom.yml (maybe there’s the problem? Where though?)
  • and then I run the playbook (after installing sshpass, since it was required)

The Problem is, it throws an error at “TASK [smartgic.mycroft : Install Python packages]”:

fatal: [rpi4b01]: FAILED! => {"changed": false, "msg": "'/usr/bin/apt-mark manual python3-pip python3-venv python3-dev python3-wheel' failed: E: Could not create temporary file for /var/lib/apt/extended_states - mkstemp (13: Permission denied)\nE: Failed to write temporary StateFile /var/lib/apt/extended_states\n", "rc": 100, "stderr": "E: Could not create temporary file for /var/lib/apt/extended_states - mkstemp (13: Permission denied)\nE: Failed to write temporary StateFile /var/lib/apt/extended_states\n", "stderr_lines": ["E: Could not create temporary file for /var/lib/apt/extended_states - mkstemp (13: Permission denied)", "E: Failed to write temporary StateFile /var/lib/apt/extended_states"], "stdout": "python3-pip was already set to manually installed.\n", "stdout_lines": ["python3-pip was already set to manually installed."]}

PLAY RECAP *****************************************************************************************************************************************************************************
rpi4b01                    : ok=53   changed=4    unreachable=0    failed=1    skipped=5    rescued=0    ignored=0

Edit: Here’s an image, so you don’t have to scroll that ^^

And I have no idea what I did wrong. I tried it again, same error.
I also looked into the python.yml (since that’s closest to the stuff in the error message i found) at /home/beo/.ansible/roles/smartgic.mycroft/tasks but realized I don’t understand the syntax at all. Only thing I could see was, that python was installed. Tried to do that manually, but all four where already installed.

The only other thing that stood out where the Task [smartgic.prepi : Update /etc/hosts] which threw the Warning:

Module remote_tmp /root/.ansible/tmp did not exist and was created with a mode of 0700, this may cause issues when running as another user. To avoid this, create the
remote_tmp dir with the correct permissions manually

I tried to manually give 777 rights to the tmp folder, just to be sure, but nothing changed, same error. The warning didn’t show up this time though.

So yeah, I’m out of ideas.
Did I overlook something? Can someone perhaps help me with the error message?

I like the idea of Ansible very much, and if nothing works I guess I can run the prepi-role only and install mycroft normally as in Linux - Mycroft AI or maybe try his docker installation. I don’t fully understand it just by reading yet, so for now I’d prefer the native one.
Also, I don’t want to use Picroft, it seems quite dead to me. Stable one didn’t boot at all (“Board needs newer software”) and the Release Candidate only worked until reboot. It’s not exactly new either.
So yeah, it would be great if someone could point me to the right direction here.

Thanks a lot and props to @goldyfruit for the whole Ansible thing. I don’t understand it, but it seems awesome :sweat_smile:

No one who has an idea?
Maybe it would be better to open an issue directly on @goldyfruit 's github?