From 51fc103d82516489ddd2c15228b9f675da0e3d4e Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Mon, 15 Oct 2018 12:59:56 -0700 Subject: [PATCH] Fix env for plugin installs In an earlier change we set up npm installations to happen in the eplite user's homedir rather than in the log dir. We did this because with systemd we no longer have a log dir on all installations. The etherpad lite plugin installation was still attemping to use the log dir which doesn't work on newer systems. Update this plugin installation process to use the homedir like the normal installation process. Also add plugin installation to the tests we run to test this works now. Change-Id: I5cff75c89b16d61c4902c920259b82463306833e --- manifests/plugin.pp | 7 +++++-- spec/acceptance/fixtures/etherpad_lite.pp | 4 ++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/manifests/plugin.pp b/manifests/plugin.pp index f319a71..2ca944f 100644 --- a/manifests/plugin.pp +++ b/manifests/plugin.pp @@ -6,8 +6,11 @@ define etherpad_lite::plugin { cwd => $etherpad_lite::modules_dir, path => $etherpad_lite::path, user => $etherpad_lite::ep_user, - environment => "HOME=${etherpad_lite::base_log_dir}/${etherpad_lite::ep_user}", + environment => "HOME=/home/${etherpad_lite::ep_user}", creates => "${etherpad_lite::modules_dir}/${plugin_name}", - require => Class['etherpad_lite'] + require => [ + Class['etherpad_lite'], + User[$etherpad_lite::ep_user], + ], } } diff --git a/spec/acceptance/fixtures/etherpad_lite.pp b/spec/acceptance/fixtures/etherpad_lite.pp index 3ff55eb..99481ee 100644 --- a/spec/acceptance/fixtures/etherpad_lite.pp +++ b/spec/acceptance/fixtures/etherpad_lite.pp @@ -19,3 +19,7 @@ class { '::etherpad_lite::site': database_password => 'password', etherpad_title => 'A fake title', } + +etherpad_lite::plugin { 'ep_headings': + require => Class['etherpad_lite'], +}