https://www.gravatar.com/avatar/8e05324b750f01637307ba45c474a47d?s=240&d=mp

James Apple

software without the soft skills

Braindump: Ansible

Run arbitrary commands ansible-doc ping ansible localhost -m ping ansible localhost -m shell -a "cat ./a-file" ansible localhost -m uri -a 'url=https://google.com return_content=true' ansible all --list-hosts Simple localhost playbook ansible-playbook -e "my_var=123 other_var=345" ./deploy.yaml 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 ---- hosts:localhostvars_prompt:- name:'env'prompt: 'Environment:nonprod | prod'private:novars_files:- './vars/env-all.yaml'- './vars/env-{{ env }}-{{ instance }}.yaml'vars:tasks:- name:'Assume to k8s'command:|aws eks update-kubeconfig --region ap-southeast-2 --profile {{ eks_profile }} --name {{ eks_cluster }}- name:'Deploy {{ namespace }} ingress'command:|kubectl --namespace={{ namespace }} apply -f -args:stdin:'{{ lookup("template", ".