https://bugzilla.redhat.com/show_bug.cgi?id=1152267
Bug ID: 1152267 Summary: Support multiple instances of couchdb Product: Fedora Version: rawhide Component: couchdb Assignee: lemenkov@gmail.com Reporter: thomas@apestaart.org QA Contact: extras-qa@fedoraproject.org CC: erlang@lists.fedoraproject.org, lemenkov@gmail.com, wtogami@gmail.com
Created attachment 946532 --> https://bugzilla.redhat.com/attachment.cgi?id=946532&action=edit older style init file
Description of problem:
couchdb is often used as a supporting database for different software which recommends using a different separate instance for various reasons. Examples I know of are:
- hood.ie which uses different parameters for the config of couchdb - feat, a clustering agent which uses python view servers which need to be custom-configured - desktopcouch, which uses per-user couch instances - puppet can use it as an ENC
I'm adding an init file (for older Fedora and pre-7 RHEL), and a systemd multiple instances file.
In my puppet modules for couchdb, I also add some selinux rules for these differently named instances, which potentially might make sense to just put in selinux-policy-targeted instead.
https://bugzilla.redhat.com/show_bug.cgi?id=1152267
--- Comment #1 from Thomas Vander Stichele thomas@apestaart.org --- Created attachment 946533 --> https://bugzilla.redhat.com/attachment.cgi?id=946533&action=edit a systemd ctl file for multiple instances
https://bugzilla.redhat.com/show_bug.cgi?id=1152267
--- Comment #2 from Thomas Vander Stichele thomas@apestaart.org --- For reference, the puppet rules I have to set couchdb types:
selinux::filecontext { "/var/log/${name}": seltype => 'couchdb_log_t' }
selinux::filecontext { "/etc/${name}(/.*)?": seltype => 'couchdb_conf_t' }
selinux::filecontext { "/var/lib/${name}(/.*)?": seltype => 'couchdb_var_lib_t' }
In selinux-policy, the file couchdb.fc could be adapted:
/etc/couchdb(/.*)? gen_context(system_u:object_r:couchdb_conf_t,s0)
/etc/rc.d/init.d/couchdb -- gen_context(system_u:object_r:couchdb_initrc_exec_t,s0)
/usr/bin/couchdb -- gen_context(system_u:object_r:couchdb_exec_t,s0)
/var/lib/couchdb(/.*)? gen_context(system_u:object_r:couchdb_var_lib_t,s0)
/var/log/couchdb(/.*)? gen_context(system_u:object_r:couchdb_log_t,s0)
/var/run/couchdb(/.*)? gen_context(system_u:object_r:couchdb_var_run_t,s0)
line 1/4/5 should be changed to accept couchdb-.* instead of just couchdb
https://bugzilla.redhat.com/show_bug.cgi?id=1152267
Peter Lemenkov lemenkov@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |FutureFeature Version|22 |rawhide
Red Hat Bugzilla bugzilla@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Doc Type|Bug Fix |Enhancement
erlang@lists.fedoraproject.org