]>
Commit | Line | Data |
---|---|---|
1780cc1f ER |
1 | Summary: letsencrypt/acme client implemented as a shell-script |
2 | Name: letsencrypt.sh | |
3 | Version: 0.1.0 | |
7410a329 | 4 | Release: 0.2 |
1780cc1f ER |
5 | License: MIT |
6 | Group: Applications/Networking | |
7 | Source0: https://github.com/lukas2511/letsencrypt.sh/archive/v%{version}/%{name}-%{version}.tar.gz | |
eb6aa75d ER |
8 | # Source0-md5: eadd134cc5365753c03929dd70db341d |
9 | Source1: apache.conf | |
10 | Source2: lighttpd.conf | |
1780cc1f ER |
11 | URL: https://github.com/lukas2511/letsencrypt.sh |
12 | BuildRequires: rpmbuild(macros) >= 1.713 | |
13 | Requires: curl | |
14 | Requires: grep | |
15 | Requires: mktemp | |
16 | Requires: openssl | |
17 | Requires: sed | |
eb6aa75d ER |
18 | Requires: webapps |
19 | Requires: webserver(access) | |
20 | Requires: webserver(alias) | |
1780cc1f ER |
21 | BuildArch: noarch |
22 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
23 | ||
eb6aa75d ER |
24 | %define _webapps /etc/webapps |
25 | %define _webapp %{name} | |
26 | %define _sysconfdir %{_webapps}/%{_webapp} | |
27 | %define _appdir %{_datadir}/%{_webapp} | |
28 | ||
1780cc1f ER |
29 | %description |
30 | This is a client for signing certificates with an ACME-server | |
31 | (currently only provided by letsencrypt) implemented as a relatively | |
32 | simple bash-script. | |
33 | ||
34 | Current features: | |
35 | - Signing of a list of domains | |
36 | - Signing of a CSR | |
37 | - Renewal if a certificate is about to expire or SAN (subdomains) | |
38 | changed | |
39 | - Certificate revocation | |
40 | ||
41 | %prep | |
42 | %setup -q | |
43 | ||
44 | %install | |
45 | rm -rf $RPM_BUILD_ROOT | |
eb6aa75d ER |
46 | install -d $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir}/acme-challenges} |
47 | ||
48 | install -p letsencrypt.sh $RPM_BUILD_ROOT%{_sbindir} | |
49 | ||
50 | cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf | |
51 | cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf | |
52 | cp -p $RPM_BUILD_ROOT%{_sysconfdir}/{apache,httpd}.conf | |
1780cc1f ER |
53 | |
54 | %clean | |
55 | rm -rf $RPM_BUILD_ROOT | |
56 | ||
eb6aa75d ER |
57 | %triggerin -- apache1 < 1.3.37-3, apache1-base |
58 | %webapp_register apache %{_webapp} | |
59 | ||
60 | %triggerun -- apache1 < 1.3.37-3, apache1-base | |
61 | %webapp_unregister apache %{_webapp} | |
62 | ||
63 | %triggerin -- apache < 2.2.0, apache-base | |
64 | %webapp_register httpd %{_webapp} | |
65 | ||
66 | %triggerun -- apache < 2.2.0, apache-base | |
67 | %webapp_unregister httpd %{_webapp} | |
68 | ||
69 | %triggerin -- lighttpd | |
70 | %webapp_register lighttpd %{_webapp} | |
71 | ||
72 | %triggerun -- lighttpd | |
73 | %webapp_unregister lighttpd %{_webapp} | |
74 | ||
1780cc1f ER |
75 | %files |
76 | %defattr(644,root,root,755) | |
77 | %doc README.md CHANGELOG LICENSE | |
7410a329 | 78 | %dir %attr(750,root,http) %{_sysconfdir} |
eb6aa75d ER |
79 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf |
80 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf | |
81 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf | |
82 | # challenges written here from letsencrypt.sh, need to be readable by webserver | |
83 | %dir %attr(751,root,root) %{_sysconfdir}/acme-challenges | |
7410a329 ER |
84 | |
85 | %attr(755,root,root) %{_sbindir}/letsencrypt.sh |