From ff7b31363595f4f99efcc5f29789fded4043a295 Mon Sep 17 00:00:00 2001
From: Alexander Olofsson <alexander.olofsson@liu.se>
Date: Mon, 10 Aug 2020 16:37:40 +0200
Subject: [PATCH] Skip file extension on CSR template kind param

The Foreman routes do not allow an extension on the kind, leading to 404
errors.
---
 .../concerns/foreman_wds/unattended_controller_extensions.rb    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/controllers/concerns/foreman_wds/unattended_controller_extensions.rb b/app/controllers/concerns/foreman_wds/unattended_controller_extensions.rb
index 9fb2057..5d9f870 100644
--- a/app/controllers/concerns/foreman_wds/unattended_controller_extensions.rb
+++ b/app/controllers/concerns/foreman_wds/unattended_controller_extensions.rb
@@ -1,7 +1,7 @@
 module ForemanWds
   module UnattendedControllerExtensions
     def host_template
-      return wds_render_csr if params[:kind] == 'csr_attributes.yaml'
+      return wds_render_csr if params[:kind] == 'csr_attributes'
       return wds_deploy_localboot if params[:kind] == 'wds_localboot'
       super
     end
-- 
GitLab