Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

config httpd

  • Loading branch information...
commit 01d5b187da7ac8759c2975c7490f2c1f7d0def30 1 parent 769fb90
Christof Damian authored
2  bin/build-rpm
@@ -8,6 +8,8 @@ topdir=`pwd`/rpm
8 8 tar cvfz ../rpm/SOURCES/webapp-$gitbuild.tgz .
9 9 )
10 10
  11 +cp -a config/*-httpd.conf rpm/SOURCES
  12 +
11 13 rpmbuild -ba --define "_topdir $topdir" --define "gitbuild $gitbuild" rpm/SPECS/webapp.spec
12 14
13 15
3  config/webapp-httpd.conf
... ... @@ -0,0 +1,3 @@
  1 +# Apache configuration for the webapp
  2 +
  3 +Alias /webapp/ /var/www/webapp/
11 rpm/SPECS/webapp.spec
@@ -7,10 +7,12 @@ Group: Development/Languages
7 7 License: LGPLv2
8 8 URL: http://example.com/
9 9 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
10   -Source0: %{name}-%{gitbuild}.tgz
  10 +Source0: %{name}-%{gitbuild}.tgz
  11 +Source1: %{name}-httpd.conf
11 12
12 13 Requires: httpd
13 14 Requires: php
  15 +Requires: systemd-units
14 16
15 17 BuildArch: noarch
16 18
@@ -29,17 +31,20 @@ cd %{name}-%{version}
29 31 mkdir -p $RPM_BUILD_ROOT/var/www/%{name}
30 32 tar xvfz %{SOURCE0} -C $RPM_BUILD_ROOT/var/www/%{name}
31 33
  34 +mkdir -p $RPM_BUILD_ROOT/etc/httpd/conf.d
  35 +install %{SOURCE1} $RPM_BUILD_ROOT/etc/httpd/conf.d/%{name}.conf
  36 +
32 37 %clean
33 38 %{__rm} -rf $RPM_BUILD_ROOT
34 39
35 40 %post
36   -
  41 +systemctl enable httpd.service
37 42
38 43 %postun
39 44
40 45 %files
41 46 %defattr(-,root,root,-)
42 47 /var/www/%{name}
43   -
  48 +/etc/httpd/conf.d/%{name}.conf
44 49
45 50 %changelog

0 comments on commit 01d5b18

Please sign in to comment.
Something went wrong with that request. Please try again.