# Failed to find required executable "apt-key" in paths

**URL:** https://discourse.roots.io/t/failed-to-find-required-executable-apt-key-in-paths/29954
**Category:** trellis
**Created:** 2025-09-30T15:54:23Z
**Posts:** 4

## Post 1 by @mZoo — 2025-09-30T15:54:23Z

Hi, all.

```
ansible --version
ansible [core 2.18.9]
```

## Trellis provision on new DO Droplet.

## Task: Add an Apt signing key, uses whichever key is at the URL

### error

```
File "/tmp/ansible_ansible.builtin.apt_key_payload_0mvcy6sp/ansible_ansible.builtin.apt_key_payload.zip/ansible/module_utils/basic.py", line 1365, in get_bin_path
    bin_path = get_bin_path(arg=arg, opt_dirs=opt_dirs)
  File "/tmp/ansible_ansible.builtin.apt_key_payload_0mvcy6sp/ansible_ansible.builtin.apt_key_payload.zip/ansible/module_utils/common/process.py", line 64, in get_bin_path
    raise ValueError('Failed to find required executable "%s" in paths: %s' % (arg, os.pathsep.join(paths)))
fatal: [IP ADDRESS]: FAILED! => {
    "changed": false,
    "invocation": {
        "module_args": {
            "data": null,
            "file": null,
            "id": null,
            "keyring": null,
            "keyserver": null,
            "state": "present",
            "url": "https://mariadb.org/mariadb_release_signing_key.asc",
            "validate_certs": true
        }
    },
    "msg": "Failed to find required executable \"apt-key\" in paths: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin"
}
```

I can manually download it and it looks like a valid key. Not sure where I would save it on the

Been seeing posts re: `apt-key` is deprecated.

---

## Post 2 by @ben — 2025-09-30T16:39:50Z

What version of Trellis? What version of Ubuntu?

---

## Post 3 by @mZoo — 2025-09-30T18:12:40Z

Oh yes, sorry @ben meant to come back to this. The issue was because I had selected a non-LTS OS in the droplet creation.

Got caught up in aws-cli ansible updates, as it doesn’t seem to exist currently as a pip package and requires zip file download. Evaluating [this ansible role from boutetnico](http://github.com/boutetnico/ansible-role-awscli).

---

## Post 4 by @ben — 2025-09-30T18:23:50Z

No worries, I noticed the other day that DO defaults their new droplet Ubuntu version to a non-LTS.. kinda strange
