shopware5 / SwagMediaS3

MIT License
22 stars 17 forks source link

Please provide further install docs #2

Closed runningman84 closed 8 years ago

runningman84 commented 8 years ago

I would like to install and activate this plugin via chef.

Where should I extract the zip contents?

runningman84 commented 8 years ago

ok this seems to work


remote_file "#{Chef::Config[:file_cache_path]}/shopware_s3plugin.zip" do
  source node['myshop']['s3plugin_zip']
  owner 'root'
  group 'root'
  checksum node['myshop']['s3plugin_zip_checksum']
end

execute 'deploy_shopware_s3plugin' do
  command "unzip #{Chef::Config[:file_cache_path]}/shopware_s3plugin.zip"
  cwd node['myshop']['server_root'] + "/engine/Shopware/Plugins/Local"
  not_if { File.exist?(node['myshop']['server_root'] +  "/engine/Shopware/Plugins/Local" + '/SwagMediaS3/Bootstrap.php') }
  action :run
  notifies :run, 'execute[chmod_shopware_plugins]'
  notifies :run, 'execute[refresh_shopware_plugins]'
  notifies :run, 'execute[install_shopware_plugins_s3plugin]'
  notifies :run, 'execute[activate_shopware_plugins_s3plugin]'
end

execute 'chmod_shopware_plugins' do
  command 'chown -R www-data.www-data ' +  node['myshop']['server_root'] + "/engine/Shopware/Plugins/Local"
  action :nothing
end

execute 'refresh_shopware_plugins' do
  command node['myshop']['server_root'] + "/bin/console sw:plugin:refresh"
  user "www-data"
  action :nothing
end

execute 'install_shopware_plugins_s3plugin' do
  command node['myshop']['server_root'] + "/bin/console sw:plugin:install SwagMediaS3"
  user "www-data"
  action :nothing
end

execute 'activate_shopware_plugins_s3plugin' do
  command node['myshop']['server_root'] + "/bin/console sw:plugin:activate SwagMediaS3"
  user "www-data"
  action :nothing
end
janbuecker commented 8 years ago

Hi, we've just released a release package including all needed files. You can simply unzip its contents to engine/Shopware/Plugins/Local/ and activate it via cli.

I would like to close this issue or do you have another question regarding this topic?