{"action":"created","issue":{"url":"https://api.github.com/repos/jsok/hiera-vault/issues/23","repository_url":"https://api.github.com/repos/jsok/hiera-vault","labels_url":"https://api.github.com/repos/jsok/hiera-vault/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/jsok/hiera-vault/issues/23/comments","events_url":"https://api.github.com/repos/jsok/hiera-vault/issues/23/events","html_url":"https://github.com/jsok/hiera-vault/issues/23","id":160914394,"number":23,"title":"[Question] Should ENV vars take precendence over hiera.yaml values?","user":{"login":"jovandeginste","id":3170771,"avatar_url":"https://avatars.githubusercontent.com/u/3170771?v=3","gravatar_id":"","url":"https://api.github.com/users/jovandeginste","html_url":"https://github.com/jovandeginste","followers_url":"https://api.github.com/users/jovandeginste/followers","following_url":"https://api.github.com/users/jovandeginste/following{/other_user}","gists_url":"https://api.github.com/users/jovandeginste/gists{/gist_id}","starred_url":"https://api.github.com/users/jovandeginste/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jovandeginste/subscriptions","organizations_url":"https://api.github.com/users/jovandeginste/orgs","repos_url":"https://api.github.com/users/jovandeginste/repos","events_url":"https://api.github.com/users/jovandeginste/events{/privacy}","received_events_url":"https://api.github.com/users/jovandeginste/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-06-17T15:28:12Z","updated_at":"2016-06-20T11:25:39Z","closed_at":null,"body":"I can not run hiera-vault without a token - it throws an error then. I can add a token in hiera.yaml, but if this is a real token I can't commit it. If this is a fake token, I can not override it.\r\n\r\nIn my mind, I should be able to add a fake token (or no token, without error) to my hiera.yaml file, and pass the token via the ENV:\r\n\r\n```\r\nVAULT_TOKEN=mytoken hiera -c hiera.yaml mykey\r\n```\r\n\r\nThis means that all sanity tests will succeed (with empty values for secrets, which should be fine), and in production the real vault token will be used and thus the real secrets.\r\n\r\nDoes my story make sense? If so, I have proof-of-concept code to have ENV variables for address and token take precedence over whatever is in hiera.yaml"},"comment":{"url":"https://api.github.com/repos/jsok/hiera-vault/issues/comments/227116817","html_url":"https://github.com/jsok/hiera-vault/issues/23#issuecomment-227116817","issue_url":"https://api.github.com/repos/jsok/hiera-vault/issues/23","id":227116817,"user":{"login":"jovandeginste","id":3170771,"avatar_url":"https://avatars.githubusercontent.com/u/3170771?v=3","gravatar_id":"","url":"https://api.github.com/users/jovandeginste","html_url":"https://github.com/jovandeginste","followers_url":"https://api.github.com/users/jovandeginste/followers","following_url":"https://api.github.com/users/jovandeginste/following{/other_user}","gists_url":"https://api.github.com/users/jovandeginste/gists{/gist_id}","starred_url":"https://api.github.com/users/jovandeginste/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jovandeginste/subscriptions","organizations_url":"https://api.github.com/users/jovandeginste/orgs","repos_url":"https://api.github.com/users/jovandeginste/repos","events_url":"https://api.github.com/users/jovandeginste/events{/privacy}","received_events_url":"https://api.github.com/users/jovandeginste/received_events","type":"User","site_admin":false},"created_at":"2016-06-20T11:25:39Z","updated_at":"2016-06-20T11:25:39Z","body":"You could obviously add an extra configuration item in `hiera.yaml`?\r\n\r\nI (personally) think this is counter-intuitive - in my experience, usually variables set in the environment take precedence over configuration files."}}
{"actor":{"display_login":"jovandeginste"}}