<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.ho.stna.me/index.php?action=history&amp;feed=atom&amp;title=Hosting</id>
	<title>Hosting - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.ho.stna.me/index.php?action=history&amp;feed=atom&amp;title=Hosting"/>
	<link rel="alternate" type="text/html" href="https://wiki.ho.stna.me/index.php?title=Hosting&amp;action=history"/>
	<updated>2026-07-01T07:43:04Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.36.2</generator>
	<entry>
		<id>https://wiki.ho.stna.me/index.php?title=Hosting&amp;diff=109&amp;oldid=prev</id>
		<title>172.17.0.1 at 19:48, 17 April 2022</title>
		<link rel="alternate" type="text/html" href="https://wiki.ho.stna.me/index.php?title=Hosting&amp;diff=109&amp;oldid=prev"/>
		<updated>2022-04-17T19:48:12Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 19:48, 17 April 2022&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l54&quot;&gt;Line 54:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 54:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [Service]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [Service]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  Type=oneshot&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  Type=oneshot&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  ExecStart=/usr/bin/certbot -q renew&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;#&lt;/ins&gt;ExecStart=/usr/bin/certbot -q renew&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  PrivateTmp=true&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;ExecStart=/usr/bin/certbot -q renew --post-hook &amp;quot;service postfix reload; service dovecot r &lt;/ins&gt;PrivateTmp=true&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>172.17.0.1</name></author>
	</entry>
	<entry>
		<id>https://wiki.ho.stna.me/index.php?title=Hosting&amp;diff=108&amp;oldid=prev</id>
		<title>172.17.0.1: Created page with &quot;==certbot== https://community.letsencrypt.org/t/cerbot-cron-job/23895/5  ===cronjob=== You should have it here /etc/cron.d/certbot  The content of this file:   # Eventually, t...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.ho.stna.me/index.php?title=Hosting&amp;diff=108&amp;oldid=prev"/>
		<updated>2022-04-17T19:47:29Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;==certbot== https://community.letsencrypt.org/t/cerbot-cron-job/23895/5  ===cronjob=== You should have it here /etc/cron.d/certbot  The content of this file:   # Eventually, t...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==certbot==&lt;br /&gt;
https://community.letsencrypt.org/t/cerbot-cron-job/23895/5&lt;br /&gt;
&lt;br /&gt;
===cronjob===&lt;br /&gt;
You should have it here /etc/cron.d/certbot&lt;br /&gt;
&lt;br /&gt;
The content of this file:&lt;br /&gt;
&lt;br /&gt;
 # Eventually, this will be an opportunity to validate certificates&lt;br /&gt;
 # haven't been revoked, etc.  Renewal will only occur if expiration&lt;br /&gt;
 # is within 30 days.&lt;br /&gt;
 SHELL=/bin/sh&lt;br /&gt;
 PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin&lt;br /&gt;
 &lt;br /&gt;
 0 */12 * * * root test -x /usr/bin/certbot -a \! -d /run/systemd/system &amp;amp;&amp;amp; perl -e 'sleep int(rand(3600))' &amp;amp;&amp;amp; certbot -q renew&lt;br /&gt;
&lt;br /&gt;
This cron job will be executed every 12 hours. If the file /usr/bin/certbot has the exe perms… AND there is no dir /run/systemd/system it will execute the renew command but If it detects this dir /run/systemd/system/ exists is because you are running systemd so it won’t execute the renew command. It won’t run the renew command because there is a systemd timer (a kind of cron job used by systemd) that was configured when you installed the certbot package.&lt;br /&gt;
&lt;br /&gt;
===systemd timer===&lt;br /&gt;
&lt;br /&gt;
You can check your systemd timers using command systemctl list-timers or systemctl list-timers --all if you also want to show inactive timers. Something like this:&lt;br /&gt;
&lt;br /&gt;
 # systemctl list-timers --all&lt;br /&gt;
 NEXT                         LEFT     LAST                         PASSED    UNIT                         ACTIVATES&lt;br /&gt;
 Sun 2016-12-11 00:00:00 CET  9h left  Sat 2016-12-10 13:48:13 CET  38min ago certbot.timer                &lt;br /&gt;
 certbot.service&lt;br /&gt;
 Sun 2016-12-11 14:03:12 CET  23h left Sat 2016-12-10 14:03:12 CET  23min ago systemd-tmpfiles-clean.timer systemd- tmpfiles-clean.service &lt;br /&gt;
 n/a                          n/a      n/a                          n/a       systemd-readahead-done.timer systemd- readahead-done.service&lt;br /&gt;
 3 timers listed.&lt;br /&gt;
&lt;br /&gt;
The certbot timer should be here /lib/systemd/system/certbot.timer and it will execute the command specified here /lib/systemd/system/certbot.service&lt;br /&gt;
&lt;br /&gt;
certbot.timer will execute the certbot.service at 12 am and 12 pm.&lt;br /&gt;
&lt;br /&gt;
 # cat /lib/systemd/system/certbot.timer&lt;br /&gt;
 [Unit]&lt;br /&gt;
 Description=Run certbot twice daily&lt;br /&gt;
 &lt;br /&gt;
 [Timer]&lt;br /&gt;
 OnCalendar=*-*-* 00,12:00:00&lt;br /&gt;
 RandomizedDelaySec=3600&lt;br /&gt;
 Persistent=true&lt;br /&gt;
 &lt;br /&gt;
 [Install]&lt;br /&gt;
 WantedBy=timers.target&lt;br /&gt;
&lt;br /&gt;
and certbot.service will execute the renew command.&lt;br /&gt;
&lt;br /&gt;
 # cat /lib/systemd/system/certbot.service&lt;br /&gt;
 [Unit]&lt;br /&gt;
 Description=Certbot&lt;br /&gt;
 Documentation=file:///usr/share/doc/python-certbot-doc/html/index.html&lt;br /&gt;
 Documentation=https://letsencrypt.readthedocs.io/en/latest/&lt;br /&gt;
 [Service]&lt;br /&gt;
 Type=oneshot&lt;br /&gt;
 ExecStart=/usr/bin/certbot -q renew&lt;br /&gt;
 PrivateTmp=true&lt;/div&gt;</summary>
		<author><name>172.17.0.1</name></author>
	</entry>
</feed>