- Create a folder at the root of your user home folder
(Example:
C:/Users/uname/
) called.ssh
. - Create the following files if they do not already exist (paths begin from the root of your user home folder):
.ssh/config
<# | |
Steps to update expired Sitecore SSL cert, XConnect site SSL cert, XConnect client cert | |
- Remove existing expired certs and client certs including root certs | |
- Download SIF scripts from https://github.com/Sitecore/Sitecore.HabitatHome.Utilities/ | |
- Use Add-SSLSiteBindingWithCertificate.ps1 to generate SSL cert for Sitecore and XConnect IIS site | |
- Comment everything else in install-xp0.ps1 except the part that generates client cert for xconnect | |
- Use install-xp0.ps1 to generate Client cert for XConnect cert authentication | |
- Ensure root cert, cert and client cert are installed correctly using certlm.msc | |
- Update IIS Site bindings to use new certs |
#------------------------------------------------------------------------------------- | |
# Create Self signed root certificate | |
# -dnsname -DnsName domain.example.com,anothersubdomain.example.com | |
# -Subject "CN=Patti Fuller,OU=UserAccounts,DC=corp,DC=contoso,DC=com" | |
$cert = New-SelfSignedCertificate -Type Custom -KeySpec Signature ` | |
-Subject "CN=P2SRootCert" ` | |
-KeyExportPolicy Exportable ` | |
-HashAlgorithm sha256 -KeyLength 4096 ` | |
-CertStoreLocation "Cert:\CurrentUser\My" ` | |
-KeyUsageProperty Sign ` |
Param( | |
$solrVersion = "6.6.2", | |
$installFolder = "c:\solr", | |
$solrPort = "8983", | |
$solrHost = "solr", | |
$solrSSL = $true, | |
$nssmVersion = "2.24", | |
$JREVersion = "1.8.0_151" | |
) |
#.Synopsis | |
# Generate a self-signed root certificate and then generate an SSL certificate signed by it. | |
#.Description | |
# Generates a self-signed root certificate and an SSL certificate signed by it. | |
# Puts the root public key in a .pem file for adding to PHP's CAcert.pem | |
param( | |
# Used as the CN for the Root certificate | |
$RootName = "NO LIABILITY ACCEPTED - Test Root $(get-date -f "yyyy-MM-dd")", | |
# Used as the CN for the SSL certificate | |
$Subject = "${Env:ComputerName}.${Env:UserDnsDomain}", |
#Requires -Version 3.0 | |
<# | |
.Description | |
Installs Apache Solr | |
.Example | |
.\ServiceInstall.ps1 | |
Installs Apache Solr as the 'solr' service running on port 8983. | |
namespace Analogy | |
{ | |
/// <summary> | |
/// This example shows that a library that needs access to target .NET Standard 1.3 | |
/// can only access APIs available in that .NET Standard. Even though similar the APIs exist on .NET | |
/// Framework 4.5, it implements a version of .NET Standard that isn't compatible with the library. | |
/// </summary>INetCoreApp10 | |
class Example1 | |
{ | |
public void Net45Application(INetFramework45 platform) |
# This script will set up (and install if needed) Apache Solr for a Sitecore instance. | |
# This does NOT configure Sitecore to use Solr, | |
# just the Solr server and cores for Sitecore to connect to once it is set up to use Solr. | |
# So, what does it do? | |
# | |
# * Installs SOLR, if needed, from the Bitnami SOLR stack: https://bitnami.com/stack/solr/installer | |
# * Creates a SOLR config set for the cores to share (shared schema) | |
# * Creates SOLR cores for all Sitecore indexes, including secondary cores to support online reindexing (Switch on Rebuild) |
($PhysicalPath, "c:\inetpub\wwwroot" -ne $null)[0] # null coalescing | |
# Based on the order of operations, this works in following order: | |
# The , operator creates an array of values to be tested. | |
# The -ne operator filters out any items from the array that match the specified value--in this case, null. The result is an array of non-null values in the same order as the array created in Step 1. | |
# [0] is used to select the first element of the filtered array. | |
# Simplifying that: |
# Add a domain user to a remote server local group, if your current user has admin over the remote machine | |
powershell -c ([ADSI]'WinNT://SERVER/Administrators,group').add('WinNT://DOMAIN/USER,user') | |
# Get all local groups on a remote server | |
powershell -c "([ADSI]'WinNT://SERVER,computer').psbase.children | where { $_.psbase.schemaClassName -eq 'group' } | foreach { ($_.name)[0]}" | |
# Find members of the local Administrators group on a remote server | |
powershell -c "$([ADSI]'WinNT://SERVER/Administrators,group').psbase.Invoke('Members') | foreach { $_.GetType().InvokeMember('ADspath', 'GetProperty', $null, $_, $null).Replace('WinNT://', '') }" | |
# Enable the local Administrator account on a remote server |