Skip to content

Commit dde1bd6

Browse files
authored
Merge pull request #507 from alan-turing-institute/DSG-2019-12-Deployment
Deployment branch for December 2019 DSG
2 parents 7cf3e5e + ad25b76 commit dde1bd6

138 files changed

Lines changed: 5816 additions & 7020 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

new_dsg_environment/azure-runbooks/dsg_build_instructions.md

Lines changed: 21 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
- #### Download a client VPN certificate for the Safe Haven Management VNet
1717

18-
- Navigate to the Safe Haven Management (SHM) KeyVault in the Safe Haven Management subscription via `Resource Groups -> RG_DSG_SECRETS -> dsg-management-<shm-id>`, where `<shm-id>` is `prod` for the production SHM environment and `test` for the test SHM environment.
18+
- Navigate to the Safe Haven Management (SHM) KeyVault in the Safe Haven Management subscription via `Resource Groups -> RG_DSG_SECRETS -> kv-shm-<shm-id>`.
1919

2020
- Once there open the "Certificates" page under the "Settings" section in the left hand sidebar.
2121

@@ -33,7 +33,7 @@
3333

3434
- Click the "Download VPN client" link at the top of the page to get the root certificate (VpnServerRoot.cer) and VPN configuration file (VpnSettings.xml), then follow the [VPN set up instructions](https://docs.microsoft.com/en-us/azure/vpn-gateway/point-to-site-vpn-client-configuration-azure-cert) using the Windows or Mac sections as appropriate.
3535

36-
- On Windows you may get a "|Windows protected your PC" pop up. If so, click `More info -> Run anyway`
36+
- On Windows you may get a "Windows protected your PC" pop up. If so, click `More info -> Run anyway`
3737

3838
- On Windows do not rename the vpn client as this will break it
3939

@@ -123,7 +123,7 @@ The full configuration details for a new DSG are generated by defining a few "co
123123

124124
### Core SHM configuration properties
125125
The core properties for the relevant pre-existing Safe Haven Management (SHM) environment must be present in the `dsg_configs/core` folder.
126-
The following core SHM properties must be defined in a JSON file named `shm_<shm-id>_core_config.json`. See `shm_testc_core_config.json` for an example.
126+
The following core SHM properties must be defined in a JSON file named `shm_<shm-id>_core_config.json`.
127127

128128
**NOTE:** The `netbiosName` fields must have a maximum length of 15 characters.
129129

@@ -133,27 +133,16 @@ The following core SHM properties must be defined in a JSON file named `shm_<shm
133133
"computeVmImageSubscriptionName": "Azure Subscription name for compute VM",
134134
"domain": "The fully qualified domain name for the management environment",
135135
"netbiosname": "A short name to use as the local name for the domain. This must be 15 characters or less",
136-
"shId": "A short ID to identify the management environment",
137-
"name": "Deployment name",
136+
"shmId": "A short ID to identify the management environment",
137+
"name": "Safe Haven deployment name",
138138
"organisation": {
139139
"name": "Organisation name",
140140
"townCity": "Location",
141141
"stateCountyRegion": "Location",
142142
"countryCode": "e.g. GB"
143143
},
144144
"location": "The Azure location in which the management environment VMs are deployed",
145-
"ipPrefix": "The three octet IP address prefix for the Class A range used by the management environment. Use 10.250.0",
146-
"dcVmName": "The VM name of the managment environment Active Directory Domain Controller",
147-
"dcHostname": "The hostname of the managment environment Active Directory Domain Controller",
148-
"dcRgName": "The name of the Resource Group containing the managment environment Active Directory Domain Controller",
149-
"vnetRgName":"The name of the Resource Group containing the Virtual Network for the management environment",
150-
"npsIpLastOctet": "248",
151-
"npsVmName": "The VM Name of the NPS VM",
152-
"npsRgName": "The resources group containing the NPS VM",
153-
"npsIp": "The IP address of the management environment NPS server",
154-
"vnetName":"The name of the Virtual Network for the management environment",
155-
"artifactStorageAccount": "The name of the storage account that will contain installation artifacts for new DSGs within the mangement environment. Must be GLOBALLY unique within Azure. We suggest the format `dsg<shm-id>artifacts`",
156-
"keyVaultName": "The name of the KeyVault that will contain secrets mangement environment. Must be GLOBALLY unique within Azure. We suggest the format `dsg-management-<shm-id>`"
145+
"ipPrefix": "The three octet IP address prefix for the Class A range used by the management environment. Use 10.0.0 for this unless you have a good reason to use another prefix."
157146
}
158147
```
159148

@@ -217,6 +206,8 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
217206

218207
- Prepare SHM by running `./Prepare_SHM.ps1`, entering the DSG ID when prompted
219208

209+
- This step also creates a DSG KeyVault in the DSG subscription in `Resource Groups -> RG_DSG_SECRETS -> kv-shm-<shm-id>-dsg<dsg-id>`. Additional deployment steps will add secrets to this KeyVault and you will need to access some of these for some of the manual configiration steps later.
210+
220211
## 2. Deploy Virtual Network
221212

222213
### Create the virtual network
@@ -235,7 +226,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
235226

236227
### Set up a VPN connection to the DSG
237228

238-
- In the **DSG subscription** open `Resource Groups -> RG_DSG_VNET -> DSG_VNET1_GW`
229+
- In the **DSG subscription** open `Resource Groups -> RG_DSG_VNET -> VNET_DSG<dsg-id>_GW`
239230

240231
- Select "**Point to Site Configuration**" from the left-hand navigation
241232

@@ -277,7 +268,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
277268

278269
- Connect to the new Domain controller via Remote Desktop client over the DSG VPN connection at the IP address `<dsg-identity-subnet-prefix>.250` (e.g. 10.250.x.250)
279270

280-
- Login with local admin user `atiadmin` and the password for the DSG DC, which was created and stored in the `dsg<dsg-id>-dc-admin-password` secret in the Safe Haven Management KeyVault by the DC deployment script
271+
- Login with local admin user and password for the DSG DC, which were created and stored in the `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in the DSG KeyVault by the DC deployment script
281272

282273
- From the "Server Management" application, select `Tools -> Group Policy Management`
283274

@@ -331,7 +322,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
331322

332323
- Connect to the **SHM Domain Controller** via Remote Desktop client over the VPN connection
333324

334-
- Login with domain user `<shm-domain>\atiadmin` and the SHM DC admin password from the `sh-management-dc-admin-password` secret in the Safe Haven Management KeyVault
325+
- Login with domain user `<shm-domain>\User` and the SHM DC admin password from the `shm-dc-admin-password` secret in the Safe Haven Management KeyVault
335326

336327
- From the "Server Management" application, select `Tools -> Active Directory Domains and Trust`
337328

@@ -349,7 +340,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
349340
| Trust Type: | External Trust |
350341
| Direction of trust: | Two-way |
351342
| Sides of trust: | Both this domain and the specified domain |
352-
| User name and password: | Domain admin user on the DSG domain. Format: `<dsg-domain\Username>. User is "atiadmin ". See DSG DC admin secret in management KeyVault for password. |
343+
| User name and password: | Domain admin user on the DSG domain. Format: <dsg-domain>\Username>. See DSG `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in DSG KeyVault for username and password. |
353344
| Outgoing Trust Authentication Level-Local Domain: | Domain-wide authentication |
354345
| Outgoing Trust Authentication Level-Specified Domain: | Domain-wide authentication |
355346

@@ -395,7 +386,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
395386

396387
- Connect to the **RDS Session Server 1 (RDSSH1)** via Remote Desktop client over the DSG VPN connection
397388

398-
- Login with domain user `<dsg-domain>\atiadmin` and the **DSG DC** admin password from the `dsg<dsg-id>-dc-admin-password` secret from the SHM KeyVault (all DSG Windows servers use the same admin credentials)
389+
- Login with domain user `<dsg-domain>\Username`. See DSG `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in DSG KeyVault for username and password (all DSG Windows servers use the same admin credentials)
399390

400391
- Open `C:\Software\rdssh1-app-server` in Windows explorer
401392

@@ -407,7 +398,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
407398

408399
- Connect to the **RDS Gateway** via Remote Desktop client over the DSG VPN connection
409400

410-
- Login with domain user `<dsg-domain>\atiadmin` and the **DSG DC** admin password from the `dsg<dsg-id>-dc-admin-password` secret from the SHM KeyVault (all DSG Windows servers use the same admin credentials)
401+
- Login with domain user `<dsg-domain>\Username`. See DSG `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in DSG KeyVault for username and password. (all DSG Windows servers use the same admin credentials)
411402

412403
- Open a PowerShell command window with elevated privileges - make sure to use the `Windows PowerShell` application, not the `Windows PowerShell (x86)` application. The required server managment commandlets are not installed on the x86 version.
413404

@@ -455,7 +446,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
455446

456447
- Enter the IP address of the NPS within the management domain (`10.251.0.248`)
457448

458-
- Set the "Shared Secret" to the value of the `dsg-<dsg-id>-nps-secret` in the SHM KeyVault.
449+
- Set the "Shared Secret" to the value of the `dsg-<dsg-id>-nps-secret` in the DSG KeyVault.
459450

460451
![C:\\Users\\ROB\~1.CLA\\AppData\\Local\\Temp\\SNAGHTML2302f1a.PNG](images/media/image23.png)
461452

@@ -523,7 +514,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
523514

524515
- Connect to the **SHM Domain Controller** via Remote Desktop client over the VPN connection
525516

526-
- Login with domain user `<shm-domain>\atiadmin` and the SHM DC admin password from the `sh-management-dc-admin-password` secret in the Safe Haven Management KeyVault
517+
- Login with **SHM** domain user `<shm-domain>\User` See **SHM** `dsg<dsg-id>-dc-admin-username` and `shm-dc-admin-password` secrets in the **SHM** KeyVault for username and password.
527518

528519
- In the "Server Management" app, click `Tools -> Active Directory Users and Computers`
529520

@@ -557,7 +548,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
557548

558549
- Ensure that the SHM NPS server RADIUS Client configuration is using the **private** IP address of the RDS Gateway and **not** its public one.
559550

560-
- Ensure the same shared secret from the `dsg-<dsg-id>-nps-secret` in the SHM KeyVault is used in **both** the SHM NPS server RADIUS Client configuration and the DSG RDS Gateway RD CAP Store configuration (see previous sections for instructions).
551+
- Ensure the same shared secret from the `dsg-<dsg-id>-nps-secret` in the DSG KeyVault is used in **both** the SHM NPS server RADIUS Client configuration and the DSG RDS Gateway RD CAP Store configuration (see previous sections for instructions).
561552

562553
- If you get a "We couldn't connect to the gateway because of an error" message, it's likely that the "Remote RADIUS Server" authentication timeouts have not been increased as described in a previous section. It seems that these are reset everytime the "Central CAP store" shared RADIUS secret is changed.
563554

@@ -569,7 +560,7 @@ Each DSG must be assigned it's own unique IP address space, and it is very impor
569560

570561
- Connect to the **RDS Session Server 2 (RDSSH1)** via Remote Desktop client over the DSG VPN connection
571562

572-
- Login with domain user `<dsg-domain>\atiadmin` and the **DSG DC** admin password from the `dsg<dsg-id>-dc-admin-password` secret from the SHM KeyVault (all DSG Windows servers use the same admin credentials)
563+
- Login with domain user `<dsg-domain>\Username`. See DSG `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in DSG KeyVault for username and password (all DSG Windows servers use the same admin credentials)
573564

574565
- Open `C:\Software\rdssh2-virtual-desktop-server` in Windows explorer
575566

@@ -663,8 +654,8 @@ To deploy a compute VM you will need the following available on the machine you
663654
- Activate boot diagnostics on the VM and click save. You need to stay on that screen until the activation is complete.
664655
- Go back to the VM panel and click on the "Serial console" item near the bottom of the VM menu on the left habnd side of the VM panel.
665656
- If you are not prompted with `login:`, hit enter until the prompt appears
666-
- Enter `atiadmin` for the username
667-
- Enter the password from the `dsgroup<dsg-id>-dsvm-admin-password` secret in the `dsg-mangement-<shm-id>` KeyVault in the `RG_DSG_SECRETS` respource group of the SHM subscription.
657+
- Enter the username from the `dsg<dsg-id>-dsvm-admin-password` secret in the DSG KeyVault.
658+
- Enter the password from the `dsg<dsg-id>-dsvm-admin-password` secret in the DSG KeyVault.
668659
- To validate that our custom `cloud-init.yaml` file has been successfully uploaded, run `sudo cat /var/lib/cloud/instance/user-data.txt`. You should see the contents of the `new_dsg_environment/azure-vms/DSG_configs/cloud-init-compute-vm-DSG-<dsg-id>.yaml` file in the Safe Haven git repository.
669660
- To see the output of our custom `cloud-init.yaml` file, run `sudo tail -n 200 /var/log/cloud-init-output.log` and scroll up.
670661

@@ -704,7 +695,7 @@ To run the smoke tests:
704695

705696
- Connect to the **DSG Dataserver** via Remote Desktop client over the DSG VPN connection. Ensure that the Remote Desktop client configuration shares the Safe Haven repository folder on your local machine with the Dataserver (or you have another way to transfer files between your local machine and the Dataserver VM).
706697

707-
- Login with domain user `<dsg-domain>\atiadmin` and the **DSG DC** admin password from the SHM KeyVault (all DSG Windows servers use the same admin credentials)
698+
- Login with domain user `<dsg-domain>\Username`. See DSG `dsg<dsg-id>-dc-admin-username` and `dsg<dsg-id>-dc-admin-password` secrets in DSG KeyVault for username and password (all DSG Windows servers use the same admin credentials)
708699

709700
- Copy the `package_lists` and `tests` folders from your local `<safe-haven-repository>/new_dsg_environment/azure-vms/` folder to a `dsg_tests` folder on within the `F:\Data` folder on the DSG Dataserver.
710701

new_dsg_environment/azure-vms/configs/mirrors.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ TIER="2"
88
ADMIN_USERNAME="atiadmin"
99
LOCATION="uksouth"
1010
MACHINENAME_BASE="Mirror"
11-
NSG_PREFIX="NSG_SHM_PKG_MIRRORS"
11+
NSG_PREFIX="NSG_SHM_TURING1_PKG_MIRRORS"
1212
SOURCEIMAGE="Canonical:UbuntuServer:18.04-LTS:latest"
1313
SUBNET_PREFIX="SBNT_SHM_PKG_MIRRORS"
14-
VNETNAME_PREFIX="VNET_SHM_PKG_MIRRORS"
14+
VNETNAME_PREFIX="VNET_SHM_TURING1_PKG_MIRRORS"
1515

1616
# Disk sizes
1717
DATADISK_LARGE="8TB"
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE – Sandbox",
3+
"adminSecurityGroupName" : "Safe Haven Production Admins",
4+
"dsgId": "100",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup100.co.uk",
8+
"netbiosName": "DSGROUP100",
9+
"ipPrefix": "10.150.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 101 - Turkcell",
3+
"adminSecurityGroupName" : "Safe Haven Production Admins",
4+
"dsgId": "101",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup101.co.uk",
8+
"netbiosName": "DSGROUP101",
9+
"ipPrefix": "10.158.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 102 - Telus",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "102",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup102.co.uk",
8+
"netbiosName": "DSGROUP102",
9+
"ipPrefix": "10.166.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 103 - STC",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "103",
5+
"shmId": "turing1",
6+
"tier": "3",
7+
"domain": "dsgroup103.co.uk",
8+
"netbiosName": "DSGROUP103",
9+
"ipPrefix": "10.172.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 104 - NATS",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "104",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup104.co.uk",
8+
"netbiosName": "DSGROUP104",
9+
"ipPrefix": "10.180.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE -105 - Roche",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "105",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup105.co.uk",
8+
"netbiosName": "DSGROUP105",
9+
"ipPrefix": "10.188.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 106 - Homeslink",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "106",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup106.co.uk",
8+
"netbiosName": "DSGROUP106",
9+
"ipPrefix": "10.196.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"subscriptionName": "Turing SRE - 107 - Ofstead",
3+
"adminSecurityGroupName": "Safe Haven Production Admins",
4+
"dsgId": "107",
5+
"shmId": "turing1",
6+
"tier": "2",
7+
"domain": "dsgroup107.co.uk",
8+
"netbiosName": "DSGROUP107",
9+
"ipPrefix": "10.204.0",
10+
"rdsAllowedSources": "Internet",
11+
"computeVmImageType": "Ubuntu",
12+
"computeVmImageVersion": "0.1.2019082900"
13+
}

0 commit comments

Comments
 (0)