diff options
author | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2016-07-14 17:09:40 -0700 |
---|---|---|
committer | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2016-07-14 17:09:40 -0700 |
commit | a5400e016234150c858ae04624bdab5725045c1b (patch) | |
tree | bcc259505e9c4a6778fb25cce4398a6058041c73 /ext/installfiles/windows/chocolatey | |
parent | bdc3b0834bb8abc621ee6dbc9a92769b57376bee (diff) | |
download | infinitytier-a5400e016234150c858ae04624bdab5725045c1b.tar.gz infinitytier-a5400e016234150c858ae04624bdab5725045c1b.zip |
Windows installer now installs a batch file and Path variable settings to make zerotier-cli work in the Windows CLI (1.1.12 MSI updated on web for this too) and a Chocolatey packaging job for ZeroTier One.
Diffstat (limited to 'ext/installfiles/windows/chocolatey')
5 files changed, 130 insertions, 0 deletions
diff --git a/ext/installfiles/windows/chocolatey/zerotier-one/tools/LICENSE.txt b/ext/installfiles/windows/chocolatey/zerotier-one/tools/LICENSE.txt new file mode 100644 index 00000000..ce0564ac --- /dev/null +++ b/ext/installfiles/windows/chocolatey/zerotier-one/tools/LICENSE.txt @@ -0,0 +1,11 @@ +From: https://raw.githubusercontent.com/zerotier/ZeroTierOne/master/COPYING + +LICENSE + +ZeroTier One is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 3 of the License, or (at +your option) any later version. + +See the file ‘LICENSE.GPL-3’ for the text of the GNU GPL version 3. +If that file is not present, see <http://www.gnu.org/licenses/>. diff --git a/ext/installfiles/windows/chocolatey/zerotier-one/tools/VERIFICATION.txt b/ext/installfiles/windows/chocolatey/zerotier-one/tools/VERIFICATION.txt new file mode 100644 index 00000000..0a5bc760 --- /dev/null +++ b/ext/installfiles/windows/chocolatey/zerotier-one/tools/VERIFICATION.txt @@ -0,0 +1,5 @@ +VERIFICATION +Verification is intended to assist the Chocolatey moderators and community +in verifying that this package's contents are trustworthy. + +Our MSI installer should be signed by ZeroTier, Inc. using a certificate from DigiCert. diff --git a/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyinstall.ps1 b/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyinstall.ps1 new file mode 100644 index 00000000..b29fd99d --- /dev/null +++ b/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyinstall.ps1 @@ -0,0 +1,8 @@ +$packageName = 'zerotier-one' +$installerType = 'msi' +$url = 'https://download.zerotier.com/RELEASES/1.1.12/dist/ZeroTier%20One.msi' +$url64 = 'https://download.zerotier.com/RELEASES/1.1.12/dist/ZeroTier%20One.msi' +$silentArgs = '/quiet' +$validExitCodes = @(0,3010) + +Install-ChocolateyPackage $packageName $installerType $silentArgs $url $url64 -validExitCodes $validExitCodes diff --git a/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyuninstall.ps1 b/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyuninstall.ps1 new file mode 100644 index 00000000..81f7a5ac --- /dev/null +++ b/ext/installfiles/windows/chocolatey/zerotier-one/tools/chocolateyuninstall.ps1 @@ -0,0 +1,30 @@ +$ErrorActionPreference = 'Stop'; + +$packageName = 'zerotier-one' +$softwareName = 'ZeroTier One*' +$installerType = 'MSI' + +$silentArgs = '/qn /norestart' +$validExitCodes = @(0, 3010, 1605, 1614, 1641) +$uninstalled = $false + +[array]$key = Get-UninstallRegistryKey -SoftwareName $softwareName + +if ($key.Count -eq 1) { + $key | % { + $silentArgs = "$($_.PSChildName) $silentArgs" + $file = '' + Uninstall-ChocolateyPackage -PackageName $packageName ` + -FileType $installerType ` + -SilentArgs "$silentArgs" ` + -ValidExitCodes $validExitCodes ` + -File "$file" + } +} elseif ($key.Count -eq 0) { + Write-Warning "$packageName has already been uninstalled by other means." +} elseif ($key.Count -gt 1) { + Write-Warning "$key.Count matches found!" + Write-Warning "To prevent accidental data loss, no programs will be uninstalled." + Write-Warning "Please alert package maintainer the following keys were matched:" + $key | % {Write-Warning "- $_.DisplayName"} +} diff --git a/ext/installfiles/windows/chocolatey/zerotier-one/zerotier-one.nuspec b/ext/installfiles/windows/chocolatey/zerotier-one/zerotier-one.nuspec new file mode 100644 index 00000000..473007c8 --- /dev/null +++ b/ext/installfiles/windows/chocolatey/zerotier-one/zerotier-one.nuspec @@ -0,0 +1,76 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Read this before creating packages: https://github.com/chocolatey/chocolatey/wiki/CreatePackages --> +<!-- It is especially important to read the above link to understand additional requirements when publishing packages to the community feed aka dot org (https://chocolatey.org/packages). --> + +<!-- Test your packages in a test environment: https://github.com/chocolatey/chocolatey-test-environment --> + +<!-- +This is a nuspec. It mostly adheres to https://docs.nuget.org/create/Nuspec-Reference. Chocolatey uses a special version of NuGet.Core that allows us to do more than was initially possible. As such there are certain things to be aware of: + +* the package xmlns schema url may cause issues with nuget.exe +* Any of the following elements can ONLY be used by choco tools - projectSourceUrl, docsUrl, mailingListUrl, bugTrackerUrl, packageSourceUrl, provides, conflicts, replaces +* nuget.exe can still install packages with those elements but they are ignored. Any authoring tools or commands will error on those elements +--> + +<!-- You can embed software files directly into packages, as long as you are not bound by distribution rights. --> +<!-- * If you are an organization making private packages, you probably have no issues here --> +<!-- * If you are releasing to the community feed, you need to consider distribution rights. --> +<!-- Do not remove this test for UTF-8: if “Ω” doesn’t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. --> +<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd"> + <metadata> + <!-- == PACKAGE SPECIFIC SECTION == --> + <!-- This section is about this package, although id and version have ties back to the software --> + <!-- id is lowercase and if you want a good separator for words, use '-', not '.'. Dots are only acceptable as suffixes for certain types of packages, e.g. .install, .portable, .extension, .template --> + <!-- If the software is cross-platform, attempt to use the same id as the debian/rpm package(s) if possible. --> + <id>zerotier-one</id> + <!-- version should MATCH as closely as possible with the underlying software --> + <!-- Is the version a prerelease of a version? https://docs.nuget.org/create/versioning#creating-prerelease-packages --> + <!-- Note that unstable versions like 0.0.1 can be considered a released version, but it's possible that one can release a 0.0.1-beta before you release a 0.0.1 version. If the version number is final, that is considered a released version and not a prerelease. --> + <version>1.1.12</version> + <!-- <packageSourceUrl>Where is this Chocolatey package located (think GitHub)? packageSourceUrl is highly recommended for the community feed</packageSourceUrl>--> + <!-- owners is a poor name for maintainers of the package. It sticks around by this name for compatibility reasons. It basically means you. --> + <!--<owners>ZeroTier, Inc.</owners>--> + <!-- ============================== --> + + <!-- == SOFTWARE SPECIFIC SECTION == --> + <!-- This section is about the software itself --> + <title>zerotier-one (Install)</title> + <authors>ZeroTier, Inc.</authors> + <!-- projectUrl is required for the community feed --> + <projectUrl>https://www.zerotier.com/</projectUrl> + <!--<iconUrl>https://www.zerotier.com/img/ZeroTierIcon.png</iconUrl>--> + <!-- <copyright>2011-2016 ZeroTier, Inc.</copyright> --> + <!-- If there is a license Url available, it is is required for the community feed --> + <!-- <licenseUrl>https://raw.githubusercontent.com/zerotier/ZeroTierOne/master/COPYING</licenseUrl> + <requireLicenseAcceptance>true</requireLicenseAcceptance>--> + <!--<projectSourceUrl>https://github.com/zerotier/ZeroTierOne</projectSourceUrl>--> + <!--<docsUrl>https://www.zerotier.com/</docsUrl>--> + <!--<mailingListUrl></mailingListUrl>--> + <!--<bugTrackerUrl>https://github.com/zerotier/ZeroTierOne/issues</bugTrackerUrl>--> + <tags>zerotier-one admin</tags> + <summary>ZeroTier One Virtual Network Endpoint for Windows</summary> + <description>ZeroTier is a smart switch for Earth with VLAN capability. See https://www.zerotier.com/ for more information.</description> + <!-- <releaseNotes>__REPLACE_OR_REMOVE__MarkDown_Okay</releaseNotes> --> + <!-- =============================== --> + + <!-- Specifying dependencies and version ranges? https://docs.nuget.org/create/versioning#specifying-version-ranges-in-.nuspec-files --> + <!--<dependencies> + <dependency id="" version="__MINIMUM_VERSION__" /> + <dependency id="" version="[__EXACT_VERSION__]" /> + <dependency id="" version="[_MIN_VERSION_INCLUSIVE, MAX_VERSION_INCLUSIVE]" /> + <dependency id="" version="[_MIN_VERSION_INCLUSIVE, MAX_VERSION_EXCLUSIVE)" /> + <dependency id="" /> + <dependency id="chocolatey-uninstall.extension" /> + </dependencies>--> + <!-- chocolatey-uninstall.extension - If supporting 0.9.9.x (or below) and including a chocolateyUninstall.ps1 file to uninstall an EXE/MSI, you probably want to include chocolatey-uninstall.extension as a dependency. Please verify whether you are using a helper function from that package. --> + + <!--<provides>NOT YET IMPLEMENTED</provides>--> + <!--<conflicts>NOT YET IMPLEMENTED</conflicts>--> + <!--<replaces>NOT YET IMPLEMENTED</replaces>--> + </metadata> + <files> + <!-- this section controls what actually gets packaged into the Chocolatey package --> + <file src="tools\**" target="tools" /> + <!--Building from Linux? You may need this instead: <file src="tools/**" target="tools" />--> + </files> +</package> |