]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: add SERVER_PORT to mongoose environment
authorYehuda Sadeh <yehuda@inktank.com>
Wed, 23 Oct 2013 21:51:02 +0000 (14:51 -0700)
committerYehuda Sadeh <yehuda@inktank.com>
Tue, 5 Nov 2013 04:28:13 +0000 (20:28 -0800)
Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
src/rgw/rgw_mongoose.cc

index 20b6b8b2a6d4d47eda0dde5788631a6e2bf9cbab..65ce020f93f90ec4f9611ee48a783c8ddec442b1 100644 (file)
@@ -102,6 +102,10 @@ void RGWMongoose::init_env(CephContext *cct)
   env.set("QUERY_STRING", info->query_string);
   env.set("REMOTE_USER", info->remote_user);
   env.set("SCRIPT_URI", info->uri); /* FIXME */
+
+  char port[16];
+  snprintf(port, sizeof(port), "%d", cct->_conf->rgw_standalone_server_port);
+  env.set("SERVER_PORT", port);
 }
 
 int RGWMongoose::send_status(const char *status, const char *status_name)