Skip to content

The vault password file was not found #3703

@ReenigneArcher

Description

@ReenigneArcher
Summary

Ansible lint gives warnings/errors that it cannot find the vault password file. I create my vault password using the following step before the ansible lint step.

run: echo ${{ secrets.MYSECRET || '1234' }} > .vault-password

I run ansible lint with this step:

uses: ansible/[email protected]
with:
  args: "playbooks/"
Issue Type
  • Bug Report
OS / ENVIRONMENT
ansible-lint --version

6.18.0 (using ansible-lint as github action)

  • ansible installation method: pypi
  • ansible-lint installation method: using github action
STEPS TO REPRODUCE

Set password file location in config.

ansible.cfg

vault_password_file=.vault-password

Create vault passowrd file in workflow, as shown above.

Run ansible lint action, as shown above.

Desired Behavior

Find the file, that was created.

Possible security bugs should be reported via email to [email protected]

Actual Behavior

File was not found.

Warning: /some_playbook.yml:1 [WARNING]: Error getting vault password file (default): The vault password file /runner/_work/ansible-repo/ansible-repo/.vault-password was not found

Additional Information

I use the same method of creating the .vault-password file to actually run ansible playbooks inside of GitHub actions, and that works fine. I also did not have this problem on the now depreciated ansible-lint-action repository.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions