X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/5992e0107fb06ff56345873f1f93d0595c3ff231..900cc4d0e89348d1396fc3dc38d131e486c2914c:/cookbooks/mediawiki/resources/extension.rb?ds=sidebyside diff --git a/cookbooks/mediawiki/resources/extension.rb b/cookbooks/mediawiki/resources/extension.rb index 6dc79ea7e..47e807052 100644 --- a/cookbooks/mediawiki/resources/extension.rb +++ b/cookbooks/mediawiki/resources/extension.rb @@ -28,6 +28,7 @@ property :version, :kind_of => String property :repository, :kind_of => String property :tag, :kind_of => String property :reference, :kind_of => String +property :compose, :kind_of => [TrueClass, FalseClass], :default => false property :update_site, :kind_of => [TrueClass, FalseClass], :default => true action :create do @@ -83,6 +84,17 @@ action :create do only_if { ::File.exist?(extension_script) } end end + + if new_resource.compose # ~FC023 + execute "composer-#{new_resource.extension}" do + action :nothing + command "composer install --no-dev" + cwd extension_directory + user node[:mediawiki][:user] + group node[:mediawiki][:group] + subscribes :run, "git[#{extension_directory}]" + end + end end action :delete do