Skip to content
SAF Advanced InSpec Profile Developer CourseSAF Advanced InSpec Profile Developer Course
MITRE InSpec Advanced Profile Developer Course
Course
Resources
Installation
  • Course

    • 1. Course Overview
      • 2. Review the Fundamentals
        • 3. Practice the Fundamentals
          • 4. Tools for Automation
            • 5. Automate Security Testing
              • 6. Explore InSpec Resources
                • 7. Local vs Built-in Resources
                  • 8. Create a Custom Resource - The Git Example
                    • 9. Create a Custom Resource - The Docker Example
                      • 10. Writing Plural Resources
                        • 11. Dissecting Resources
                          • 12. Exercise - Develop your own resources
                            • 13. Add Your Resource to InSpec
                              • 14. Custom Resource Examples from InSpec

                              Installing InSpec on Windows

                              June 7, 2022Less than 1 minute

                              On This Page
                              • Install Ruby
                              • Install InSpec
                                • Option 1 (Download as a package)
                                • Option 2 (Download as a ruby gem)
                              • Download additional required gems
                              • After Install

                              # Install InSpec on Windows

                              # Install Ruby

                              Go to https://rubyinstaller.org/downloads/open in new window and download and install the newest ruby that corresponds with your operating system, it will look like this: Ruby+Devkit x.x.x.

                              • Make sure when installing that the two checkboxes are checked for Add Ruby executables to your PATH and Associate .rb and .rbw files with this Ruby installation
                              • When installation is complete keep the last checkbox marked to perform ridk installation. Once console pops up and prompts you to interact then press enter. When this is complete close the command prompt

                              # Verify Ruby installation

                              • Open powershell
                              • type $ ruby -v, then press enter
                                • if a ruby version is returned then ruby is properly installed

                              # Verify Ruby Devkit installation

                              • Open powershell
                              • type $ gem install json --platform=ruby, then press enter
                                • If the devkit is installed properly then this command will install the RubyGems library JSON gem.

                              # Install InSpec

                              # Option 1 (Download as a package)

                              The InSpec package is available for MacOS, RedHat, Ubuntu and Windows. Download the latest package at InSpec Downloadsopen in new window or install InSpec via script:

                              # Windows
                              . { iwr -useb https://omnitruck.chef.io/install.ps1 } | iex; install -project inspec
                              

                              # Option 2 (Download as a ruby gem)

                              • Open powershell
                              • type $ gem install inspec, then press enter

                              # Download additional required gems

                              • type $ gem install bundler, then press enter
                              • type $ gem install test-kitchen, then press enter

                              # After Install

                              Once InSpec is installed, run $ inspec version to verify that the installation was successful.

                              Edit this pageopen in new window
                              Last update: 6/7/2022, 7:18:57 PM
                              Contributors: Emily Rodriguez
                              Prev
                              Installing InSpec On Your Machine
                              Apache-2.0 | Copyright © 2022 - The MITRE Corporation
                              Copyright © 2022 Aaron Lippold