--- - name: Minimal check for doc/rpc Sol host hosts: sol_rpc gather_facts: true become: true tasks: - name: Install operator packages (Debian/Ubuntu) ansible.builtin.apt: name: - tmux - mc - git - neovim state: present update_cache: true when: ansible_facts.os_family == "Debian" - name: Ensure root config directories exist ansible.builtin.file: path: "{{ item }}" state: directory owner: root group: root mode: "0755" loop: - /root/.config - /root/.config/mc - /root/.config/nvim - /root/.config/nvim/lua - name: Deploy tmux config (Ctrl+a prefix) ansible.builtin.copy: src: ../files/operator-dotfiles/tmux.conf dest: /root/.tmux.conf owner: root group: root mode: "0644" - name: Deploy Midnight Commander config ansible.builtin.copy: src: "../files/operator-dotfiles/mc/{{ item.src }}" dest: "/root/.config/mc/{{ item.dest }}" owner: root group: root mode: "0644" loop: - { src: "ini", dest: "ini" } - { src: "panels.ini", dest: "panels.ini" } - name: Deploy Neovim config files ansible.builtin.copy: src: "../files/operator-dotfiles/nvim/{{ item.src }}" dest: "/root/.config/nvim/{{ item.dest }}" owner: root group: root mode: "0644" loop: - { src: "init.lua", dest: "init.lua" } - { src: "lazy-lock.json", dest: "lazy-lock.json" } - { src: "lua/options.lua", dest: "lua/options.lua" } - { src: "lua/keymaps.lua", dest: "lua/keymaps.lua" } - { src: "lua/plugins.lua", dest: "lua/plugins.lua" } - { src: "lua/utils.lua", dest: "lua/utils.lua" } - { src: "lua/hazard3_dap.lua", dest: "lua/hazard3_dap.lua" } - name: Validate Ansible transport ansible.builtin.ping: - name: Show host basics ansible.builtin.debug: msg: - "inventory_hostname={{ inventory_hostname }}" - "ansible_host={{ ansible_host | default('n/a') }}" - "hostname={{ ansible_facts['hostname'] | default('n/a') }}" - "os_family={{ ansible_facts['os_family'] | default('n/a') }}" - "kernel={{ ansible_facts['kernel'] | default('n/a') }}" - name: Read uptime ansible.builtin.command: uptime register: uptime_cmd changed_when: false - name: Print uptime ansible.builtin.debug: var: uptime_cmd.stdout