Skip to main content
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 ...
Ahmed Elsabbahy's 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 ...
hvindin's user avatar
  • 1,744
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 ...
Dave Swersky's user avatar
  • 4,068
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 ...
Evgeny Zislis's user avatar
11 votes
Accepted

What are possible implementations (or examples) of the four-eyes principle?

One of the implementation on code is the Pull Request model (PR) popularized by GitHub. The main reasoning behind is that only a small set of maintainers of the product will be allowed to merge code ...
Tensibai's user avatar
  • 11.4k
9 votes

What are possible implementations (or examples) of the four-eyes principle?

Code Reviews This is about having at least 1 other person look at the code written by somebody, eg to evaluate if it meets some predefined criteria like: Coding standards (indentations, etc). Inline ...
Pierre.Vriens's user avatar
  • 7,205
8 votes
Accepted

How to implement the four-eyes principle for emergency fixes?

In the SCM-world where I'm mostly familiar with, the above scenario is typically addressed by what's called the "abbreviated-approval list procedure. Here is a blueprint of it: Define your business ...
Pierre.Vriens's user avatar
  • 7,205
7 votes

Assertions and constraints

In Ansible: you can use assert or fail module. - name: "Make sure web_sites is dictionary" fail: msg="web_sites should be dictionary" when: web_sites is not dict - name: "cluster_name should ...
Věroš K.'s user avatar
6 votes

What are possible implementations (or examples) of the four-eyes principle?

These are strategies/patterns I can think of: Separation of Duty DevOps, to my view at least, does not means embodying of both dev and ops in a single person. So it is still possible to separate the ...
kenchew's user avatar
  • 341
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 ...
coderanger's user avatar
  • 1,197
6 votes

Where should I put my application configuration?

Who said that properties files and environment variables where mutually exclusive? There is a distinction to be made between "where do I store my app configuration?" And "where does my app source it'...
hvindin's user avatar
  • 1,744
6 votes

Tool for storing per environment configuration

There are many tools that can do something like this, including configuration management tools like Chef, Ansible, or Puppet; and KVS tools like Consul and etcd. You could also integrate it as a build ...
Adrian's user avatar
  • 783
6 votes

How to automate initial server configuration?

What you are trying to accomplish is referred to as infrastructure as code. Which tools you select will depend on where you are operating, and what your business needs are. If you are operating in ...
Wesley Rolnick's user avatar
6 votes
Accepted

Where does k3s store it's "/var/lib/kubelet/config.yaml" file?

/etc/rancher/k3s/config.yaml Note, /etc/rancher/k3s/config.yaml not /etc/rancher/k3s/k3s.yaml! You may have to create the file if it doesn't exist. K3s doesn't have a dedicated kubelet service. It's ...
Evan Carroll's user avatar
  • 2,391
5 votes
Accepted

Bad edit to sudoers file on EC2 instance, how to fix it?

How about user-data ? I believe adding the "#cloud-boothook" allow to force the user-data to run at every restart. #cloud-boothook #!/bin/bash echo 'test' > /home/ec2-user/user-script-output.txt ...
TheAce's user avatar
  • 66
4 votes

Bad edit to sudoers file on EC2 instance, how to fix it?

Generally recovering from this sort of mistake involves editing the boot loader to force a root shell. Since you don't have physical access to the (non-physical) machine, things are a bit different. ...
Xiong Chiamiov's user avatar
4 votes

How to implement a frozen test environment?

TeamCity has a Shared Resources build feature which allows you to define a resource which multiple Build Definitions depend upon it. Build Definitions can either require a Read Lock or a Write Lock, ...
Richard Slater's user avatar
4 votes

Can GitHub's Pull Request model be used for implementing post approvals?

Yes, I do believe so. To explain that I need to lay some groundwork on how I have implemented something similar, I have simplified the model in an attempt to make it as clear as possible. ...
Richard Slater's user avatar
4 votes
Accepted

How can I validate GoCD configuration before applying it

The best solution we found so far, is using the MagicalGoConfigXmlLoader interface from the go source code, as it calls an internal validateCruiseConfig command, that does all validations, or die if ...
SztupY's user avatar
  • 1,577
4 votes

Unable to parse YAML: mapping values are not allowed here

You simply have an incorrect yaml syntax in your workflows jobs list. From what I could very quickly understand on circleCI's documentation, jobs names are accepted as a shorthand if you don't define ...
Zeitounator's user avatar
4 votes
Accepted

Unable to parse YAML: mapping values are not allowed here

Running your config.yml through yamllint, produced the following: 1:1 warning missing document start "---" (document-start) 13:3 error duplication of key "build" in mapping (key-...
Argyle's user avatar
  • 1,026
4 votes
Accepted

No Kubernetes Option in Docker Desktop for Windows

You need to first switch to Edge version by going to the Docker -> Settings -> General tab. Then, you have to enable the kubernetes. Open Docker for Windows settings by accessing your system ...
Samit's user avatar
  • 1,021
3 votes

How to implement the four-eyes principle for emergency fixes?

In the case of off-hours emergency fixes, it's more practical to require less sign-off for changes than your normal procedure. Generally, you can deploy a fix and then do post-approvals the next ...
tayworm's user avatar
  • 660
3 votes
Accepted

How to implement a frozen test environment?

My answer in the context of the question is a very expensive test environment (like mainframes or very large telecom equipment, for example) which are expected to be shared by multiple users for ...
Dan Cornilescu's user avatar
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 ...
Jiri Klouda's user avatar
  • 5,817
3 votes
Accepted

Where is the apache2 filebeat module configured?

After looking a bit further, I found it in the sample called filebeat.full.yml So I added this section to the filebeat.yml Restarted filebeat After running at 100% CPU for minute, Kibana is now ...
scipilot's user avatar
  • 249
3 votes

Kubernetes API Server KUBE_SERVICE_ADDRESSES parameter and Pod Network configuration

https://kubernetes.io/docs/getting-started-guides/centos/centos_manual_config/ # Address range to use for services KUBE_SERVICE_ADDRESSES="--service-cluster-ip-range=10.254.0.0/16"
030's user avatar
  • 13.3k
3 votes

Ensure a line is uncommented in an XML file using ansible

As mentioned in the question and the comments on it, this isn't an area in which Ansible excels. The "best" solution depends a bit on the type of file you're dealing with, and the structure of it. ...
Xiong Chiamiov's user avatar
3 votes
Accepted

What are Pros and Cons of various VCS and CI/CD tools to store, change and deploy configuration snippets of more than 1000 customers in a VCS?

Personally I'd keep them in separate repositories, for clear customer isolation: minimal/no risk of unwanted interference between customers different access control for different customers is ...
Dan Cornilescu's user avatar
3 votes

Where are dunder dictionaries stored in salt?

There are currently 5 dunder dictionaries. They are available at runtime and generally not stored statically. __opts__ - Master or Minion configuration options; stored in configuration files of ...
A. Z.'s user avatar
  • 76

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