aboutsummaryrefslogtreecommitdiff
path: root/docker
diff options
context:
space:
mode:
Diffstat (limited to 'docker')
-rw-r--r--docker/macros.j23
1 files changed, 3 insertions, 0 deletions
diff --git a/docker/macros.j2 b/docker/macros.j2
index 48c56208c..34d67335c 100644
--- a/docker/macros.j2
+++ b/docker/macros.j2
@@ -43,6 +43,9 @@
{% endmacro %}
{% macro configure_user(name, groups=None, shell=None, homedir=None) %}
+{%- if name not in users %}
+{{ raise_error("Failed to find configuration for '" + name + "' user. Try specifying '" + name + "-user' config section.") }}
+{%- endif %}
{% set user=users[name] %}
{%- if not homedir %}
{% set homedir='/var/lib/' + name %}