Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tiller does not produce when the only data source is Vault #43

Open
liquid-sky opened this issue Dec 22, 2016 · 2 comments
Open

Tiller does not produce when the only data source is Vault #43

liquid-sky opened this issue Dec 22, 2016 · 2 comments
Assignees

Comments

@liquid-sky
Copy link
Contributor

liquid-sky commented Dec 22, 2016

Hi @markround,

I've noticed that with the configuration below, tiller does not produce parsed templates:

data_sources: [ vault ]
template_sources: [ file ]

environments:
    production:
        postgres_dashboard.erb:
            target: 'parsed_template.txt'

vault:
 url: 'https://<MASTER_URL>'
 token: '<VAULT_TOKEN>'
➜  tiller  tiller -b . -v -n -e production
tiller v0.9.7 (https://github.com/markround/tiller) <[email protected]>
Using configuration from .
Using plugins from /usr/local/lib/tiller


Using environment production
Template sources loaded [FileTemplateSource]
Data sources loaded [EnvironmentDataSource, VaultDataSource]
Available templates : ["postgres_dashboard.erb"]
Template generation completed

Although when data source is set to data_sources: [ vault, file ], it builds a template and saves to a file:

Building template postgres_dashboard.erb
Not running as root, so not setting ownership/permissions on parsed_template.txt

It fails with vault as an only data source, because target values variable is empty and file generation is skipped.

So if there's either defaults section and defaults data source or file section and file data source, all works fine.

defaults:
  postgres_dashboard.erb:
      target: 'template_temp.txt

Not a huge issue, but perhaps Vault plugin documentation should have a note that common.yaml should have an environment or defaults sources with target section specified?

@markround markround self-assigned this Jan 4, 2017
@markround
Copy link
Owner

markround commented Jan 4, 2017

Thanks for the comments! I think that this section in the README covers it:

File : The default template_ and data_source plugins which read templates from ERB files on disk, and values from YAML file(s). This use-case is discussed below in this main document. Important: You normally will want to enable these plugins unless you are fetching everything from another data source, as Tiller needs this to read configuration blocks from common.yaml, fetch templates from disk etc.

However, I should probably make that bigger and bolder as it seems to be a fairly common problem. Maybe reference it in the Gotchas section as well as referencing it in plugin docs. Actually, I keep meaning to go through and have a major documentation overhaul and tidy-up (the main README has got pretty large and unwieldy), this would be an ideal time to get started on that ;)

@liquid-sky
Copy link
Contributor Author

Awesome, thanks Mark! 👍

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

No branches or pull requests

2 participants