]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-cookbooks.git/commitdiff
Support civetweb rgw frontend 204/head
authorÁcs Sándor <acs.sandor@ustream.tv>
Fri, 31 Jul 2015 20:36:04 +0000 (22:36 +0200)
committerÁcs Sándor <acs.sandor@ustream.tv>
Fri, 31 Jul 2015 20:36:04 +0000 (22:36 +0200)
README.md
attributes/radosgw.rb
recipes/radosgw_civetweb.rb [new file with mode: 0644]
templates/default/ceph.conf.erb

index 493ea9cc8213b28cbb94d2fe310533a031f4748b..19f473ba518d16a95ea6e583324677c6ccd82da7 100644 (file)
--- a/README.md
+++ b/README.md
@@ -126,7 +126,7 @@ Ceph Rados Gateway nodes should use the ceph-radosgw role
 * `node['ceph']['radosgw']['admin_email']` - the admin email address to configure in the web server
 * `node['ceph']['radosgw']['rgw_addr']` - the web server's bind address, such as *:80
 * `node['ceph']['radosgw']['rgw_port']` - if set, connects to the radosgw fastcgi over this port instead of a unix socket
-* `node['ceph']['radosgw']['webserver_companion']` - defaults to 'apache2', but can be set to false to not configure anything
+* `node['ceph']['radosgw']['webserver_companion']` - defaults to 'apache2', but it can be set to 'civetweb', or to false in order to leave it unconfigured
 * `node['ceph']['radosgw']['path']` - where to save the s3gw.fcgi file
 * `node['ceph']['config']['global']['rgw dns name']` -  the main domain of the radosgw daemon, to calculate the bucket name from a subdomain
 
index 11e39c2884c81e85bd7db5f928e12bec74b48fc3..246f74432154407854a1ddb4bf9fc11841f84578 100644 (file)
@@ -23,7 +23,7 @@ default['ceph']['radosgw']['api_fqdn'] = 'localhost'
 default['ceph']['radosgw']['admin_email'] = 'admin@example.com'
 default['ceph']['radosgw']['rgw_addr'] = '*:80'
 default['ceph']['radosgw']['rgw_port'] = false
-default['ceph']['radosgw']['webserver_companion'] = 'apache2' # can be false
+default['ceph']['radosgw']['webserver_companion'] = 'apache2' # can be civetweb or false
 default['ceph']['radosgw']['use_apache_fork'] = true
 default['ceph']['radosgw']['init_style'] = node['ceph']['init_style']
 
diff --git a/recipes/radosgw_civetweb.rb b/recipes/radosgw_civetweb.rb
new file mode 100644 (file)
index 0000000..ac8d4d1
--- /dev/null
@@ -0,0 +1 @@
+# Civetweb has no dependencies. It is included since the Firefly release.
index d17fe32a67669212cc4cd94d7bc69d83e2ad2a9f..c58d8790b3beb1ccade91671f7ac868f42338e45 100644 (file)
 
 <% if (@is_rgw) -%>
 [client.radosgw.<%= node['hostname'] %>]
+<% if node['ceph']['radosgw']['webserver_companion'] == 'civetweb' -%>
+  <% if node['ceph']['radosgw']['rgw_port'] == false %>
+  rgw frontends = "civetweb port=80"
+<% else -%>
+  rgw frontends = "civetweb port=<%=node['ceph']['radosgw']['rgw_port']%>"
+<% end -%>
+<% end -%>
   host = <%= node['hostname'] %>
   rgw socket path = /var/run/ceph-radosgw/radosgw.<%= node['hostname'] %>
   admin socket = /var/run/ceph-radosgw/ceph-client.radosgw.<%= node['hostname'] %>.asok