{"action":"opened","issue":{"url":"https://api.github.com/repos/mitchellh/packer/issues/3171","repository_url":"https://api.github.com/repos/mitchellh/packer","labels_url":"https://api.github.com/repos/mitchellh/packer/issues/3171/labels{/name}","comments_url":"https://api.github.com/repos/mitchellh/packer/issues/3171/comments","events_url":"https://api.github.com/repos/mitchellh/packer/issues/3171/events","html_url":"https://github.com/mitchellh/packer/issues/3171","id":132495731,"number":3171,"title":"PACKER_CACHE_DIR env var left empty if cacheDir set to default \"packer_cache\"","user":{"login":"tylert","id":152904,"avatar_url":"https://avatars.githubusercontent.com/u/152904?v=3","gravatar_id":"","url":"https://api.github.com/users/tylert","html_url":"https://github.com/tylert","followers_url":"https://api.github.com/users/tylert/followers","following_url":"https://api.github.com/users/tylert/following{/other_user}","gists_url":"https://api.github.com/users/tylert/gists{/gist_id}","starred_url":"https://api.github.com/users/tylert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tylert/subscriptions","organizations_url":"https://api.github.com/users/tylert/orgs","repos_url":"https://api.github.com/users/tylert/repos","events_url":"https://api.github.com/users/tylert/events{/privacy}","received_events_url":"https://api.github.com/users/tylert/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-02-09T18:33:40Z","updated_at":"2016-02-09T18:33:40Z","closed_at":null,"body":"Currently, main.go checks for the presence of the environment variable \"PACKER_CACHE_DIR\" and sets \"cacheDir\" to this value.  When \"PACKER_CACHE_DIR\" is left undefined, cacheDir is given the default value \"packer_cache\".\r\n\r\nThis behaviour works correctly (and a workaround is to always define \"PACKER_CACHE_DIR\"), however, there isn't currently any nice way to provide a value for this location that may be used in packer templates."}}