From 8a92cb3d50bfc623b32de5045398146130c91a05 Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Wed, 31 May 2017 11:17:04 +0200 Subject: [PATCH 1/6] GH-31 & GH-32 (#33) --- CHANGELOG.md | 6 ++++++ Source/Modules/ISHServer/Set-ISHUserLocal.ps1 | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 820c3b1..188c19e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +**1.6** + +Issues: +- GH-32: Set-ISHUserLocal throws error "net.exe : The user name could not be found." when the password has character " +- GH-31: Set-ISHUserLocal cannot work with passwords longer thatn 14 characters + **1.5** Issues: diff --git a/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 b/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 index 66a987f..ad8a049 100644 --- a/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 +++ b/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 @@ -99,14 +99,16 @@ function Set-ISHUserLocal } } + # Do this for when the password contains the " character + $normalizedOSUserPassword=$osUserPassword.Replace('"','\"') if($existingUsers -contains $localUserName) { - & NET USER $localUserName $osUserPassword + & NET USER $localUserName $normalizedOSUserPassword /Y Write-Verbose "Updated $localUserName" } else { - & NET USER $localUserName $osUserPassword /ADD + & NET USER $localUserName $normalizedOSUserPassword /ADD /Y $user = [adsi]"WinNT://$env:computername/$localUserName" $user.UserFlags.value = $user.UserFlags.value -bor 0x10000 $user.CommitChanges() From 12fe36f763ca4091bc3279a5719204f0e103fb3a Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Wed, 31 May 2017 16:21:02 +0200 Subject: [PATCH 2/6] GH-34 (#35) * GH-34 * GH-34 --- CHANGELOG.md | 6 +++++- README.md | 2 +- .../{Get-ISHCOMPlus.ps1 => Get-ISHServerCOMPlus.ps1} | 2 +- Source/Modules/ISHServer/ISHServer.12.psm1 | 2 +- Source/Modules/ISHServer/ISHServer.13.psm1 | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) rename Source/Modules/ISHServer/{Get-ISHCOMPlus.ps1 => Get-ISHServerCOMPlus.ps1} (98%) diff --git a/CHANGELOG.md b/CHANGELOG.md index 188c19e..f42eea5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,11 @@ Issues: - GH-32: Set-ISHUserLocal throws error "net.exe : The user name could not be found." when the password has character " -- GH-31: Set-ISHUserLocal cannot work with passwords longer thatn 14 characters +- GH-31: Set-ISHUserLocal cannot work with passwords longer than 14 characters +- GH-34: Rename Get-ISHCOMPlus to Get-ISHServerCOMPlus + +In detail: +- Renamed `Get-ISHCOMPlus` to `Get-ISHServerCOMPlus` **1.5** diff --git a/README.md b/README.md index f9695b0..986cf00 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,7 @@ The target path is always `C:\ISHCD\X.0.Z` where `X` is the major version and `Y For installation and maintenance reasons, the module offers a couple of general purpose cmdlets: -- `Get-ISHCOMPlus` returns the status of COM+ applications. This can prove useful for troubleshooting after the product is installed. +- `Get-ISHServerCOMPlus` returns the status of COM+ applications. This can prove useful for troubleshooting after the product is installed. - `Get-ISHNETInfo` returns the available .NET versions on the operating system. - `Get-ISHOSInfo` returns details of the operating system. diff --git a/Source/Modules/ISHServer/Get-ISHCOMPlus.ps1 b/Source/Modules/ISHServer/Get-ISHServerCOMPlus.ps1 similarity index 98% rename from Source/Modules/ISHServer/Get-ISHCOMPlus.ps1 rename to Source/Modules/ISHServer/Get-ISHServerCOMPlus.ps1 index 4d3979f..5195750 100644 --- a/Source/Modules/ISHServer/Get-ISHCOMPlus.ps1 +++ b/Source/Modules/ISHServer/Get-ISHServerCOMPlus.ps1 @@ -14,7 +14,7 @@ # limitations under the License. #> -function Get-ISHCOMPlus +function Get-ISHServerCOMPlus { [CmdletBinding()] Param() diff --git a/Source/Modules/ISHServer/ISHServer.12.psm1 b/Source/Modules/ISHServer/ISHServer.12.psm1 index da298b4..4a27170 100644 --- a/Source/Modules/ISHServer/ISHServer.12.psm1 +++ b/Source/Modules/ISHServer/ISHServer.12.psm1 @@ -21,7 +21,7 @@ $exportNames=@( "Test-ISHServerCompliance" "Get-ISHServerFolderPath" "Grant-ISHUserLogOnAsService" - "Get-ISHCOMPlus" + "Get-ISHServerCOMPlus" "Get-ISHNormalizedCredential" #endregion diff --git a/Source/Modules/ISHServer/ISHServer.13.psm1 b/Source/Modules/ISHServer/ISHServer.13.psm1 index 977a9fe..818d916 100644 --- a/Source/Modules/ISHServer/ISHServer.13.psm1 +++ b/Source/Modules/ISHServer/ISHServer.13.psm1 @@ -21,7 +21,7 @@ $exportNames=@( "Test-ISHServerCompliance" "Get-ISHServerFolderPath" "Grant-ISHUserLogOnAsService" - "Get-ISHCOMPlus" + "Get-ISHServerCOMPlus" "Get-ISHNormalizedCredential" #endregion From 50955a4e887ed89c7ec31cb9dd202adc89e6ffda Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Tue, 6 Jun 2017 15:33:04 +0200 Subject: [PATCH 3/6] Removed output of user for Set-ISHUserLocal --- Source/Modules/ISHServer/Set-ISHUserLocal.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 b/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 index ad8a049..af48524 100644 --- a/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 +++ b/Source/Modules/ISHServer/Set-ISHUserLocal.ps1 @@ -66,12 +66,12 @@ function Set-ISHUserLocal { if(Get-LocalUser -Name $localUserName -ErrorAction SilentlyContinue) { - Set-LocalUser -Name $localUserName -Password $OsUserCredentials.Password -AccountNeverExpires + $null=Set-LocalUser -Name $localUserName -Password $OsUserCredentials.Password -AccountNeverExpires Write-Verbose "Updated $localUserName" } else { - New-LocalUser -Name $localUserName -Password $OsUserCredentials.Password -AccountNeverExpires -PasswordNeverExpires + $null=New-LocalUser -Name $localUserName -Password $OsUserCredentials.Password -AccountNeverExpires -PasswordNeverExpires Write-Verbose "Created $localUserName" } } From cd92a7a1ecdaf635aef0b7b2d7c1c04d9dd3eec0 Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Mon, 9 Oct 2017 14:37:32 +0200 Subject: [PATCH 4/6] Upgrade od twith odac122010 (#41) * GH-39 - Added artifacts for new ODAC version * GH-39 & GH-40 : Updated dependencies and refactored implementation for future convinience. --- README.md | 28 ++- .../ISHServer/Get-ISHPrerequisites.ISH12.ps1 | 199 ------------------ ...tes.ISH13.ps1 => Get-ISHPrerequisites.ps1} | 37 ++-- .../ISHServer/Get-ISHServerFolderPath.ps1 | 8 +- Source/Modules/ISHServer/ISHServer.12.psm1 | 18 +- Source/Modules/ISHServer/ISHServer.13.psm1 | 18 +- .../ISHServer/Install-ISHToolAntennaHouse.ps1 | 2 +- .../ISHServer/Install-ISHToolDotNET.ISH12.ps1 | 36 ---- ...ET.ISH13.ps1 => Install-ISHToolDotNET.ps1} | 2 +- .../ISHServer/Install-ISHToolHtmlHelp.ps1 | 2 +- .../Modules/ISHServer/Install-ISHToolJAVA.ps1 | 6 +- .../ISHServer/Install-ISHToolJavaHelp.ps1 | 2 +- .../ISHServer/Install-ISHToolMSXML4.ps1 | 2 +- .../ISHServer/Install-ISHToolOracleODAC.ps1 | 2 +- .../Install-ISHToolVisualCPP.ISH13.ps1 | 50 ----- ...ISH12.ps1 => Install-ISHToolVisualCPP.ps1} | 2 +- .../Install-ISHVisualBasicRuntime.ps1 | 2 +- .../Set-ISHToolAntennaHouseLicense.ps1 | 2 +- 18 files changed, 93 insertions(+), 325 deletions(-) delete mode 100644 Source/Modules/ISHServer/Get-ISHPrerequisites.ISH12.ps1 rename Source/Modules/ISHServer/{Get-ISHPrerequisites.ISH13.ps1 => Get-ISHPrerequisites.ps1} (84%) delete mode 100644 Source/Modules/ISHServer/Install-ISHToolDotNET.ISH12.ps1 rename Source/Modules/ISHServer/{Install-ISHToolDotNET.ISH13.ps1 => Install-ISHToolDotNET.ps1} (94%) delete mode 100644 Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH13.ps1 rename Source/Modules/ISHServer/{Install-ISHToolVisualCPP.ISH12.ps1 => Install-ISHToolVisualCPP.ps1} (93%) diff --git a/README.md b/README.md index 986cf00..7a8e06b 100644 --- a/README.md +++ b/README.md @@ -30,10 +30,11 @@ The supported operating systems are: Because of the size of **Knowledge Center Content Manager** prerequisites they are not included in the module. This makes it your responsibility to make them available to the module. -To find out which file names are required, execute `Get-ISHPrerequisites -FileNames` and the result should be +To find out which file names are required, execute `Get-ISHPrerequisites -FileNames` and the result should be per Knowledge Center version: + +**Knowledge Center 2016 - Content Manager 12 - ISHServer.12** ```text -MSXML.40SP3.msi jdk-8u60-windows-x64.exe jre-8u60-windows-x64.exe javahelp-2_0_05.zip @@ -44,9 +45,28 @@ V6-2-M9-Windows_X64_64E.exe.vcredist_x64.exe V6-2-M9-Windows_X64_64E.exe.vcredist_x86.exe ODTwithODAC121012.zip ODTwithODAC121012.rsp +MSXML.40SP3.msi NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe ``` +**Knowledge Center 2018 - Content Manager 13 - ISHServer.13** + +```text +jdk-8u144-windows-x64.exe +jre-8u144-windows-x64.exe +javahelp-2_0_05.zip +htmlhelp.zip +V6-5-R1-Windows_X64_64E.exe +V6-5-R1-Windows_X64_64E.exe.iss +V6-5-R1-Windows_X64_64E.exe.vcredist_x64.exe +V6-5-R1-Windows_X64_64E.exe.vcredist_x86.exe +ODTwithODAC122010.zip +ODTwithODAC122010.rsp +NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe +NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe +``` + + If you want to manually make the files available to the module then copy them to the location provided by `Get-ISHServerFolderPath`. As an alternative, the `Get-ISHPrerequisites` cmdlet offers the option to download the files will take care of everything. @@ -66,6 +86,7 @@ ISHServer offers two cmdlets to download and expand the ISHCD. **Notice that it The target path is always `C:\ISHCD\X.0.Z` where `X` is the major version and `Y` the revision. - For `12.0.1` it's `C:\ISHCD\12.0.1` - For `12.0.3` it's `C:\ISHCD\12.0.3` +- For `13.0.0` it's `C:\ISHCD\13.0.0` ## Maintenance @@ -85,10 +106,13 @@ The goal is to reuse as much as possible the scripts developed for **ISHServer.1 Current differences of **ISHServer.13** with **ISHServer.12**: +- **Java** runtime and development kit for (64-bit) 1.8.0_144. - **MSDTC** is removed form the prerequisites list, therefore the `Initialize-ISHMSDTCSettings` and `Initialize-ISHMSDTCTransactionTimeout` cmdlets are removed. - **MSXML** is removed form the prerequisites list, therefore the `Install-ISHToolMSXML4` cmdlet is removed. - **Microsoft .NET Framework 4.6.1** is required instead of **Microsoft .NET Framework 4.5**. - **Visual C++ Redistributable for Visual Studio 2015** is required instead of **Visual C++ Redistributable for Visual Studio 2013**. +- **Oracle Client - ODAC 12c2 Release 1 (12.2.0.1.0)** is required instead of **Oracle Client - ODAC 12c Release 4**. +- **Antenna House V6.5**. # Acknowledgements diff --git a/Source/Modules/ISHServer/Get-ISHPrerequisites.ISH12.ps1 b/Source/Modules/ISHServer/Get-ISHPrerequisites.ISH12.ps1 deleted file mode 100644 index 1a2de7f..0000000 --- a/Source/Modules/ISHServer/Get-ISHPrerequisites.ISH12.ps1 +++ /dev/null @@ -1,199 +0,0 @@ -<# -# Copyright (c) 2014 All Rights Reserved by the SDL Group. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#> - -function Get-ISHPrerequisites -{ - [CmdletBinding()] - param( - [Parameter(Mandatory=$true,ParameterSetName="From FTP")] - [string]$FTPHost, - [Parameter(Mandatory=$true,ParameterSetName="From FTP")] - [pscredential]$Credential, - [Parameter(Mandatory=$true,ParameterSetName="From FTP")] - [string]$FTPFolder, - [Parameter(Mandatory=$true,ParameterSetName="From AWS S3")] - [string]$BucketName, - [Parameter(Mandatory=$true,ParameterSetName="From AWS S3")] - [string]$FolderKey, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$AccessKey, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$ProfileName, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$ProfileLocation, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$Region, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$SecretKey, - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [string]$SessionToken, - [Parameter(Mandatory=$true,ParameterSetName="From Azure FileStorage")] - [string]$ShareName, - [Parameter(Mandatory=$true,ParameterSetName="From Azure BlobStorage")] - [string]$ContainerName, - [Parameter(Mandatory=$true,ParameterSetName="From Azure FileStorage")] - [Parameter(Mandatory=$true,ParameterSetName="From Azure BlobStorage")] - [string]$FolderPath, - [Parameter(Mandatory=$true,ParameterSetName="From Azure FileStorage")] - [Parameter(Mandatory=$true,ParameterSetName="From Azure BlobStorage")] - [string]$StorageAccountName, - [Parameter(Mandatory=$true,ParameterSetName="From Azure FileStorage")] - [Parameter(Mandatory=$true,ParameterSetName="From Azure BlobStorage")] - [string]$StorageAccountKey, - [Parameter(Mandatory=$false,ParameterSetName="From FTP")] - [Parameter(Mandatory=$false,ParameterSetName="From AWS S3")] - [Parameter(Mandatory=$false,ParameterSetName="From Azure FileStorage")] - [Parameter(Mandatory=$false,ParameterSetName="From Azure BlobStorage")] - [switch]$Force=$false, - [Parameter(Mandatory=$true,ParameterSetName="No Download")] - [switch]$FileNames - ) - - begin - { - if($PSCmdlet.ParameterSetName -ne "No Download") - { - . $PSScriptRoot\Private\Test-RunningAsElevated.ps1 - Test-RunningAsElevated -StopCallerPSCmdlet $PSCmdlet - } - - . $PSScriptRoot\Get-ISHServerFolderPath.ps1 - . $PSScriptRoot\Get-ISHOSInfo.ps1 - - if(-not ($FTPFolder.EndsWith("/"))) - { - $FTPFolder+="/" - } - if(-not ($FolderKey.EndsWith("/"))) - { - $FolderKey+="/" - } - if(-not ($FolderPath.EndsWith("/"))) - { - $FolderPath+="/" - } - } - - process - { - $filesToDownload=@( - #Common for 12 and 13 - "jdk-8u60-windows-x64.exe" - "jre-8u60-windows-x64.exe" - "javahelp-2_0_05.zip" - "htmlhelp.zip" - "V6-2-M9-Windows_X64_64E.exe" - "V6-2-M9-Windows_X64_64E.exe.iss" - "V6-2-M9-Windows_X64_64E.exe.vcredist_x64.exe" - "V6-2-M9-Windows_X64_64E.exe.vcredist_x86.exe" - "ODTwithODAC121012.zip" - "ODTwithODAC121012.rsp" - - #Specific for 12 - "MSXML.40SP3.msi" - "NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe" - ) - $osInfo=Get-ISHOSInfo - if($osInfo.IsCore) - { - $filesToDownload+="vbrun60sp6.exe" - } - - if($PSCmdlet.ParameterSetName -ne "No Download") - { - $localPath=Get-ISHServerFolderPath - } - - switch ($PSCmdlet.ParameterSetName) - { - 'From FTP' { - . $PSScriptRoot\Private\Get-ISHFTPItem.ps1 - - $paths=@() - $filesToDownload | ForEach-Object { - $paths+="$FTPFolder$_" - } - Get-ISHFTPItem -FTPHost $FTPHost -Credential $Credential -Path $paths -LocalPath $localPath -Force:$Force | Out-Null - break - } - 'From AWS S3' { - . $PSScriptRoot\Private\Get-ISHS3Object.ps1 - - $hash=@{ - BucketName=$BucketName - LocalFolder=$localPath - AccessKey=$AccessKey - ProfileName=$ProfileName - ProfileLocation=$ProfileLocation - Region=$Region - SecretKey=$SecretKey - SessionToken=$SessionToken - } - $keys=@() - $filesToDownload | ForEach-Object { - $keys+="$FolderKey$_" - } - Get-ISHS3Object -Key $keys @hash -Force:$Force | Out-Null - break - } - 'From Azure FileStorage' { - . $PSScriptRoot\Private\Get-ISHAzureFileObject.ps1 - - $localPath=Get-ISHServerFolderPath - $hash=@{ - ShareName=$ShareName - LocalFolder=$localPath - StorageAccountName=$StorageAccountName - StorageAccountKey=$StorageAccountKey - } - $paths=@() - $filesToDownload | ForEach-Object { - $paths+="$FolderPath$_" - } - Get-ISHAzureFileObject -Path $paths @hash -Force:$Force | Out-Null - break - } - 'From Azure BlobStorage' { - . $PSScriptRoot\Private\Get-ISHAzureBlobObject.ps1 - - $hash=@{ - ContainerName=$ContainerName - LocalFolder=$localPath - StorageAccountName=$StorageAccountName - StorageAccountKey=$StorageAccountKey - } - $blobs=@() - $filesToDownload | ForEach-Object { - $blobs+="$FolderPath$_" - } - Get-ISHAzureBlobObject -BlobName $blobs @hash -Force:$Force | Out-Null - break - } - 'No Download' { - if($FileNames) - { - $filesToDownload - } - break - } - } - } - - end - { - - } -} diff --git a/Source/Modules/ISHServer/Get-ISHPrerequisites.ISH13.ps1 b/Source/Modules/ISHServer/Get-ISHPrerequisites.ps1 similarity index 84% rename from Source/Modules/ISHServer/Get-ISHPrerequisites.ISH13.ps1 rename to Source/Modules/ISHServer/Get-ISHPrerequisites.ps1 index d20d969..16bb0e5 100644 --- a/Source/Modules/ISHServer/Get-ISHPrerequisites.ISH13.ps1 +++ b/Source/Modules/ISHServer/Get-ISHPrerequisites.ps1 @@ -91,34 +91,41 @@ function Get-ISHPrerequisites { $filesToDownload=@( #Common for 12 and 13 - "jdk-8u60-windows-x64.exe" - "jre-8u60-windows-x64.exe" - "javahelp-2_0_05.zip" - "htmlhelp.zip" - "V6-2-M9-Windows_X64_64E.exe" - "V6-2-M9-Windows_X64_64E.exe.iss" - "V6-2-M9-Windows_X64_64E.exe.vcredist_x64.exe" - "V6-2-M9-Windows_X64_64E.exe.vcredist_x86.exe" - "ODTwithODAC121012.zip" - "ODTwithODAC121012.rsp" + Get-Variable -Name "ISHServer:JDK" -ValueOnly + Get-Variable -Name "ISHServer:JRE" -ValueOnly + Get-Variable -Name "ISHServer:JavaHelp" -ValueOnly + Get-Variable -Name "ISHServer:HtmlHelp" -ValueOnly + "$(Get-Variable -Name "ISHServer:AntennaHouse" -ValueOnly)" + "$(Get-Variable -Name "ISHServer:AntennaHouse" -ValueOnly).iss" + "$(Get-Variable -Name "ISHServer:AntennaHouse" -ValueOnly).vcredist_x64.exe" + "$(Get-Variable -Name "ISHServer:AntennaHouse" -ValueOnly).vcredist_x86.exe" + "$(Get-Variable -Name "ISHServer:Oracle" -ValueOnly).zip" + "$(Get-Variable -Name "ISHServer:Oracle" -ValueOnly).rsp" - #Specific for 13 - "NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe" + Get-Variable -Name "ISHServer:MicrosoftVisualCPlusPlusRedistributable" -ValueOnly ) + if($PSCmdlet.MyInvocation.MyCommand.Module.Name -eq "ISHServer.12") + { + $filesToDownload+=Get-Variable -Name "ISHServer:MSXML" -ValueOnly + } + $osInfo=Get-ISHOSInfo - + if($osInfo.Server -eq "2016") { } else { - $filesToDownload+="NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe" + if($PSCmdlet.MyInvocation.MyCommand.Module.Name -eq "ISHServer.13") + { + $filesToDownload+=Get-Variable -Name "ISHServer:NETFramework" -ValueOnly + } } if($osInfo.IsCore) { - $filesToDownload+="vbrun60sp6.exe" + $filesToDownload+=Get-Variable -Name "ISHServer:VisualBasicRuntime" -ValueOnly } if($PSCmdlet.ParameterSetName -ne "No Download") diff --git a/Source/Modules/ISHServer/Get-ISHServerFolderPath.ps1 b/Source/Modules/ISHServer/Get-ISHServerFolderPath.ps1 index fd0190d..8dfd449 100644 --- a/Source/Modules/ISHServer/Get-ISHServerFolderPath.ps1 +++ b/Source/Modules/ISHServer/Get-ISHServerFolderPath.ps1 @@ -30,13 +30,7 @@ function Get-ISHServerFolderPath process { - $moduleName=$($MyInvocation.MyCommand.Module) - if(-not $moduleName) - { - $moduleName="ISHServer.Debug" - Write-Warning "Executed the cmdlet directly. Setting module name to $moduleName" - } - $programDataPath=Join-Path $env:ProgramData $moduleName + $programDataPath=Join-Path $env:ProgramData ($MyInvocation.MyCommand.Module.Name) if(-not (Test-Path $programDataPath)) { New-Item $programDataPath -ItemType Directory |Out-Null diff --git a/Source/Modules/ISHServer/ISHServer.12.psm1 b/Source/Modules/ISHServer/ISHServer.12.psm1 index 4a27170..a85dd9a 100644 --- a/Source/Modules/ISHServer/ISHServer.12.psm1 +++ b/Source/Modules/ISHServer/ISHServer.12.psm1 @@ -14,6 +14,18 @@ # limitations under the License. #> +Set-Variable -Name "ISHServer:JDK" -Value "jdk-8u60-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JRE" -Value "jre-8u60-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JavaHelp" -Value "javahelp-2_0_05.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:HtmlHelp" -Value "htmlhelp.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouse" -Value "V6-2-M9-Windows_X64_64E.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouseInstallPath" -Value "Antenna House\AHFormatterV62\" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:Oracle" -Value "ODTwithODAC121012" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:MicrosoftVisualCPlusPlusRedistributable" -Value "NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe" -Scope "Script" -Option Constant +#Set-Variable -Name "ISHServer:NETFramework" -Value "jre-8u60-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:VisualBasicRuntime" -Value "vbrun60sp6.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:MSXML" -Value "MSXML.40SP3.msi" -Scope "Script" -Option Constant + $exportNames=@( #region Helpers "Get-ISHOSInfo" @@ -37,7 +49,7 @@ $exportNames=@( #region Global "Get-ISHServerFolderPath" - "Get-ISHPrerequisites.ISH12" + "Get-ISHPrerequisites" "Initialize-ISHLocale" "Initialize-ISHIIS" "Initialize-ISHUserLocalProfile" @@ -50,8 +62,8 @@ $exportNames=@( #region Install "Install-ISHToolMSXML4" - "Install-ISHToolDotNET.ISH12" - "Install-ISHToolVisualCPP.ISH12" + "Install-ISHToolDotNET" + "Install-ISHToolVisualCPP" "Install-ISHToolJAVA" "Install-ISHToolJavaHelp" "Install-ISHToolHtmlHelp" diff --git a/Source/Modules/ISHServer/ISHServer.13.psm1 b/Source/Modules/ISHServer/ISHServer.13.psm1 index 818d916..2740d70 100644 --- a/Source/Modules/ISHServer/ISHServer.13.psm1 +++ b/Source/Modules/ISHServer/ISHServer.13.psm1 @@ -14,6 +14,18 @@ # limitations under the License. #> +Set-Variable -Name "ISHServer:JDK" -Value "jdk-8u144-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JRE" -Value "jre-8u144-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JavaHelp" -Value "javahelp-2_0_05.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:HtmlHelp" -Value "htmlhelp.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouse" -Value "V6-5-R1-Windows_X64_64E.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouseInstallPath" -Value "Antenna House\AHFormatterV65\" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:Oracle" -Value "ODTwithODAC122010" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:MicrosoftVisualCPlusPlusRedistributable" -Value "NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:NETFramework" -Value "NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:VisualBasicRuntime" -Value "vbrun60sp6.exe" -Scope "Script" -Option Constant +#Set-Variable -Name "ISHServer:MSXML" -Value "MSXML.40SP3.msi" -Scope "Script" -Option Constant + $exportNames=@( #region Helpers "Get-ISHOSInfo" @@ -37,7 +49,7 @@ $exportNames=@( #region Global "Get-ISHServerFolderPath" - "Get-ISHPrerequisites.ISH13" + "Get-ISHPrerequisites" "Initialize-ISHLocale" "Initialize-ISHIIS" "Initialize-ISHUserLocalProfile" @@ -47,8 +59,8 @@ $exportNames=@( #endregion #region Install - "Install-ISHToolDotNET.ISH13" - "Install-ISHToolVisualCPP.ISH13" + "Install-ISHToolDotNET" + "Install-ISHToolVisualCPP" "Install-ISHToolJAVA" "Install-ISHToolJavaHelp" "Install-ISHToolHtmlHelp" diff --git a/Source/Modules/ISHServer/Install-ISHToolAntennaHouse.ps1 b/Source/Modules/ISHServer/Install-ISHToolAntennaHouse.ps1 index f17671c..293ddaf 100644 --- a/Source/Modules/ISHServer/Install-ISHToolAntennaHouse.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolAntennaHouse.ps1 @@ -53,7 +53,7 @@ function Install-ISHToolAntennaHouse - $fileName="V6-2-M9-Windows_X64_64E.exe" + $fileName=Get-Variable -Name "ISHServer:AntennaHouse" -ValueOnly #Before installing Antenna houe we need to install the Microsoft Visual C++ 2010. Minimum version must be 10.0.40219.1 Write-Verbose "Need to install Microsoft Visual C++ 2010 as a prerequisite" diff --git a/Source/Modules/ISHServer/Install-ISHToolDotNET.ISH12.ps1 b/Source/Modules/ISHServer/Install-ISHToolDotNET.ISH12.ps1 deleted file mode 100644 index d77f6b4..0000000 --- a/Source/Modules/ISHServer/Install-ISHToolDotNET.ISH12.ps1 +++ /dev/null @@ -1,36 +0,0 @@ -<# -# Copyright (c) 2014 All Rights Reserved by the SDL Group. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#> - -function Install-ISHToolDotNET -{ - [CmdletBinding()] - Param() - - begin - { - . $PSScriptRoot\Get-ISHOSInfo.ps1 - } - - process - { - $osInfo=Get-ISHOSInfo - Write-Verbose "Assuming .NET 4.5 is installed on $($osInfo.Caption)" - } - end - { - - } -} diff --git a/Source/Modules/ISHServer/Install-ISHToolDotNET.ISH13.ps1 b/Source/Modules/ISHServer/Install-ISHToolDotNET.ps1 similarity index 94% rename from Source/Modules/ISHServer/Install-ISHToolDotNET.ISH13.ps1 rename to Source/Modules/ISHServer/Install-ISHToolDotNET.ps1 index cb53061..ced0450 100644 --- a/Source/Modules/ISHServer/Install-ISHToolDotNET.ISH13.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolDotNET.ps1 @@ -37,7 +37,7 @@ function Install-ISHToolDotNET } else { - $fileName="NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe" + $fileName=Get-Variable -Name "ISHServer:NETFramework" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $logFile=Join-Path $env:TEMP "$FileName.htm" $arguments=@( diff --git a/Source/Modules/ISHServer/Install-ISHToolHtmlHelp.ps1 b/Source/Modules/ISHServer/Install-ISHToolHtmlHelp.ps1 index 20b5fbd..9e28be8 100644 --- a/Source/Modules/ISHServer/Install-ISHToolHtmlHelp.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolHtmlHelp.ps1 @@ -31,7 +31,7 @@ function Install-ISHToolHtmlHelp { # http://docs.sdl.com/LiveContent/content/en-US/SDL%20Knowledge%20Center%20full%20documentation-v2/GUID-7FADBDFC-919D-435F-8E0F-C54A4922100A #The original htmlhelp.exe cannot be automated. Extract and create a new zip file. - $fileName="htmlhelp.zip" + $fileName=Get-Variable -Name "ISHServer:HtmlHelp" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $targetPath=Join-Path ${env:ProgramFiles(x86)} "HTML Help Workshop" if(Test-Path $targetPath) diff --git a/Source/Modules/ISHServer/Install-ISHToolJAVA.ps1 b/Source/Modules/ISHServer/Install-ISHToolJAVA.ps1 index 6c27fea..799c5fe 100644 --- a/Source/Modules/ISHServer/Install-ISHToolJAVA.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolJAVA.ps1 @@ -30,7 +30,11 @@ function Install-ISHToolJAVA process { # http://docs.sdl.com/LiveContent/content/en-US/SDL%20Knowledge%20Center%20full%20documentation-v2/GUID-D385255A-3644-485A-9B76-2D8695C0F000 - $fileNames=@("jre-8u60-windows-x64.exe","jdk-8u60-windows-x64.exe") + $fileNames=@( + Get-Variable -Name "ISHServer:JDK" -ValueOnly + Get-Variable -Name "ISHServer:JRE" -ValueOnly + ) + $arguments=@( "/s" ) diff --git a/Source/Modules/ISHServer/Install-ISHToolJavaHelp.ps1 b/Source/Modules/ISHServer/Install-ISHToolJavaHelp.ps1 index f7e465c..cb035c9 100644 --- a/Source/Modules/ISHServer/Install-ISHToolJavaHelp.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolJavaHelp.ps1 @@ -30,7 +30,7 @@ function Install-ISHToolJavaHelp process { # http://docs.sdl.com/LiveContent/content/en-US/SDL%20Knowledge%20Center%20full%20documentation-v2/GUID-48FBD1F6-1492-4156-827C-30CA45FC60E9 - $fileName="javahelp-2_0_05.zip" + $fileName=Get-Variable -Name "ISHServer:JavaHelp" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $targetPath="C:\JavaHelp\" if(Test-Path $targetPath) diff --git a/Source/Modules/ISHServer/Install-ISHToolMSXML4.ps1 b/Source/Modules/ISHServer/Install-ISHToolMSXML4.ps1 index 4290d3d..58b395a 100644 --- a/Source/Modules/ISHServer/Install-ISHToolMSXML4.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolMSXML4.ps1 @@ -29,7 +29,7 @@ function Install-ISHToolMSXML4 { # http://docs.sdl.com/LiveContent/content/en-US/SDL%20Knowledge%20Center%20full%20documentation-v2/GUID-EA97B03F-C33B-466E-A307-CA9F2B10B22D - $fileName="MSXML.40SP3.msi" + $fileName=Get-Variable -Name "ISHServer:MSXML" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $logFile=Join-Path $env:TEMP "$fileName.log" $arguments=@( diff --git a/Source/Modules/ISHServer/Install-ISHToolOracleODAC.ps1 b/Source/Modules/ISHServer/Install-ISHToolOracleODAC.ps1 index 129c2ed..a8fc89e 100644 --- a/Source/Modules/ISHServer/Install-ISHToolOracleODAC.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolOracleODAC.ps1 @@ -31,7 +31,7 @@ function Install-ISHToolOracleODAC { # http://docs.sdl.com/LiveContent/content/en-US/SDL%20Knowledge%20Center%20full%20documentation-v2/GUID-DD65E7B5-204B-48D7-91F9-CBDCB0730B80 - $baseFileName="ODTwithODAC121012" + $baseFileName=Get-Variable -Name "ISHServer:Oracle" -ValueOnly $fileName="$baseFileName.zip" $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $targetPath=Join-Path $env:TEMP "$baseFileName" diff --git a/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH13.ps1 b/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH13.ps1 deleted file mode 100644 index 351256b..0000000 --- a/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH13.ps1 +++ /dev/null @@ -1,50 +0,0 @@ -<# -# Copyright (c) 2014 All Rights Reserved by the SDL Group. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#> - -function Install-ISHToolVisualCPP -{ - [CmdletBinding()] - Param() - - begin - { - . $PSScriptRoot\Private\Test-RunningAsElevated.ps1 - Test-RunningAsElevated -StopCallerPSCmdlet $PSCmdlet - - . $PSScriptRoot\Get-ISHServerFolderPath.ps1 - } - - process - { - $fileName="NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe" - $filePath=Join-Path (Get-ISHServerFolderPath) $fileName - $logFile=Join-Path $env:TEMP "$FileName.log" - $arguments=@( - "/install" - "/quiet" - "/log" - "$logFile" - ) - - Write-Debug "Installing $filePath and logging to $logFile" - Start-Process $filePath -ArgumentList $arguments -Wait -Verb RunAs - Write-Verbose "Installed $fileName" - } - end - { - - } -} diff --git a/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH12.ps1 b/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ps1 similarity index 93% rename from Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH12.ps1 rename to Source/Modules/ISHServer/Install-ISHToolVisualCPP.ps1 index c0ba67f..651c7ec 100644 --- a/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ISH12.ps1 +++ b/Source/Modules/ISHServer/Install-ISHToolVisualCPP.ps1 @@ -29,7 +29,7 @@ function Install-ISHToolVisualCPP process { - $fileName="NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe" + $fileName=Get-Variable -Name "ISHServer:MicrosoftVisualCPlusPlusRedistributable" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $logFile=Join-Path $env:TEMP "$FileName.log" $arguments=@( diff --git a/Source/Modules/ISHServer/Install-ISHVisualBasicRuntime.ps1 b/Source/Modules/ISHServer/Install-ISHVisualBasicRuntime.ps1 index cc96378..ad409f7 100644 --- a/Source/Modules/ISHServer/Install-ISHVisualBasicRuntime.ps1 +++ b/Source/Modules/ISHServer/Install-ISHVisualBasicRuntime.ps1 @@ -37,7 +37,7 @@ function Install-ISHVisualBasicRuntime # https://social.technet.microsoft.com/Forums/windowsserver/en-US/9b0f8911-07f4-420f-9e48-d31915f91528/msvbvm60dll-missing-in-core?forum=winservercore Write-Warning "This is a workaround for making the Visual Basic runtime available on $($osInfo.Caption) Core" - $fileName="vbrun60sp6.exe" + $fileName=Get-Variable -Name "ISHServer:VisualBasicRuntime" -ValueOnly $filePath=Join-Path (Get-ISHServerFolderPath) $fileName $arguments=@( "/Q" diff --git a/Source/Modules/ISHServer/Set-ISHToolAntennaHouseLicense.ps1 b/Source/Modules/ISHServer/Set-ISHToolAntennaHouseLicense.ps1 index 26b7a14..5e543d4 100644 --- a/Source/Modules/ISHServer/Set-ISHToolAntennaHouseLicense.ps1 +++ b/Source/Modules/ISHServer/Set-ISHToolAntennaHouseLicense.ps1 @@ -71,7 +71,7 @@ function Set-ISHToolAntennaHouseLicense process { $antennaHouseLicenseFileName="AHFormatter.lic" - $antennaHouseFolderPath=Join-Path $env:ProgramFiles "Antenna House\AHFormatterV62\" + $antennaHouseFolderPath=Join-Path $env:ProgramFiles (Get-Variable -Name "ISHServer:AntennaHouseInstallPath" -ValueOnly) $antennaHouseLicensePath=Join-Path $antennaHouseFolderPath $antennaHouseLicenseFileName if(Test-Path $antennaHouseLicensePath) { From 7e41d43256268dc30712a1c2a9855d8be7d5e86b Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Thu, 30 Nov 2017 13:57:01 +0100 Subject: [PATCH 5/6] GH-42 Make ContentManager2018 the primary artifact (#43) --- Automation/Publish-Module.ps1 | 79 ++++++++-------- CHANGELOG.md | 4 + README.md | 67 +++++++------- Source/Modules/ISHServer/ISHServer.14.psm1 | 101 +++++++++++++++++++++ 4 files changed, 179 insertions(+), 72 deletions(-) create mode 100644 Source/Modules/ISHServer/ISHServer.14.psm1 diff --git a/Automation/Publish-Module.ps1 b/Automation/Publish-Module.ps1 index 5a6c035..d4d0bb8 100644 --- a/Automation/Publish-Module.ps1 +++ b/Automation/Publish-Module.ps1 @@ -15,59 +15,69 @@ #> param( - [Parameter(Mandatory=$false,ParameterSetName="KC2016")] - [Parameter(Mandatory=$false,ParameterSetName="KC2016+Dev")] + [Parameter(Mandatory=$false,ParameterSetName="Public")] + [Parameter(Mandatory=$false,ParameterSetName="Public+Internal")] [string]$NuGetApiKey=$null, - [Parameter(Mandatory=$true,ParameterSetName="KC2016+Dev")] + [Parameter(Mandatory=$true,ParameterSetName="Public+Internal")] [ValidateScript({$_ -ne "PSGallery"})] - [string]$DevRepository #, - <# - [Parameter(Mandatory=$true,ParameterSetName="KC2016")] - [Parameter(Mandatory=$false,ParameterSetName="KC2016+Dev")] - [switch]$ISH12=$false, - [Parameter(Mandatory=$false,ParameterSetName="KC2016+Dev")] - [switch]$ISH13=$false - #> + [string]$DevRepository ) Set-StrictMode -Version latest $moduleNamesToPublish=@() switch ($PSCmdlet.ParameterSetName) { - 'KC2016' { + 'Public' { $publishDebug=$false $repository="PSGallery" $moduleNamesToPublish+="ISHServer.12" + $moduleNamesToPublish+="ISHServer.13" break; } - 'KC2016+Dev' { + 'Public+Internal' { $publishDebug=$true $repository=$DevRepository $moduleNamesToPublish+="ISHServer.12" $moduleNamesToPublish+="ISHServer.13" + $moduleNamesToPublish+="ISHServer.14" break } } $changeLogPath="$PSScriptRoot\..\CHANGELOG.md" $changeLog=Get-Content -Path $changeLogPath -if($publishDebug) -{ - $revision=0 - $date=(Get-Date).ToUniversalTime() - $build=[string](1200 * ($date.Year -2015)+$date.Month*100+$date.Day) - $build+=$date.ToString("HHmm") -} - - foreach($moduleName in $moduleNamesToPublish) { try { + if($publishDebug) + { + switch ($moduleName) + { + 'ISHServer.12' { + $startYear="2014" + break + } + 'ISHServer.13' { + $startYear="2015" + break + } + 'ISHServer.14' { + $startYear="2017" + break + } + } + + $revision=0 + $date=(Get-Date).ToUniversalTime() + $build=[string](1200 * ($date.Year -$startYear)+$date.Month*100+$date.Day) + $build+=$date.ToString("HHmm") + } + $progressActivity="Publish $moduleName" Write-Progress -Activity $progressActivity - if(($Repository -eq "PSGallery") -and ($moduleName -eq "ISHServer.13")) + if(($Repository -eq "PSGallery") -and ($moduleName -eq "ISHServer.14")) { throw "Not allowed to publish $moduleName to $repository" } @@ -84,15 +94,8 @@ foreach($moduleName in $moduleNamesToPublish) Write-Verbose "Temporary working folder $modulePath is ready" Copy-Item -Path "$PSScriptRoot\..\Source\Modules\ISHServer\*" -Destination $modulePath -Recurse - switch ($moduleName) - { - 'ISHServer.12' { - Remove-Item -Path "$modulePath\ISHServer.13.psm1" -Force - } - 'ISHServer.13' { - Remove-Item -Path "$modulePath\ISHServer.12.psm1" -Force - } - } + Get-ChildItem -Path $modulePath -Filter "ISHServer.*.psm1"|Where-Object -Property Name -Ne "$($moduleName).psm1"|remove-Item -Force + $psm1Path=Join-Path $modulePath "$moduleName.psm1" $metadataPath=Join-Path $modulePath "metadata.ps1" $metadataContent=Get-Content -Path $metadataPath -Raw @@ -160,7 +163,6 @@ foreach($moduleName in $moduleNamesToPublish) $exportedNames=Get-Command -Module $moduleName | Select-Object -ExcludeProperty Name $psm1Name=$moduleName+".psm1" $psd1Path=Join-Path $modulePath "$moduleName.psd1" - $guid="c1e7cbac-9e47-4906-8281-5f16471d7ccd" $possition = "None" $releaseNotes=foreach ($line in $changeLog) { @@ -191,11 +193,11 @@ foreach($moduleName in $moduleNamesToPublish) "CompanyName" = "SDL plc" "Copyright"="SDL plc. All rights reserved." "RootModule"=$psm1Name - "Description"="Prerequisite automation module for SDL Knowledge Center Content Manager 12.0.* (LiveContent Architect, Trisoft InfoShare)" + "Description"="" "ModuleVersion"=$sourceVersion "Path"=$psd1Path - "LicenseUri"='https://github.com/Sarafian/ISHServer/blob/master/LICENSE' - "ProjectUri"= 'https://github.com/Sarafian/ISHServer/' + "LicenseUri"='https://github.com/sdl/ISHServer/blob/master/LICENSE' + "ProjectUri"= 'https://github.com/sdl/ISHServer/' "ReleaseNotes"= $releaseNotes -join [System.Environment]::NewLine "CmdletsToExport" = $exportedNames "FunctionsToExport" = $exportedNames @@ -212,6 +214,11 @@ foreach($moduleName in $moduleNamesToPublish) $hash.Guid="c73125ea-0914-4a1c-958b-05eccd6c2c29" break } + 'ISHServer.14' { + $hash.Description="Prerequisite automation module for SDL Knowledge Center Content Manager 14.0.* (LiveContent Architect, Trisoft InfoShare)" + $hash.Guid="05077a18-b95e-458c-9adc-5ad7d95aed5d" + break + } } New-ModuleManifest @hash diff --git a/CHANGELOG.md b/CHANGELOG.md index f42eea5..2574cd9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,10 +4,14 @@ Issues: - GH-32: Set-ISHUserLocal throws error "net.exe : The user name could not be found." when the password has character " - GH-31: Set-ISHUserLocal cannot work with passwords longer than 14 characters - GH-34: Rename Get-ISHCOMPlus to Get-ISHServerCOMPlus +- GH-42: Make ContentManager2018 the primary artifact In detail: - Renamed `Get-ISHCOMPlus` to `Get-ISHServerCOMPlus` +Remarks: +- Moved links from https://github.com/Sarafian to https://github.com/sdl . + **1.5** Issues: diff --git a/README.md b/README.md index 7a8e06b..b626fab 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,15 @@ # ISHServer A PowerShell module to help automate installation of prerequisites for **Knowledge Center Content Manager**. -# ISHServer.12 +# Available ISHServer modules -[ISHServer.12**](https://www.powershellgallery.com/packages/ISHServer.12/) is the specific module matching the prerequisite requirements of the **Knowledge Center 2016** release. +## ISHServer.13 + +[ISHServer.13**](https://www.powershellgallery.com/packages/ISHServer.13/) is the specific module matching the prerequisite requirements of the **Knowledge Center 2018** release. -The module requires elevated privileges for most of its cmdlets. +## ISHServer.12 + +[ISHServer.12**](https://www.powershellgallery.com/packages/ISHServer.12/) is the specific module matching the prerequisite requirements of the **Knowledge Center 2016** release. ## Prerequisite and CD sources @@ -32,23 +36,6 @@ Because of the size of **Knowledge Center Content Manager** prerequisites they a This makes it your responsibility to make them available to the module. To find out which file names are required, execute `Get-ISHPrerequisites -FileNames` and the result should be per Knowledge Center version: -**Knowledge Center 2016 - Content Manager 12 - ISHServer.12** - -```text -jdk-8u60-windows-x64.exe -jre-8u60-windows-x64.exe -javahelp-2_0_05.zip -htmlhelp.zip -V6-2-M9-Windows_X64_64E.exe -V6-2-M9-Windows_X64_64E.exe.iss -V6-2-M9-Windows_X64_64E.exe.vcredist_x64.exe -V6-2-M9-Windows_X64_64E.exe.vcredist_x86.exe -ODTwithODAC121012.zip -ODTwithODAC121012.rsp -MSXML.40SP3.msi -NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe -``` - **Knowledge Center 2018 - Content Manager 13 - ISHServer.13** ```text @@ -66,6 +53,22 @@ NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe ``` +**Knowledge Center 2016 - Content Manager 12 - ISHServer.12** + +```text +jdk-8u60-windows-x64.exe +jre-8u60-windows-x64.exe +javahelp-2_0_05.zip +htmlhelp.zip +V6-2-M9-Windows_X64_64E.exe +V6-2-M9-Windows_X64_64E.exe.iss +V6-2-M9-Windows_X64_64E.exe.vcredist_x64.exe +V6-2-M9-Windows_X64_64E.exe.vcredist_x86.exe +ODTwithODAC121012.zip +ODTwithODAC121012.rsp +MSXML.40SP3.msi +NETFramework2013_4.5_MicrosoftVisualC++Redistributable_(vcredist_x64).exe +``` If you want to manually make the files available to the module then copy them to the location provided by `Get-ISHServerFolderPath`. As an alternative, the `Get-ISHPrerequisites` cmdlet offers the option to download the files will take care of everything. @@ -75,7 +78,7 @@ As an alternative, the `Get-ISHPrerequisites` cmdlet offers the option to downlo Once the files are available on the server, you can start the installation of the prerequisites and their configuration using the rest of the cmdlets. The module is structured in manner that represents the steps described in the product's [documentation](http://docs.sdl.com/LiveContent/web/pub.xql?action=home&pub=SDL%20Knowledge%20Center%20full%20documentation-v2.1.2&lang=en-US). Understanding the prerequisites and how to configure them will be helpful but it is not a requirement. -An example of how to use the sequence the installation and configuration is available in [ISHBootstrap](https://github.com/Sarafian/ISHBootstrap). +An example of how to use the sequence the installation and configuration is available in [ISHBootstrap](https://github.com/sdl/ISHBootstrap). ## CD Management @@ -84,9 +87,9 @@ ISHServer offers two cmdlets to download and expand the ISHCD. **Notice that it - `Expand-ISHCD` will expand the CD. The target path is always `C:\ISHCD\X.0.Z` where `X` is the major version and `Y` the revision. -- For `12.0.1` it's `C:\ISHCD\12.0.1` -- For `12.0.3` it's `C:\ISHCD\12.0.3` -- For `13.0.0` it's `C:\ISHCD\13.0.0` +- For `13.0.*` it's `C:\ISHCD\13.0.0`. +- For `12.0.*` it's `C:\ISHCD\12.0.3`. +- For the internal upcoming `14.0.*` it's `C:\ISHCD\14.0.0`. ## Maintenance @@ -96,23 +99,15 @@ For installation and maintenance reasons, the module offers a couple of general - `Get-ISHNETInfo` returns the available .NET versions on the operating system. - `Get-ISHOSInfo` returns details of the operating system. -# ISHServer.13 +# ISHServer.14 -**ISHServer.13** is the module for the next major release **Knowledge Center Content Manager** and **it's not published** in the PowerShell gallery. -The goal is to reuse as much as possible the scripts developed for **ISHServer.12** but here are a couple of things to keep in mind: +**ISHServer.14** is the module for the next major release **Knowledge Center Content Manager** and **it's not published** in the PowerShell gallery. +The goal is to reuse as much as possible the scripts developed for **ISHServer.13** but here are a couple of things to keep in mind: - When a prerequisite is dropped, then the relative cmdlets will be also dropped. - When a prerequisite version is changed, then the cmdlet's implementation will be adjusted to match the correct version of the prerequisite. -Current differences of **ISHServer.13** with **ISHServer.12**: - -- **Java** runtime and development kit for (64-bit) 1.8.0_144. -- **MSDTC** is removed form the prerequisites list, therefore the `Initialize-ISHMSDTCSettings` and `Initialize-ISHMSDTCTransactionTimeout` cmdlets are removed. -- **MSXML** is removed form the prerequisites list, therefore the `Install-ISHToolMSXML4` cmdlet is removed. -- **Microsoft .NET Framework 4.6.1** is required instead of **Microsoft .NET Framework 4.5**. -- **Visual C++ Redistributable for Visual Studio 2015** is required instead of **Visual C++ Redistributable for Visual Studio 2013**. -- **Oracle Client - ODAC 12c2 Release 1 (12.2.0.1.0)** is required instead of **Oracle Client - ODAC 12c Release 4**. -- **Antenna House V6.5**. +No current differences of **ISHServer.14** with **ISHServer.13**. # Acknowledgements diff --git a/Source/Modules/ISHServer/ISHServer.14.psm1 b/Source/Modules/ISHServer/ISHServer.14.psm1 new file mode 100644 index 0000000..2740d70 --- /dev/null +++ b/Source/Modules/ISHServer/ISHServer.14.psm1 @@ -0,0 +1,101 @@ +<# +# Copyright (c) 2014 All Rights Reserved by the SDL Group. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#> + +Set-Variable -Name "ISHServer:JDK" -Value "jdk-8u144-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JRE" -Value "jre-8u144-windows-x64.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:JavaHelp" -Value "javahelp-2_0_05.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:HtmlHelp" -Value "htmlhelp.zip" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouse" -Value "V6-5-R1-Windows_X64_64E.exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:AntennaHouseInstallPath" -Value "Antenna House\AHFormatterV65\" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:Oracle" -Value "ODTwithODAC122010" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:MicrosoftVisualCPlusPlusRedistributable" -Value "NETFramework2015_4.6_MicrosoftVisualC++Redistributable_(vc_redist.x64).exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:NETFramework" -Value "NETFramework2015_4.6.1.xxxxx_(NDP461-KB3102436-x86-x64-AllOS-ENU).exe" -Scope "Script" -Option Constant +Set-Variable -Name "ISHServer:VisualBasicRuntime" -Value "vbrun60sp6.exe" -Scope "Script" -Option Constant +#Set-Variable -Name "ISHServer:MSXML" -Value "MSXML.40SP3.msi" -Scope "Script" -Option Constant + +$exportNames=@( + #region Helpers + "Get-ISHOSInfo" + "Get-ISHNETInfo" + "Test-ISHServerCompliance" + "Get-ISHServerFolderPath" + "Grant-ISHUserLogOnAsService" + "Get-ISHServerCOMPlus" + "Get-ISHNormalizedCredential" + #endregion + + #region Ports + "Set-ISHFirewallHTTPS" + "Set-ISHFirewallNETBIOS" + "Set-ISHFirewallOracle" + "Set-ISHFirewallHTTPS" + "Set-ISHFirewallSMTP" + "Set-ISHFirewallSQLServer" + #endregion + + + #region Global + "Get-ISHServerFolderPath" + "Get-ISHPrerequisites" + "Initialize-ISHLocale" + "Initialize-ISHIIS" + "Initialize-ISHUserLocalProfile" + "Set-ISHUserLocal" + "Set-ISHUserAdministrator" + "Initialize-ISHRegistry" + #endregion + + #region Install + "Install-ISHToolDotNET" + "Install-ISHToolVisualCPP" + "Install-ISHToolJAVA" + "Install-ISHToolJavaHelp" + "Install-ISHToolHtmlHelp" + "Install-ISHToolAntennaHouse" + "Install-ISHToolOracleODAC" + "Install-ISHWindowsFeature" + "Install-ISHWindowsFeatureIISWinAuth" + "Install-ISHVisualBasicRuntime" + #endregion + + #region Regional settings + "Initialize-ISHRegional" + "Initialize-ISHRegionalDefault" + #endregion + + #region License + "Set-ISHToolAntennaHouseLicense" + #endregion + + #region CD + "Expand-ISHCD" + "Get-ISHCD" + #endregion +) + +$privateNames=@( + "Get-ISHFTPItem" + "Get-ISHS3Object" + "Get-ISHAzureFileObject" + "Get-ISHAzureBlobObject" + "Test-RunningAsElevated" +) + +$privateNames | ForEach-Object {. $PSScriptRoot\Private\$_.ps1 } +$exportNames | ForEach-Object {. $PSScriptRoot\$_.ps1 } + +$exportedMemberNames=$exportNames -replace "\.ISH[0-9]+","" +Export-ModuleMember $exportedMemberNames From 18605ab5ef84d526dbcfb82bf66afbda26847f2f Mon Sep 17 00:00:00 2001 From: Alex Sarafian Date: Fri, 1 Dec 2017 11:36:44 +0100 Subject: [PATCH 6/6] Bump version to 1.6 --- Source/Modules/ISHServer/metadata.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Modules/ISHServer/metadata.ps1 b/Source/Modules/ISHServer/metadata.ps1 index fb8387d..2b0a68a 100644 --- a/Source/Modules/ISHServer/metadata.ps1 +++ b/Source/Modules/ISHServer/metadata.ps1 @@ -15,5 +15,5 @@ #> <#PSScriptInfo -.VERSION 1.5 +.VERSION 1.6 #>