mirror of
https://github.com/certbot/certbot.git
synced 2026-08-01 18:56:55 +02:00
[Windows] Create a certbot renew scheduled task using the installer (#7371)
This PR implements the item "register a scheduled task for certificate renewal" from the list of requirements described in #7365. This PR adds required instructions in the NSIS installer for Certbot to create a task, named "Certbot Renew Task" in the Windows Scheduler. This task is run twice a day, to execute the command certbot renew and keep the certificates up-to-date. Uninstalling Certbot will also remove this scheduled task. * Implementation * Corrections * Update template.nsi * Improve scripts * Add a random delay of 12 hours * Synchronize template against default one in pynsist 2.4 * Clean config of scheduled task * Install only in AllUsers mode * Add comments * Remove the logic of single user install
This commit is contained in:
committed by
Brad Warren
parent
754c34c120
commit
e402993c34
@@ -0,0 +1,6 @@
|
||||
$taskName = "Certbot Renew Task"
|
||||
|
||||
$exists = Get-ScheduledTask | Where-Object {$_.TaskName -like $taskName}
|
||||
if ($exists) {
|
||||
Unregister-ScheduledTask -TaskName $taskName -Confirm:$false
|
||||
}
|
||||
Reference in New Issue
Block a user