Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added hooks, policy and rakefile to install selinux policy for this plug... #121

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

kubitron
Copy link

Note that the following patch is subsumed (included in) the resilience patch, issue #124

This is a pull request for the 0.4.2 release that provides selinux support. I realize that we got off on the wrong foot. This is a great plugin -- hopefully you will accept this change. (Shouldn't alter behavior seen by non-selinux users).

I've given some pretty complete documentation, as well as a rakefile for setup. The bulk of the support is in a selinux subdirectory and in the tasks/selinux.rake file. The only substantive changes are that I've moved binaries to a bin directory in the plugin root and prevented modification of gitUser and ssh key directories in the settings page (but only when selinux operational). The lock file and other tmp file functionality is still in /tmp as before (although I've put them in /tmp/redmine_git_hosting/git_user subdirectory to handle case in which there are multiple redmine distributions with multiple gitolite repositories on the same machine, which is my use case).

I've updated the README.mkd file with a new selinux section.

Note that there is one new local string added to warn users that they cannot change those settings. It appears that all of the locals are in English except for the Portugese ones? At any rate, you might check my translation in pt.yml and pt-BR.yml, since I don't really know Portugese.

I hope that you will take this. It seems to work fine and might help users who are working in a selinux environment. Note that the rakefile will actually handle multiple, complete redmine + redmine_git_hosting installations simply by typing something like:

rake RAILS_ENV=production ROOT_PATTERN="/source/.*/redmine" selinux:install

p.s. I believe that I have all of the selinux use-cases covered, but just in case I left the redmine_git_hosting binaries running in a permissive environment for now (can be fixed by commenting out line near top of selinux/redmine_git.te.

change rakefile to install binary policy (redmine_git.pp) instead of
compiling source policy (redmine_git.te) before every
installation. New rake task added to recompile policy if necessary:

    rake selinux:redmine_git_hosting:build_policy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant