Skip to content

Fix for upgrade Fails Due to Missing Vault Password File .local_repo_credentials_key During Credential Decryption#4169

Merged
abhishek-sa1 merged 2 commits intodell:pub/q1_devfrom
mithileshreddy04:pub/q1_dev
Mar 12, 2026
Merged

Fix for upgrade Fails Due to Missing Vault Password File .local_repo_credentials_key During Credential Decryption#4169
abhishek-sa1 merged 2 commits intodell:pub/q1_devfrom
mithileshreddy04:pub/q1_dev

Conversation

@mithileshreddy04
Copy link
Contributor

Removed redundant decryption logic, added tasks to take care of scenarios where file is decrypted with key present and with key missing

- name: Warn about plaintext copy without key
ansible.builtin.debug:
msg: |
user_registry_credential.yml copied in plaintext (no key present in backup).
Copy link
Collaborator

Choose a reason for hiding this comment

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

message should be in vars

ansible.builtin.debug:
msg: |
user_registry_credential.yml was plaintext in backup.
Copied and encrypted using provided key.
Copy link
Collaborator

Choose a reason for hiding this comment

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

move all message to vars

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Made the change

ansible.builtin.copy:
src: "{{ backup_location }}/.local_repo_credentials_key"
dest: "{{ input_project_dir }}/.local_repo_credentials_key"
mode: '0600'
Copy link
Collaborator

Choose a reason for hiding this comment

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

move the mode also to vars

block:
- name: Copy local_repo_credentials_key from backup (unencrypted case)
ansible.builtin.copy:
src: "{{ backup_location }}/.local_repo_credentials_key"
Copy link
Collaborator

Choose a reason for hiding this comment

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

use key and file name as variable file as used many places

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Made the change

@abhishek-sa1 abhishek-sa1 self-requested a review March 12, 2026 07:00
@abhishek-sa1 abhishek-sa1 merged commit bbd7a6a into dell:pub/q1_dev Mar 12, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants