From: Elan Ruusamäe Date: Tue, 26 May 2015 16:05:30 +0000 (+0300) Subject: move apache config as separate file X-Git-Tag: auto/th/apache-php-fcgi-5.6-1~2 X-Git-Url: https://git.pld-linux.org/gitweb.cgi?p=packages%2Fapache-php-fcgi.git;a=commitdiff_plain;h=52ab9b62079ef89f45fb05bb0f4419e005e688e2 move apache config as separate file --- diff --git a/apache-php-fcgi.spec b/apache-php-fcgi.spec index 51077e1..03abd20 100644 --- a/apache-php-fcgi.spec +++ b/apache-php-fcgi.spec @@ -5,6 +5,7 @@ Version: 5.6 Release: 1 License: GPL Group: Applications/WWW +Source0: apache.conf BuildRequires: apache-devel >= 1.3.39 BuildRequires: rpmbuild(macros) >= 1.268 Requires: apache-mod_fastcgi @@ -15,7 +16,6 @@ BuildArch: noarch BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null) -%define fcgiapp /usr/bin/php56.fcgi %description This virtual package provides support for the PHP via FastCGI @@ -24,30 +24,10 @@ protocol. %prep %setup -qcT -cat <<'EOF' > apache.conf -# setup via fastcgi to run php5 - - # the server name is bogus actually, to satisfy mod_fastcgi - FastCgiExternalServer %{fcgiapp} -socket /var/run/php/fcgi.sock -idle-timeout 120 - ScriptAlias /php-fcgi %{fcgiapp} - - SetHandler fastcgi-script - Allow from all - - - Action application/x-httpd-php-fcgi /php-fcgi - - -# To register handler for .php in your config context: -# -# AddType application/x-httpd-php-fcgi .php -# -EOF - %install rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT%{_sysconfdir}/conf.d -cp -a apache.conf $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/90_php-fcgi.conf +cp -p %{SOURCE0} $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/90_php-fcgi.conf %clean rm -rf $RPM_BUILD_ROOT diff --git a/apache.conf b/apache.conf new file mode 100644 index 0000000..e25d256 --- /dev/null +++ b/apache.conf @@ -0,0 +1,17 @@ +# setup via fastcgi to run php5 + + # the server name is bogus actually, to satisfy mod_fastcgi + FastCgiExternalServer /usr/bin/php56.fcgi -socket /var/run/php/fcgi.sock -idle-timeout 120 + ScriptAlias /php-fcgi /usr/bin/php56.fcgi + + SetHandler fastcgi-script + Allow from all + + + Action application/x-httpd-php-fcgi /php-fcgi + + +# To register handler for .php in your config context: +# +# AddType application/x-httpd-php-fcgi .php +#