mirror of
https://github.com/certbot/certbot.git
synced 2026-06-08 00:02:14 -04:00
Increase compatibility
This commit is contained in:
parent
1b16d64b9f
commit
2a9505927a
3 changed files with 2 additions and 5 deletions
|
|
@ -1,8 +1,8 @@
|
|||
#Requires -RunAsAdministrator
|
||||
[CmdletBinding()]
|
||||
param()
|
||||
begin {}
|
||||
process {
|
||||
New-Item "C:\Certbot\log" -ItemType Directory -ErrorAction SilentlyContinue *>$Null
|
||||
Start-Transcript -Path "C:\Certbot\log\auto-update.log"
|
||||
trap { Stop-Transcript }
|
||||
|
||||
|
|
@ -25,6 +25,7 @@ process {
|
|||
|
||||
# Get latest remote certbot version
|
||||
try {
|
||||
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
|
||||
$result = Invoke-RestMethod -Uri https://api.github.com/repos/certbot/certbot/releases/latest
|
||||
$latestVersion = $result.tag_name -replace '^v(\d+\.\d+\.\d+).*$', '$1'
|
||||
$latestVersion = [System.Version]"$latestVersion"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
#Requires -RunAsAdministrator
|
||||
|
||||
$tasks = "Certbot Renew & Auto-Update Task", "Certbot Renew Task"
|
||||
|
||||
foreach ($task in $tasks) {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
#Requires -RunAsAdministrator
|
||||
|
||||
param(
|
||||
[Parameter(Mandatory=$true, ValueFromPipeline=$true)]
|
||||
[string]
|
||||
|
|
|
|||
Loading…
Reference in a new issue