Closed jakobsack closed 11 years ago
I think this is a very specific need for this use case. It will not be very useful for the average user. But we will try to include this if it doesn't add too much complexity to the current code.
Commited to master
the possibility to use the git repo. It will be included on the next release of the cookbook.
You must set the attributes node['owncloud']['deploy_from_git']
to true
and node['owncloud']['git_ref']
to the git reference you want to deploy. Also, you need to add the git
recipe to the run_list.
Role example:
name "owncloud_git"
description "Install ownCloud from Git"
default_attributes(
"owncloud" => {
"server_name" => "cloud.mysite.com",
"deploy_from_git" => true,
"git_ref" => "master"
}
)
run_list(
"recipe[git]",
"recipe[owncloud]"
)
One problem I see is that 3rdparty
submodule is not included on all the branches of the core
ownCloud repo (mainly old ones). In these cases, the 3rdparty
directory will not be created. Is this an impediment for your tests?
Thank you very much, this looks great!
However, the downloadable stable version already contains all the apps from the apps repository. Do you think you can add these apps as well or shall we do this in our own cookbook?
To install the apps I'd clone the apps repository to "apps2" and add this path to the config.php.
@raulr I don't see any problems with the 3rdparty
submodule as this only affects old branches. We are not going to test those.
Wow, thanks!
I will look into it as soon as the stable tests of our testing work!
@jakobsack I think that cloning apps repository should be testing cookbook's responsibility.
The config needs to be set before including the owncloud
cookbook and the apps
repo cloned afterwards. Something like this should work:
node.default['owncloud']['config']['apps_paths'] = [
{
'path' => ::File.join(node['owncloud']['dir'], 'apps'),
'url' => '/apps',
'writable' => true
},
{
'path' => ::File.join(node['owncloud']['dir'], 'apps2'),
'url' => '/apps2',
'writable' => false
}
]
include_recipe "owncloud"
git 'clone owncloud apps' do
destination ::File.join(node['owncloud']['dir'], 'apps2')
repository 'https://github.com/owncloud/apps.git'
action :sync
end
@raulr ok, we will include it in our own cookbook.
Very cool that your config generator is flexible enough to do this out of the box :-)
@jakobsack and @Gomez we have just released the 0.2.0
version of the cookbook including this feature and the Nginx support.
Thanks! I just updated our acceptance-testing to the new version.
It would be awesome if ownCloud could be installed from git repositories.
Background
We, the ownCloud QA team, would like to use this cookbook for setting up our testing vms. However, this requires some improvements like the ability to use different webservers or install ownCloud from different sources.
Code only used for testing will be in another cookbook, see https://github.com/owncloud/acceptance-testing for more information.