Skip to content
Ricky
English

Search

Searching… No matching pages. Matching pages are listed below. Search is unavailable. Please try again.

Ansible

All posts

Windows SSH Setup Install OpenSSH for Windows The default shell is cmd. The docs say to change the ansible_shell_type variable if needed. This should be set as a host variable in inventory: ansible_shell_type, …

Convert Command Output to an Image --- - name: Capture command output and convert to image hosts: all tasks: - name: Display content of /etc/redhat-release shell: cat /etc/redhat-release register: …

1 minute

LVM - lvg and lvol volume group - name: 在 /dev/sda1 跟 /dev/sdb1 之上建立 volume group,其 extend size 設置為 32MB community.general.lvg: vg: vg.services pvs: /dev/sda1,/dev/sdb1 pesize: 32 local volume - name: 建立一個大小為 …

What to Do With Long Strings in YAML? YAML already defines this. In this case, there are four methods: |: Newlines under it are preserved as newlines, and the last line ends with a newline. >: Newlines under …

Convert a List to a List of Dicts list my_users: - aaa - bbb - ccc dict my_users: - Name: aaa - Name: bbb - Name: ccc playbook - name: Transform data vars: orig_users: - aaa - bbb - ccc my_users: [] set_fact: …

1 minute

[Community] Cisco UCS CIMC series Ansible - configure Cisco UCS CIMC time zone Ansible - configure Cisco UCS CIMC DNS and disable IPv6 Ansible - configure Cisco UCS CIMC fan policy Ansible - configure Cisco …

ansible.builtin.slurp - read file content --- - name: Use HTTP POST to upload file hosts: all tasks: - name: Read binary file content slurp: path: "/bin/ls" register: bin_file - name: Send HTTP POST Request …

1 minute

# hosts 可以這樣寫 $ ansible 'max-compute[!3:9][0:3][0:3]' -m setup --list-hosts hosts (4): max-compute10 max-compute13 max-compute20 max-compute23 $ ansible 'max-compute[!3:9][0:4][0:4]' -m setup --list-hosts hosts …

1 minute