Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kitchen-inspec fails to configure HTTPS winrm for inspec #152

Closed
joekhoobyar opened this issue Dec 3, 2017 · 0 comments · Fixed by #153
Closed

kitchen-inspec fails to configure HTTPS winrm for inspec #152

joekhoobyar opened this issue Dec 3, 2017 · 0 comments · Fixed by #153

Comments

@joekhoobyar
Copy link
Contributor

I have a working configuration for test-kitchen that uses self-signed HTTPS winrm as a transport:

---
driver:
  name: ec2
  region: <%= ENV['AWS_REGION'] %>
  subnet_id: <%= ENV['SUBNET_ID'] %>
  security_group_ids: ["<%= ENV['SG_ID'] %>"]
  aws_ssh_key_id: <%= ENV['SSH_KEY'] %>
  iam_profile_name: <%= ENV['IAM_PROFILE'] %>
  associate_public_ip: <%= ENV['PUBLIC_IP'] %>
  ssl: true
  self_signed: true
  tags:
    Owner: <%= ENV['TAGS_OWNER'] %>
    Environment: <%= ENV['TAGS_ENVIRONMENT'] %>
    Project: <%= ENV['TAGS_PROJECT'] %>
    ExpirationDate: "<%= ENV['TAGS_EXPIRY'] %>"

transport:
  name: winrm
  username: Administrator
  ssh_key: <%= ENV['SSH_KEY_PATH'] %>
  port: 5986
  winrm_transport: ssl
  ssl: true
  self_signed: true

verifier:
  name: inspec

....
OMITTED FOR BREVITY
....

However, when kitchen-inspec prepares the winrm runner_options, it fails to pass the necessary information to allow inspec to utilize the HTTPS transport.

At a minimum, kitchen-inspec should apply the same defaults as test-kitchen, when encountering winrm_transport: ssl. This means that it should configure 'ssl' => true, 'self_signed' => true in winrm runner options whenever it detects winrm_transport: ssl.

I will raise a PR that fixes this issue.

arlimus pushed a commit that referenced this issue Dec 5, 2017
Signed-off-by: Joe Khoobyar <joe@khoobyar.name>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant