fenton-project / fenton_integration_test

A Chef cookbook with test-kitchen to validate fenton_server, fenton_api and a server setup to use SSH CA certificates work together

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

fenton_integration_test

A testing framework to validate ssh certificate are properly handled in the Fenton Project.

Usage

Build/Converge Servers

kitchen converge server
kitchen converge shell
kitchen converge machine-ubuntu-1404 # choose 1 operating system per test run

Test SSH

Run inspec to validate Fenton CLI on the shell node will successfully SSH into the machine node

kitchen verify shell

Debug the fenton server logs

kitchen exec server -c "tail -F /fenton_server/log/server.log"

Test them all

function run_command {
  "$@"
  local command_status=$?
  
  if [ $command_status -ne 0 ]; then
    exit $command_status
  fi
  
  return $command_status
}

kitchen converge server
kitchen converge shell

for machine in `kitchen list | grep machine- | awk '{print $1}'`
do
  run_command kitchen converge $machine
  run_command kitchen verify shell
  run_command kitchen destroy $machine
done

About

A Chef cookbook with test-kitchen to validate fenton_server, fenton_api and a server setup to use SSH CA certificates work together


Languages

Language:Ruby 93.3%Language:HTML 6.7%