diff --git a/ansible/roles/kolla-ansible/library/kolla_passwords.py b/ansible/roles/kolla-ansible/library/kolla_passwords.py
index 4c728f75fe0e8f461fac793f912dad86af579a1c..f3c53b1f2785ccb18da49834b8fd1761e6c56fad 100644
--- a/ansible/roles/kolla-ansible/library/kolla_passwords.py
+++ b/ansible/roles/kolla-ansible/library/kolla_passwords.py
@@ -20,6 +20,7 @@ short_description: Generates a kolla-ansible passwords file
 
 from ansible.module_utils.basic import *
 
+import os
 import os.path
 import shutil
 import tempfile
@@ -238,6 +239,8 @@ def kolla_passwords(module):
             checksum_temp_file = module.sha1(temp_file_path)
             changed = checksum_dest != checksum_temp_file
         else:
+            os.makedirs(os.path.dirname(module.params['dest']),
+                        exist_ok=True)
             changed = True
 
         # Encrypt the file.
diff --git a/releasenotes/notes/fix-kolla-passwords-f1b5d051c494b4d8.yaml b/releasenotes/notes/fix-kolla-passwords-f1b5d051c494b4d8.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..3a3c1490dea9dae608ef7ee3b13005a4bd221dbb
--- /dev/null
+++ b/releasenotes/notes/fix-kolla-passwords-f1b5d051c494b4d8.yaml
@@ -0,0 +1,8 @@
+---
+fixes:
+  - |
+    Fixes an issue where generation of ``passwords.yml`` for Kolla Ansible
+    could fail if the directory containing the file does not exist. This is
+    typical in a multiple environment setup, when creating a new environment.
+    See `story 2010293 <https://storyboard.openstack.org/#!/story/2010293>`_
+    for details.