From 6e908ed67b76b7246cd77f709e268aa56af1500f Mon Sep 17 00:00:00 2001 From: Skyler Layne Date: Tue, 17 Oct 2017 14:22:57 -0400 Subject: [PATCH 1/4] ensure make is installed ensure make package is installed, needed by curb. --- recipes/_base_aem_setup.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/_base_aem_setup.rb b/recipes/_base_aem_setup.rb index b63561b..c2dcc16 100644 --- a/recipes/_base_aem_setup.rb +++ b/recipes/_base_aem_setup.rb @@ -33,6 +33,10 @@ action :nothing end.run_action(:install) +package 'make' do + action :nothing +end.run_action(:install) + chef_gem 'curb' do compile_time false if Chef::Resource::ChefGem.method_defined?(:compile_time) action :nothing From 1ccf3f5d02eed8416ece57876810b7b35f1c587b Mon Sep 17 00:00:00 2001 From: Skyler Layne Date: Tue, 17 Oct 2017 14:23:21 -0400 Subject: [PATCH 2/4] bump VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index ccbccc3..c043eea 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.2.0 +2.2.1 From 94a41b0eee9f03a9e52d98c57f4b7856afdd5dfa Mon Sep 17 00:00:00 2001 From: Skyler Layne Date: Tue, 17 Oct 2017 14:40:31 -0400 Subject: [PATCH 3/4] support chef 13 Signed-off-by: Skyler Layne --- VERSION | 2 +- metadata.rb | 1 + recipes/_base_aem_setup.rb | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index c043eea..b1b25a5 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.2.1 +2.2.2 diff --git a/metadata.rb b/metadata.rb index 675f5b4..717ddd2 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,6 +4,7 @@ name 'aem' description 'Installs/Configures Adobe AEM' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) +chef_version '~> 13' version IO.read(File.join(File.dirname(__FILE__), 'VERSION')) recipe 'aem::author', 'Installs AEM Author instance.' diff --git a/recipes/_base_aem_setup.rb b/recipes/_base_aem_setup.rb index c2dcc16..7197555 100644 --- a/recipes/_base_aem_setup.rb +++ b/recipes/_base_aem_setup.rb @@ -71,7 +71,7 @@ system true shell '/bin/bash' home '/home/crx' - supports manage_home: true + manage_home true action :create end end From 08425bf4f87869a7a3ba0f93427953ce1a136b07 Mon Sep 17 00:00:00 2001 From: Skyler Layne Date: Tue, 17 Oct 2017 14:43:20 -0400 Subject: [PATCH 4/4] check chef version for crx user Signed-off-by: Skyler Layne --- VERSION | 2 +- metadata.rb | 1 - recipes/_base_aem_setup.rb | 25 ++++++++++++++++++------- 3 files changed, 19 insertions(+), 9 deletions(-) diff --git a/VERSION b/VERSION index b1b25a5..5859406 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.2.2 +2.2.3 diff --git a/metadata.rb b/metadata.rb index 717ddd2..675f5b4 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,7 +4,6 @@ name 'aem' description 'Installs/Configures Adobe AEM' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) -chef_version '~> 13' version IO.read(File.join(File.dirname(__FILE__), 'VERSION')) recipe 'aem::author', 'Installs AEM Author instance.' diff --git a/recipes/_base_aem_setup.rb b/recipes/_base_aem_setup.rb index 7197555..2008738 100644 --- a/recipes/_base_aem_setup.rb +++ b/recipes/_base_aem_setup.rb @@ -66,13 +66,24 @@ action :install end else - user 'crx' do - comment 'crx/aem role user' - system true - shell '/bin/bash' - home '/home/crx' - manage_home true - action :create + if Chef::VERSION.to_f >= 13 + user 'crx' do + comment 'crx/aem role user' + system true + shell '/bin/bash' + home '/home/crx' + manage_home true + action :create + end + else + user 'crx' do + comment 'crx/aem role user' + system true + shell '/bin/bash' + home '/home/crx' + supports manage_home: true + action :create + end end end