Ansible Learning

  1. Red Hat now backs Ansible Project (start learning 2018-08-01)
  2. The system is apt to be more reliable and secure : 系统更可靠、更安全。
  3. Talk about provisioning new servers (谈如何配置新服务器), in the context of public cloud such as Amazon EC2, this refers to spinning up a new virtual machine instance (这指的是启动新的虚拟机实例).
  4. Ansible works against multiple systems in your infrastructure at the same time : Ansible可同时处理基础架构中的多个系统
  5. If Ansible modules are the tools in your workshop, playbooks are your instruction manuals, and your inventory of hosts are your raw material: 如果Ansible模块是您工作坊中的工具,那么Playbook就是您的使用说明书,而您的主机清单就是您的原材料
  6. Ansible Facts are information derived from speaking with your remote systems. An example of this might be the IP address of the remote host, or what the operating system is.
  7. Understanding Privilege Escalation : 了解权限提升

  8. ssh -i mymaster.pem [email protected] -o "proxycommand ssh -W %h:%p -i mymaster.pem [email protected]"
    ssh -o ProxyCommand='ssh -W %h:%p your_user@bastion' your_user@target
    Above we tell ssh that when it establishes a connection to private subnet host ie 10.0.2.56.

    To do so using the stdin/stdout of the ProxyCommand as a transport. The ProxyCommand then tells the system to first ssh to our bastion host and open a connection to host %h (hostname supplied to ssh) on port %p (port supplied to ssh).

    sshuttle -r [email protected] 10.1.0.0/16 --dns -e 'ssh -i /home/plcm/.ssh/zhuzhi'
    ssh -i /home/plcm/.ssh/zhuzhi [email protected]

  9. ff

Ansible and Azure

  1. pip3 show azure-mgmt-storage
  2. ModuleNotFoundError: No module named 'keyring.util.escape: pip3 install --upgrade keyrings.alt
  3. An application object therefore has a 1:1 relationship with the software application, and a 1:many relationships with its corresponding service principal object(s).

  4. Azure client_id == Application ID (The service principal will be the application Id);To sign in with a service principal using a password:
    az login --service-principal --username APP_ID --password PASSWORD --tenant TENANT_ID
    az vmss nic list --resource-group plcm-dev-dcos --vmss-name dcos-agentprivate-dev87990-vmss --query [].{ip:ipConfigurations[0].privateIpAddress} -o tsv

  5. dd

Blogs

  1. Lorin's Ansible quick reference pages on GitHub
  2. Ansible Module Index
  3. Ansible Galaxy
  4. Jinja2 templating engine
  5. How to Manage Multistage Environments with Ansible
  6. On-Demand Test Environments With Ansible and Shippable
  7. Delegation, Rolling Updates, and Local Actions

  8. Ansible rolling-update example

Azure Resource Manager Template

  1. ARM Templates
  2. Azure Resource Manager Template 101
  3. Select clouds with the Azure CLI

results matching ""

    No results matching ""