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

Contents of /rpms/smeserver-letsencrypt/contribs9/smeserver-letsencrypt.spec

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


Revision 1.17 - (show annotations) (download)
Fri Jan 17 15:20:48 2020 UTC (4 years, 4 months ago) by jcrisp
Branch: MAIN
CVS Tags: smeserver-letsencrypt-0_5-11
Changes since 1.16: +13 -2 lines
* Fri Jan 17 2020 John Crisp <jcrisp@safeandsoundit.co.uk> 0.5-11.sme
- force required versioni to 0.6.5 for EPEL version
- Add new cron template for EPEL version of dehydrated [SME: 10862]

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

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