roles/taskotron/execdb/tasks/main.yml and roles/taskotron/execdb/templates/alembic.ini.j2 use local_ prefix for the execdb variables, but roles/taskotron/execdb/templates/settings.py.j2 was not. This removes the need for both local_execdb_db_{user, pasword} and execdb_db_{user, pasword} in the private vars for the local deployment.
Details
Diff Detail
- Lint
Lint Skipped - Unit
Unit Tests Skipped
I'd rather solve this in a similar way to how I've been refactoring the non-local playbooks: keep setting the local_* vars as they are but set the non-prefixed variables in a group_vars file. For example, set execdb_db_password: {{ local_execdb_password }} in the inventory/group_vars/resultsdb file. resultsdb for dev and stg should mostly be set up that way. I won't be doing production until we upgrade to F22, though.
I really want to get rid of those conditional blocks in the templates and tasks - they're confusing and encourage silly repetition. Apparently I missed some of it in the execdb role :-/
How about this? I "finished" the resultsdb/execdb refactoring, so there are (almost) no conditionals in the tasks/templates, using the aforementioned method of setting stuff in the inventory/group_vars. I hope I grasped the idea right, though.
LGTM - can you wait until tomorrow before pushing this, though - infra freeze is still in place until tomorrow morning and this affects some production systems.
New changes look good to me
roles/taskotron/resultsdb-backend/templates/settings.py.j2 | ||
---|---|---|
10 | When we have more than one of these, I'd prefer to see {% when deployment_type in ['local', 'dev'] %} |
When we have more than one of these, I'd prefer to see {% when deployment_type in ['local', 'dev'] %}