/[smecontribs]/rpms/smeserver-letsencrypt/contribs10/smeserver-letsencrypt.spec
ViewVC logotype

Annotation of /rpms/smeserver-letsencrypt/contribs10/smeserver-letsencrypt.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (hide annotations) (download)
Tue Oct 6 11:15:05 2020 UTC (4 years ago) by brianr
Branch: MAIN
CVS Tags: smeserver-letsencrypt-0_5-16
Changes since 1.1: +4 -1 lines
* Fri Oct 06  2020 Brian Read <brianr@bjsystems.co.uk> 0.5-16.sme
- Move to SME10 [SME: 11022]

1 brianr 1.1 %define name smeserver-letsencrypt
2     %define version 0.5
3 brianr 1.2 %define release 16
4 brianr 1.1 Summary: Plugin to enable letsencrypt certificates
5     Name: %{name}
6     Version: %{version}
7     Release: %{release}
8     License: GNU GPL version 2
9     URL: https://letsencrypt.org/
10     Group: SMEserver/addon
11     Source: %{name}-%{version}.tar.gz
12     Patch0: smeserver-letsencrypt-remove-debug-lines.patch
13     Patch1: smeserver-letsencrypt-remove-licence.patch
14     Patch2: smeserver-letsencrypt-log-to-file.patch
15     Patch3: smeserver-letsencrypt-API1-URL-change.patch
16     Patch4: smeserver-letsencrypt-fix-logging.patch
17     Patch5: smeserver-letsencrypt-fix-logging-reverse.patch
18     Patch6: smeserver-letsencrypt-fix-acme-v01-url.patch
19     Patch7: smeserver-letsencrypt-fix-hook-entry.patch
20     Patch8: smeserver-letsencrypt-change-cron-entry.patch
21    
22     BuildRoot: /var/tmp/%{name}-%{version}
23     BuildArchitectures: noarch
24     BuildRequires: e-smith-devtools
25     Requires: e-smith-release >= 9.0
26     Requires: dehydrated >= 0.6.5
27     AutoReqProv: no
28    
29     %description
30     Lets Encrypt is a free, automated, and open certificate authority
31     https://letsencrypt.org/
32    
33     %changelog
34 brianr 1.2 * Fri Oct 06 2020 Brian Read <brianr@bjsystems.co.uk> 0.5-16.sme
35     - Move to SME10 [SME: 11022]
36    
37 brianr 1.1 * Thu Mar 12 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-15.sme
38     - take 3: remove dangling cron.daily dir missed in 0.5-12 [SME: 10862]
39    
40     * Wed Mar 11 2020 Jean-Philipe Pialasse <tests@pialasse.com> 0.5-14.sme
41     - take 2: remove dangling cron.daily dir missed in 0.5-12 [SME: 10862]
42    
43     * Mon Mar 09 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-13.sme
44     - remove dangling cron.daily dir missed in 0.5-12 [SME: 10862]
45    
46     * Sat Jan 18 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-12.sme
47     - forgot to remove template-begin and cron.daily dir [SME: 10862]
48    
49     * Fri Jan 17 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-11.sme
50     - force required version to 0.6.5 for EPEL version
51     - Add new cron template for EPEL version of dehydrated [SME: 10862]
52    
53     * Fri Jan 17 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-10.sme
54     - Fix incorrect HOOK entry in config [SME: 10861]
55    
56     * Fri Jan 04 2019 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-9.sme
57     - Fix incorrect CA line in config [SME: 10688]
58    
59     * Mon Dec 31 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-8.sme
60     - Reverse my previous error [SME: 10681]
61    
62     * Mon Dec 31 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-7.sme
63     - fix spec file numbering
64    
65     * Mon Dec 31 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-6.sme
66     - Fix typo error in cron.daily [SME: 10681]
67    
68     * Sun Dec 23 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-5.sme
69     - Fix changed V1 staging URL [SME: 10595]
70     - Thanks Terry Fage
71    
72     * Wed Dec 12 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-4.sme
73     - log to file rather than /dev/null [SME: 10412]
74    
75     * Tue Oct 13 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-3.sme
76     - remove Licence key from config template [SME:10636]
77    
78     * Tue Jun 19 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-2.sme
79     - remove debug print lines
80    
81     * Tue Jun 12 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-1.sme
82     - Update to v2 API [SME:10595]
83     - Add key letsencrypt hostOverride to ignore 'Self' host check
84     - This requires v0.6 of dehydrated
85    
86     * Wed Jun 06 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.4-6.sme
87     - Fix missing event actions [SME: 10315]
88    
89     * Thu May 31 2018 John Crisp <jcrisp@safeandsoundit.co.uk> 0.4-5.sme
90     - Fix typo in Accept Terms
91     - add domain-delete to createlinks [SME: 10315]
92     - Update requires release to SME v9
93     - Update requires dehydrated to v0.5
94    
95     * Fri Aug 18 2017 Jean-Philipe Pialasse <tests@pialasse.com> 0.4-4.sme
96     - change ACCEPT_TERMS template position to appear after shebang in config file [SME: 10410]
97    
98     * Wed Jul 12 2017 Jean-Philipe Pialasse <tests@pialasse.com> 0.4-3.sme
99     - remove workaround for curl dns resolution [SME: 10300]
100     - should be corrected at dnscache level (djbdns-1.05-10)
101    
102     * Fri Apr 28 2017 Jean-Philipe Pialasse <tests@pialasse.com> 0.4-2.sme
103     - help accept licence [SME: 10253]
104     - workaround for curl issues
105     - spec tidying
106    
107     * Sat Feb 04 2017 John Crisp <jcrisp@safeandsoundit.co.uk> 0.4-1
108     - first attempt at using stock letsencrypt script
109    
110     * Wed Sep 14 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.3-1
111     - Due to madness at letsencrypt the script had to be renamed for copyright reasons
112     - move /etc/letsencrypt.sh to /etc/dehydrated
113     - change references to letsencrypt.sh to dehydrated
114     - Fix typos in readme
115    
116     * Wed Aug 3 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-10
117     - Some tweaks from JPP for the domains.txt file
118    
119     * Wed Aug 3 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-9
120     - Fix version differences with between v8 and v9
121    
122     * Thu Jul 14 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-8
123     - Remove spaces in POSTIN [[]]
124    
125     * Mon Jun 27 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-7
126     - fix another typo in bash scripts
127     - fix typo in Docs
128    
129     * Fri Jun 10 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-6
130     - Fix typo in domains.txt
131     - Set configure default type none
132    
133     * Tue May 31 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-5
134     - update incorrect bash scripts in spec file
135    
136     * Tue May 31 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-4
137     - update letsencrypt requires
138    
139     * Mon May 30 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-3
140     - add support for letsencrypt.sh v0.2
141     - config.sh renamed to config
142     - fix trailing / on urls in 40ACME
143    
144     * Mon Apr 04 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-2
145     - letsencrypt.sh now calls deploy-cert with an argument for the chain file
146     - thanks to Dan Brown
147    
148     * Tue Mar 29 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.2-1
149     - Remove letsencrypt.sh script and put in separate RPM
150    
151     * Tue Mar 29 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-21
152     - modify hook script templates as per Dan Browd contribution
153    
154     * Thu Mar 17 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-20
155     - updated letsencrypt.sh
156     - https://github.com/lukas2511/letsencrypt.sh/commit/429c5250ede7ff4af3b6f37b39925cfa5afee278
157     - Add "" to wellknown path in config.sh
158    
159     * Fri Feb 05 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-19
160     - updated letsencrypt.sh
161     - https://github.com/lukas2511/letsencrypt.sh/commit/21c18dd3b8c2572b894d9ec2e5c3fc2589f56f32
162    
163     * Tue Jan 26 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-18
164     - updated letsencrypt.sh
165     - https://github.com/lukas2511/letsencrypt.sh/commit/79ff846e267c30d85988f79f58b81bc7bd91790c
166    
167     * Sat Jan 23 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-17
168     - Fix typos in hook-script
169     - Add latest letsencrypt.sh script
170    
171     * Wed Jan 20 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-16
172     - Minor fixes including typo in cron.daily
173    
174     * Tue Jan 19 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-15
175     - Missed a "
176     - remove ' from Let's encrypt and add URL
177    
178     * Tue Jan 19 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-14
179     - Updated readme and install notes
180     - Allow either domains or hosts
181    
182     * Mon Jan 18 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-13
183     - Add missing templates.metadata file
184     - modify spec file wording
185    
186     * Mon Jan 18 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-12
187     - Set hookscript to always run unless letsencrypt is disabled
188     - Add cron.daily script to console-save action and set perms
189    
190     * Sun Jan 17 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-11
191     - Fix hook-script.sh perms using templates.metadata
192    
193     * Sun Jan 17 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-10
194     - Add latest revision of letsencrypt.sh
195     - add hookscript.sh templates and various fixes
196    
197     * Sat Jan 16 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-9
198     - Add latest revision of letsencrypt.sh
199    
200     * Fri Jan 15 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-8
201     - set +x on hook-script and correct file name in config
202    
203     * Fri Jan 15 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-7
204     - Add missing curly brace
205     - Move Status check line up so we can generate empty file if disabled
206    
207     * Fri Jan 15 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-6
208     - Add hookScript key
209    
210     * Fri Jan 15 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-5
211     - Modify spec file to add paths and set permisssions
212    
213     * Thu Jan 14 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-4
214     - Modify file paths and cron script
215    
216     * Thu Jan 14 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-3
217     - updated bash script in spec file
218     - updated file locations in README.MD
219    
220     * Wed Jan 13 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-2
221     - Moved config.sh file location
222     - added cron.daily template - only works if letsencrypt is enabled
223     - added check to create /etc/letsencrypt.sh directory if it does not exist
224     - added latest letsencrypt.sh script
225    
226     * Thu Jan 07 2016 John Crisp <jcrisp@safeandsoundit.co.uk> 0.1-1
227     - initial release
228    
229     %prep
230     %setup
231     %patch0 -p1
232     %patch1 -p1
233     %patch2 -p1
234     %patch3 -p1
235     %patch4 -p1
236     %patch5 -p1
237     %patch6 -p1
238     %patch7 -p1
239     %patch8 -p1
240    
241     # remove old template
242     rm -rf root/etc/e-smith/templates/etc/cron.daily
243    
244     %build
245     perl createlinks
246    
247     %install
248     rm -rf $RPM_BUILD_ROOT
249     (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
250     rm -f %{name}-%{version}-filelist
251     /sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist
252     echo "%doc COPYING" >> %{name}-%{version}-filelist
253    
254    
255     %clean
256     cd ..
257     rm -rf %{name}-%{version}
258    
259     %files -f %{name}-%{version}-filelist
260     %defattr(-,root,root)
261    
262     %pre
263    
264     %preun
265    
266     %post
267     # if previously installed letsencrypt.sh, but first migration to dehydrated
268     if [[ -e /etc/letsencrypt.sh ]] && [[ ! -e /etc/dehydrated ]];
269     then
270     # assume in production
271     # CA="https://acme-v01.api.letsencrypt.org/directory" ;
272     # CAHASH="$(echo "${CA}" | urlbase64)"
273     # mkdir /etc/dehydrated;
274     # mkdir -p /etc/dehydrated/accounts
275     # cp -a /etc/letsencrypt.sh/private_key.json /etc/dehydrated/accounts/${CAHASH}/registration_info.json
276     # cp -a /etc/letsencrypt.sh/private_key.pem /etc/dehydrated/accounts/${CAHASH}/account_key.pem
277     # cp -a /etc/letsencrypt.sh/certs /etc/dehydrated/
278     mv -f /etc/letsencrypt.sh /etc/letsencrypt.sh.old;
279     fi
280    
281     # if letsencrypt still there but already migrated to dehydrated
282     if [[ -e /etc/letsencrypt.sh ]] && [[ -e /etc/dehydrated/certs ]];
283     then
284     mv -f /etc/letsencrypt.sh /etc/letsencrypt.sh.old;
285     fi
286    
287     # if first installation of dehydrated
288     if [[ ! -e /etc/dehydrated ]];
289     then mkdir /etc/dehydrated;
290     fi
291    
292     if [[ -f /usr/local/bin/config.sh ]];
293     then mv -f /usr/local/bin/config.sh /usr/local/bin/config.sh.orig;
294     fi
295    
296     if [[ -f /usr/local/bin/config ]];
297     then mv -f /usr/local/bin/config /usr/local/bin/config.old;
298     fi
299    
300     if [[ -f /usr/local/bin/domain.txt ]];
301     then mv -f /usr/local/bin/domains.txt /usr/local/bin/domains.txt.orig;
302     fi
303    
304     if [[ -d /etc/cron.daily/letsencrypt ]];
305     then rm -rf /etc/cron.daily/letsencrypt;
306     fi
307    
308     if [[ -d /etc/e-smith/templates/etc/cron.daily/letsencrypt ]];
309     then rm -rf /root/etc/e-smith/templates/etc/cron.daily/letsencrypt
310     fi
311    
312     if [[ ! -e /home/e-smith/files/ibays/Primary/html/.well-known/acme-challenge ]];
313     then mkdir -p /home/e-smith/files/ibays/Primary/html/.well-known/acme-challenge;
314     fi
315    
316     chmod -R 0775 /home/e-smith/files/ibays/Primary/html/.well-known
317     chown -R apache:shared /home/e-smith/files/ibays/Primary/html/.well-known
318    
319     # remove old template file
320     if [[ -e /etc/cron.daily/letsencrypt ]];
321     then rm -rf /etc/cron.daily/letsencrypt
322     fi
323     %postun

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed