René Welches

TECH NOTES TO MYSELF

Securing Proxmox API Tokens with Apple Keychain Access for Terraform

Store and retrieve Proxmox credentials securely using macOS Keychain instead of plain text files

Introduction

When working with Terraform to manage Proxmox infrastructure, you need to authenticate. Proxmox offers three options: API Token, Auth Ticket, and Username/Password.

In my setup, I use API Tokens for authentication with Proxmox. The approach described here should also work with username/password combinations.

Storing these credentials in plain text files or environment variables poses security risks, especially if you accidentally commit them to version control. macOS provides a secure solution: the Keychain Access, which encrypts and manages passwords system-wide.