lib/kitchen/driver/ec2.rb in kitchen-ec2-2.2.2 vs lib/kitchen/driver/ec2.rb in kitchen-ec2-2.3.0

- old
+ new

@@ -639,11 +639,15 @@ C:\\ProgramData\\Amazon\\EC2-Windows\\Launch\\Scripts\\InitializeDisks.ps1 } Else { $logfile='C:\\Program Files\\Amazon\\Ec2ConfigService\\Logs\\kitchen-ec2.log' - } + } + + # Logfile fail-safe in case the directory does not exist + New-Item $logfile -Force + # Allow script execution Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Force #PS Remoting and & winrm.cmd basic config $enableArgs=@{Force=$true} $command=Get-Command Enable-PSRemoting @@ -748,10 +752,10 @@ debug(" in VPC #{vpc_id || 'none'}") # Set up SG rules. ec2.client.authorize_security_group_ingress( group_id: state[:auto_security_group_id], # Allow SSH and WinRM (both plain and TLS). - ip_permissions: [22, 5985, 5986].map do |port| + ip_permissions: [22, 3389, 5985, 5986].map do |port| { ip_protocol: "tcp", from_port: port, to_port: port, ip_ranges: [{ cidr_ip: "0.0.0.0/0" }],