24 votes
Accepted

How to test provisioning and configuration in Ansible setup?

Some options out there.. Testing tools: Sorted by github stars Serverspec - Ruby, most popular tool out there, built on ruby's rspec Goss - YAML, simple, <10MB self-contained binary, extremely ...
user avatar
13 votes

How should I store my environment variables?

I've had two runs at doing environment variables in a scalable way and neither has ended up perfect because, as I've discovered, is a very tricky thing to get right. I'll give a summary of both of my ...
user avatar
  • 1,634
12 votes

How to test provisioning and configuration in Ansible setup?

The two tools I've seen for this are InSpec and ServerSpec. Serverspec is a Ruby-based tool that builds on RSpec. InSpec is inspired by RSpec and ServerSpec. I've used ServerSpec. It's cool, but ...
user avatar
  • 3,943
11 votes

How to test provisioning and configuration in Ansible setup?

When using configuration management tools, such as Ansible, the tool itself would be responsible preventing configuration drift. Once you used Ansible to set a certain configuration, repetitive ...
user avatar
10 votes

How to test VM provisioning script without provisioning

I can see some options: Use Vagrant to create your VMs; it separates the process of creating the VM (including the base OS) and the actual provisioning. It also has some options to run certain ...
user avatar
  • 4,696
6 votes

How to test provisioning and configuration in Ansible setup?

Test Kitchen has a kitchen-ansible provisioner plugin for testing of Ansible code. It isn't as deep as the Chef integration but it does get the job done for most cases. There is also the more recent ...
user avatar
  • 1,197
6 votes

How to test VM provisioning script without provisioning

http://www.vagrantup.com You could use vagrant to deploy VMs on the local laptop. You could also check whether it is possible to split the script in smaller parts so it will not take four hours to ...
user avatar
  • 12.5k
5 votes

Provisioning raspbery pi sdcard

If you're previsioning your raspberry pi SD cards then you would probably be best using something like packer to build the actual image (you can use ansible as the provisioner for packer if you are ...
user avatar
  • 1,634
5 votes

How to test VM provisioning script without provisioning

If testing locally isn't an option, then the most straight forward approach would be to use disk volume snapshots/backups to your advantage. These will still cost $$$, but will save you time in the ...
user avatar
  • 2,973
5 votes
Accepted

difference between packer and matchbox

You may use matchbox on a VM as you do on a baremetal machine, you won't be able to use packer on a baremetal machine ont he other hand as it doesn't handle any PXE boot option. That said, leveraging ...
user avatar
  • 11k
4 votes
Accepted

How do I automate population of known_hosts and authorized_keys?

You have to execute ssh-keyscan. For example to ssh to a host (github.com here ) you have to run below script # Add ssh key to help cloning private github repo ssh-keygen -t rsa -N "" -f secrets/...
user avatar
  • 186
3 votes

Cannot install Ansible

As it says, No such file or directory: 'gpg', so you probably need to install gnupg before adding the PPA repository: apt-get install gnupg
user avatar
  • 706
3 votes

Open source private cloud VM provisioning for container workload

"best suited" is the question. How do you measure this? what are the metrics and why do you choose them? I think you are looking for some kind of "tools combination", earlier tested on production by ...
user avatar
  • 201
3 votes

How should I store my environment variables?

If your environments are per customer, I would suggest in your specific case to have a repository per customer. (In general it is repository per environment.) This repository would have a standard ...
user avatar
  • 5,607
2 votes

Why screen folder in /var/run disappears in Docker container after running Ansible playbook?

Rather than solving the immediate problem you're having, let me suggest an alternative solution to your actual problem: I need screen, so I can use multiple interactive shells in one instance of ...
user avatar
2 votes

Proper way to showcase multi-container web app to customers

You mention that you are demonstrating this for a customer. The first question you should ask yourself (or, more pertinently, the customer) is : what does this customer really want? Why have they ...
user avatar
  • 3,048
2 votes

Other tools to provision virtual machines

Have you considered to use Ansible? You have some resources about using Ansible with VirtualBox and also vagrant
user avatar
  • 248
2 votes

Provisioning meaning

As per my understanding on cloud native infra. Provisioning involves creating resources like VMs/instances, setting up IAM roles and policies, Firewalls, DBs, Load balancers, any clusters like EKS, ...
user avatar
  • 273
1 vote

What are minimum permissions required for an IAM user to provision EC2 instances?

quick answer: - The user will need the permissions to execute the ec2 run-instances command. Explanation on how to do this: First create a policy (not Role) that authorizes the EC2 RunInstances ...
user avatar
  • 148
1 vote

How to Automate VM provisioning and setup using code?

First and foremost, there are several tools for better managing and provisioning of infrastructure such as Terraform. You could create a pipeline to create things automatically as needed (based on ...
user avatar
1 vote
Accepted

Provision and configure Azure VM in private subnet (file, remote-exec, cloud-init, etc.)

Hashicorp recommends using provisioners only as a last resort. They recommend using the Azure VM custom_data method, or cloud-init where available. Ansible would likely be overkill unless you will ...
user avatar
  • 136
1 vote

I'm trying to run `vagrant provision` on PowerShell Window for Ansible playbook

You have 2 viable options to run ansible on windows 10: Install a linux vm with your favorite virtualization tool and run ansible inside that vm. Run ansible from WSL With the first option, you will ...
user avatar
1 vote

How do I bootstrap an alpine image to work with a private repo proxy behind TLS?

It turns out that /etc/ssl/cert.pem is the bundle scanned by apk to verify a repo behind HTTPS, so the following works: wget our.cert.server.com/CA.crt cat CA.crt >> /etc/ssl/cert.pem sed -i 's,...
user avatar
  • 265
1 vote

How to send local files using Terraform Cloud as remote backend?

Currently when you run terraform against a remote workspace in terraform cloud the repository that you are working in gets uploaded. If your key is contained in that repo and is a relative path from ...
user avatar
1 vote

How to send local files using Terraform Cloud as remote backend?

May be a better way to manage private key is using protected variables into the Terraform Cloud. Otherwise you have to save it in repo that is not secure.
user avatar
1 vote

Ansible - Copy multiple files

Following you comment: no I cannot reproduce your problem. Since you did not provide the rest of your files (inventory, etc...) and I cannot guess where is your problem, here is a quick proof by ...
user avatar
1 vote
Accepted

Cannot install Ansible

This is how I managed to test your scenario manually against the php:7.0-apache docker image. Note that this image is based on debian:stretch. In your question, you are following the install guide for ...
user avatar
1 vote

Open source private cloud VM provisioning for container workload

Here's what I've tried: Terraform + libvirt There's unofficial libvirt provider for terraform. It works, but there are a few gotchas: Doesn't support block devices: https://github.com/dmacvicar/...
user avatar
  • 141
1 vote

Other tools to provision virtual machines

I've been wondering if there is any other similar software/tool that just does a one time provision, sets up a static IP/MAC address, and allows for easy start/resume/shutdown when testing/deploying/...
user avatar
  • 4,696
1 vote

Deploying to VSphere with Packer and/or Terraform?

I'm using vagrant with vsphere plugin, starting from a 'base' image already present on vsphere. The new machine is then fully configured (inlcluding middleware) by chef after vsphere customization. ...
user avatar
  • 11k

Only top scored, non community-wiki answers of a minimum length are eligible