Get-GoogleCloudParams.ps1
function Set-GoogleCloudParams { <# .Synopsis Sets parameters for other Google Cloud DNS Functions .Description Creates a variable to pass settings to other functions .Example C:\PS>$Google = Set-GoogleCloudParams -Domain yourdomain.com .Notes Name: Set-GoogleCloudParams Author: Jeremy jackson Last Edit: September 17 2020 Keywords: Google DNS .Link .Inputs None .Outputs None #> param ( [string]$Domain ) $GoogeleDNS = [PSCustomObject]@{ Domain = $Domain + "." Project = (Get-GcpProject).projectid Zone = ((Get-GcdManagedZone).where{ $_.DnsName -eq $Domain + "." }).Name } return $GoogeleDNS } |