Wednesday, December 1, 2021

Ansible - Unexpected parameter type in action

If the error "ERROR! unexpected parameter type in action: <class 'ansible.parsing.yaml.objects.AnsibleSequence'>" appears when running a role implies there is issue with the playbook. Mostly the playbook has been written in standalone mode and not as running inside a role. Playbook should not contain task, hosts and other parameters. Just the name of the task and the task parameters. This should fix the issue. For example, a playbook file will look like below.
---
- shell: ls -la
  register: shell_result

- debug:
    var: shell_result.stdout_lines
...
And corresponding role file is:
---
- name: list task role
  hosts: localhost
  user: root
  become: yes
  become_user: root

  roles:
    - ls
...

Friday, January 15, 2021

Running Node.js on iPhone

We have Touch Code Pro with a node server and all that, so a terminal with node.js would not be that hard. And iSH does just that and more.

Thursday, January 14, 2021

Xcode 12.2 Storyboard

If you wonder whether Apple has deprecated Xcode storyboards in 12.2, then no. You might have selected the universal app option when creating the project which makes SwiftUI the default and the only choice. Selecting the App option under the iOS section will bring back Storyboard.