From 49a79e419b44c733ac99cd374cf56c4214b1a40a Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Mar 30 2015 12:52:06 +0000 Subject: Rename progit files to pagure --- diff --git a/files/pagure.cfg.sample b/files/pagure.cfg.sample new file mode 100644 index 0000000..5f8c0ea --- /dev/null +++ b/files/pagure.cfg.sample @@ -0,0 +1,76 @@ + +### Secret key for the Flask application +SECRET_KEY='' + +### url to the database server: +#DB_URL=mysql://user:pass@host/db_name +#DB_URL=postgres://user:pass@host/db_name +DB_URL = 'sqlite:////var/tmp/pagure_dev.sqlite' + +### The FAS group in which the admin of pagure are +ADMIN_GROUP = ['sysadmin-main', 'sysadmin-cvs'] + +### The email address to which the flask.log will send the errors (tracebacks) +EMAIL_ERROR = 'pingou@pingoured.fr' + +### The URL at which the project is available. +APP_URL = 'https://fedorahosted.org/pagure/' + +### The URL to use to clone git repositories. +GIT_URL = 'git@pagure.fedorahosted.org' + +### Folder containing to the git repos +GIT_FOLDER = os.path.join( + os.path.abspath(os.path.dirname(__file__)), + '..', + 'repos' +) + +### Folder containing the forks repos +FORK_FOLDER = os.path.join( + os.path.abspath(os.path.dirname(__file__)), + '..', + 'forks' +) + +### Folder containing the docs repos +DOCS_FOLDER = os.path.join( + os.path.abspath(os.path.dirname(__file__)), + '..', + 'docs' +) + +### Configuration file for gitolite +GITOLITE_CONFIG = os.path.join( + os.path.abspath(os.path.dirname(__file__)), + '..', + 'gitolite.conf' +) + + +### Home folder of the gitolite user +### Folder where to run gl-compile-conf from +GITOLITE_HOME = None + +### Folder containing all the public ssh keys for gitolite +GITOLITE_KEYDIR = None + +### Path to the gitolite.rc file +GL_RC = None + +### Path to the /bin directory where the gitolite tools can be found +GL_BINDIR = None + + + +# Optional configuration + +### Default SMTP server to use for sending emails +#SMTP_SERVER = 'localhost' + +### Email used to sent emails +#FROM_EMAIL = 'pagure@fedoraproject.org' + +### the number of items (packages, packagers..) to display on the search +### pages +ITEMS_PER_PAGE = 50 diff --git a/files/pagure.conf b/files/pagure.conf new file mode 100644 index 0000000..f33e51f --- /dev/null +++ b/files/pagure.conf @@ -0,0 +1,23 @@ +# Apache configuration file for pagure + +#WSGIDaemonProcess pagure user=apache maximum-requests=1000 display-name=pagure processes=2 threads=1 +#WSGISocketPrefix run/wsgi +#WSGIRestrictStdout On +#WSGIRestrictSignal Off +#WSGIPythonOptimize 1 + +#WSGIScriptAlias /pagure /usr/share/pagure/pagure.wsgi + +# +# WSGIProcessGroup pagure +# +# # Apache 2.4 +# Require all granted +# +# +# # Apache 2.2 +# Order deny,allow +# Allow from all +# +# + diff --git a/files/pagure.spec b/files/pagure.spec new file mode 100644 index 0000000..01e7f06 --- /dev/null +++ b/files/pagure.spec @@ -0,0 +1,108 @@ +%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from +%distutils.sysconfig import get_python_lib; print (get_python_lib())")} + +Name: pagure +Version: 0.0 +Release: 1.20141008%{?dist} +Summary: A git-centered forge + +License: GPLv2+ +URL: http://fedorahosted.org/pagure/ +Source0: https://fedorahosted.org/releases/p/r/pagure/%{name}-%{version}.tar.gz + +BuildArch: noarch + +BuildRequires: python2-devel +BuildRequires: python-setuptools +BuildRequires: python-nose + +BuildRequires: python-alembic +BuildRequires: python-arrow +BuildRequires: python-docutils +BuildRequires: python-flask +BuildRequires: python-flask-wtf +BuildRequires: python-markdown +BuildRequires: python-psutil +BuildRequires: python-pygit2 >= 0.20.1 +BuildRequires: python-pygments +BuildRequires: python-fedora +BuildRequires: python-openid +BuildRequires: python-openid-cla +BuildRequires: python-openid-teams +BuildRequires: python-straight-plugin +BuildRequires: python-wtforms + +# EPEL6 +%if ( 0%{?rhel} && 0%{?rhel} == 6 ) +BuildRequires: python-sqlalchemy0.8 +Requires: python-sqlalchemy0.8 +%else +BuildRequires: python-sqlalchemy > 0.8 +Requires: python-sqlalchemy > 0.8 +%endif + +Requires: python-alembic +Requires: python-arrow +Requires: python-docutils +Requires: python-flask +Requires: python-flask-wtf +Requires: python-markdown +Requires: python-psutil +Requires: python-pygit2 >= 0.20.1 +Requires: python-pygments +Requires: python-fedora +Requires: python-openid +Requires: python-openid-cla +Requires: python-openid-teams +Requires: python-straight-plugin +Requires: python-wtforms +Requires: mod_wsgi + +%description +Pagure is a light-weight git-centered forge based on pygit2. + +Currently, Pagure offers a web-interface for git repositories, a ticket +system and possibilities to create new projects, fork existing ones and +create/merge pull-requests across or within projects. + +%prep +%setup -q + + +%build +%{__python} setup.py build + + +%install +rm -rf $RPM_BUILD_ROOT +%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT + +# Install apache configuration file +mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d/ +install -m 644 files/pagure.conf $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d/pagure.conf + +# Install configuration file +mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/pagure +install -m 644 files/pagure.cfg.sample $RPM_BUILD_ROOT/%{_sysconfdir}/pagure/pagure.cfg + +# Install WSGI file +mkdir -p $RPM_BUILD_ROOT/%{_datadir}/pagure +install -m 644 files/pagure.wsgi $RPM_BUILD_ROOT/%{_datadir}/pagure/pagure.wsgi + +# Install the createdb script +install -m 644 createdb.py $RPM_BUILD_ROOT/%{_datadir}/pagure/pagure_createdb.py + + +%files +%doc README.rst LICENSE +%config(noreplace) %{_sysconfdir}/httpd/conf.d/pagure.conf +%config(noreplace) %{_sysconfdir}/pagure/pagure.cfg +%dir %{_sysconfdir}/pagure/ +%{_datadir}/pagure/ +%{python_sitelib}/pagure/ +%{python_sitelib}/pagure*.egg-info + + +%changelog +* Wed Oct 08 2014 Pierre-Yves Chibon - 0.0-1.20141008 +- Initial packaging work for Fedora diff --git a/files/pagure.wsgi b/files/pagure.wsgi new file mode 100644 index 0000000..91bba6e --- /dev/null +++ b/files/pagure.wsgi @@ -0,0 +1,22 @@ +#-*- coding: utf-8 -*- + +# The three lines below are required to run on EL6 as EL6 has +# two possible version of python-sqlalchemy and python-jinja2 +# These lines make sure the application uses the correct version. +#import __main__ +#__main__.__requires__ = ['SQLAlchemy >= 0.8', 'jinja2 >= 2.4'] +#import pkg_resources + +#import os +## Set the environment variable pointing to the configuration file +#os.environ['PAGURE_CONFIG'] = '/etc/pagure/pagure.cfg' + +## The following is only needed if you did not install pagure +## as a python module (for example if you run it from a git clone). +#import sys +#sys.path.insert(0, '/path/to/pagure/') + + +## The most import line to make the wsgi working +#from pagure import APP as application +#application.debug = True diff --git a/files/progit.cfg.sample b/files/progit.cfg.sample deleted file mode 100644 index 5f8c0ea..0000000 --- a/files/progit.cfg.sample +++ /dev/null @@ -1,76 +0,0 @@ - -### Secret key for the Flask application -SECRET_KEY='' - -### url to the database server: -#DB_URL=mysql://user:pass@host/db_name -#DB_URL=postgres://user:pass@host/db_name -DB_URL = 'sqlite:////var/tmp/pagure_dev.sqlite' - -### The FAS group in which the admin of pagure are -ADMIN_GROUP = ['sysadmin-main', 'sysadmin-cvs'] - -### The email address to which the flask.log will send the errors (tracebacks) -EMAIL_ERROR = 'pingou@pingoured.fr' - -### The URL at which the project is available. -APP_URL = 'https://fedorahosted.org/pagure/' - -### The URL to use to clone git repositories. -GIT_URL = 'git@pagure.fedorahosted.org' - -### Folder containing to the git repos -GIT_FOLDER = os.path.join( - os.path.abspath(os.path.dirname(__file__)), - '..', - 'repos' -) - -### Folder containing the forks repos -FORK_FOLDER = os.path.join( - os.path.abspath(os.path.dirname(__file__)), - '..', - 'forks' -) - -### Folder containing the docs repos -DOCS_FOLDER = os.path.join( - os.path.abspath(os.path.dirname(__file__)), - '..', - 'docs' -) - -### Configuration file for gitolite -GITOLITE_CONFIG = os.path.join( - os.path.abspath(os.path.dirname(__file__)), - '..', - 'gitolite.conf' -) - - -### Home folder of the gitolite user -### Folder where to run gl-compile-conf from -GITOLITE_HOME = None - -### Folder containing all the public ssh keys for gitolite -GITOLITE_KEYDIR = None - -### Path to the gitolite.rc file -GL_RC = None - -### Path to the /bin directory where the gitolite tools can be found -GL_BINDIR = None - - - -# Optional configuration - -### Default SMTP server to use for sending emails -#SMTP_SERVER = 'localhost' - -### Email used to sent emails -#FROM_EMAIL = 'pagure@fedoraproject.org' - -### the number of items (packages, packagers..) to display on the search -### pages -ITEMS_PER_PAGE = 50 diff --git a/files/progit.conf b/files/progit.conf deleted file mode 100644 index f33e51f..0000000 --- a/files/progit.conf +++ /dev/null @@ -1,23 +0,0 @@ -# Apache configuration file for pagure - -#WSGIDaemonProcess pagure user=apache maximum-requests=1000 display-name=pagure processes=2 threads=1 -#WSGISocketPrefix run/wsgi -#WSGIRestrictStdout On -#WSGIRestrictSignal Off -#WSGIPythonOptimize 1 - -#WSGIScriptAlias /pagure /usr/share/pagure/pagure.wsgi - -# -# WSGIProcessGroup pagure -# -# # Apache 2.4 -# Require all granted -# -# -# # Apache 2.2 -# Order deny,allow -# Allow from all -# -# - diff --git a/files/progit.spec b/files/progit.spec deleted file mode 100644 index 01e7f06..0000000 --- a/files/progit.spec +++ /dev/null @@ -1,108 +0,0 @@ -%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from -%distutils.sysconfig import get_python_lib; print (get_python_lib())")} - -Name: pagure -Version: 0.0 -Release: 1.20141008%{?dist} -Summary: A git-centered forge - -License: GPLv2+ -URL: http://fedorahosted.org/pagure/ -Source0: https://fedorahosted.org/releases/p/r/pagure/%{name}-%{version}.tar.gz - -BuildArch: noarch - -BuildRequires: python2-devel -BuildRequires: python-setuptools -BuildRequires: python-nose - -BuildRequires: python-alembic -BuildRequires: python-arrow -BuildRequires: python-docutils -BuildRequires: python-flask -BuildRequires: python-flask-wtf -BuildRequires: python-markdown -BuildRequires: python-psutil -BuildRequires: python-pygit2 >= 0.20.1 -BuildRequires: python-pygments -BuildRequires: python-fedora -BuildRequires: python-openid -BuildRequires: python-openid-cla -BuildRequires: python-openid-teams -BuildRequires: python-straight-plugin -BuildRequires: python-wtforms - -# EPEL6 -%if ( 0%{?rhel} && 0%{?rhel} == 6 ) -BuildRequires: python-sqlalchemy0.8 -Requires: python-sqlalchemy0.8 -%else -BuildRequires: python-sqlalchemy > 0.8 -Requires: python-sqlalchemy > 0.8 -%endif - -Requires: python-alembic -Requires: python-arrow -Requires: python-docutils -Requires: python-flask -Requires: python-flask-wtf -Requires: python-markdown -Requires: python-psutil -Requires: python-pygit2 >= 0.20.1 -Requires: python-pygments -Requires: python-fedora -Requires: python-openid -Requires: python-openid-cla -Requires: python-openid-teams -Requires: python-straight-plugin -Requires: python-wtforms -Requires: mod_wsgi - -%description -Pagure is a light-weight git-centered forge based on pygit2. - -Currently, Pagure offers a web-interface for git repositories, a ticket -system and possibilities to create new projects, fork existing ones and -create/merge pull-requests across or within projects. - -%prep -%setup -q - - -%build -%{__python} setup.py build - - -%install -rm -rf $RPM_BUILD_ROOT -%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT - -# Install apache configuration file -mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d/ -install -m 644 files/pagure.conf $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d/pagure.conf - -# Install configuration file -mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/pagure -install -m 644 files/pagure.cfg.sample $RPM_BUILD_ROOT/%{_sysconfdir}/pagure/pagure.cfg - -# Install WSGI file -mkdir -p $RPM_BUILD_ROOT/%{_datadir}/pagure -install -m 644 files/pagure.wsgi $RPM_BUILD_ROOT/%{_datadir}/pagure/pagure.wsgi - -# Install the createdb script -install -m 644 createdb.py $RPM_BUILD_ROOT/%{_datadir}/pagure/pagure_createdb.py - - -%files -%doc README.rst LICENSE -%config(noreplace) %{_sysconfdir}/httpd/conf.d/pagure.conf -%config(noreplace) %{_sysconfdir}/pagure/pagure.cfg -%dir %{_sysconfdir}/pagure/ -%{_datadir}/pagure/ -%{python_sitelib}/pagure/ -%{python_sitelib}/pagure*.egg-info - - -%changelog -* Wed Oct 08 2014 Pierre-Yves Chibon - 0.0-1.20141008 -- Initial packaging work for Fedora diff --git a/files/progit.wsgi b/files/progit.wsgi deleted file mode 100644 index 91bba6e..0000000 --- a/files/progit.wsgi +++ /dev/null @@ -1,22 +0,0 @@ -#-*- coding: utf-8 -*- - -# The three lines below are required to run on EL6 as EL6 has -# two possible version of python-sqlalchemy and python-jinja2 -# These lines make sure the application uses the correct version. -#import __main__ -#__main__.__requires__ = ['SQLAlchemy >= 0.8', 'jinja2 >= 2.4'] -#import pkg_resources - -#import os -## Set the environment variable pointing to the configuration file -#os.environ['PAGURE_CONFIG'] = '/etc/pagure/pagure.cfg' - -## The following is only needed if you did not install pagure -## as a python module (for example if you run it from a git clone). -#import sys -#sys.path.insert(0, '/path/to/pagure/') - - -## The most import line to make the wsgi working -#from pagure import APP as application -#application.debug = True