Go to file
2024-09-09 14:31:45 +05:30
l2-setup Move remote host setup to root README 2024-09-09 14:31:45 +05:30
nitro-bridge-setup Move remote host setup to root README 2024-09-09 14:31:45 +05:30
nitro-contracts-setup Move remote host setup to root README 2024-09-09 14:31:45 +05:30
nitro-nodes-setup Move remote host setup to root README 2024-09-09 14:31:45 +05:30
.gitignore Move remote host setup to root README 2024-09-09 14:31:45 +05:30
example-hosts.ini Move remote host setup to root README 2024-09-09 14:31:45 +05:30
README.md Move remote host setup to root README 2024-09-09 14:31:45 +05:30

testnet-ops

Installation

  • Install Ansible

  • Add location of the directory containing the ansible binary to your PATH

  • Set Locale Encoding to UTF-8

    Ansible requires the locale encoding to be UTF-8. You can either use the LANG prefix when running Ansible commands or set the system-wide locale.

Setup Remote Hosts

To run the playbook on a remote machine, follow these steps:

  • Create a new file named hosts.ini:

    cp example-hosts.ini hosts.ini
    
  • Edit the hosts.ini file to run the playbook on a remote machine

    [<deployment_host>]
    <host_name> ansible_host=<TARGET_IP> ansible_user=<SSH_USER> ansible_ssh_common_args='-o ForwardAgent=yes'
    
    • Replace <deployment_host> with the appropriate host group for the deployment
    • Replace <host_name> with the alias of your choice.
    • Replace <TARGET_IP> with the IP address or hostname of the target machine.
    • Replace <SSH_USER> with the SSH username (e.g., dev, ubuntu).
  • Verify that you are able to connect to the host using the following command

    ansible all -m ping -i hosts.ini -k
    
    # Expected output:
    
    # <host_name> | SUCCESS => {
    #  "ansible_facts": {
    #      "discovered_interpreter_python": "/usr/bin/python3.10"
    #  },
    #  "changed": false,
    #  "ping": "pong"
    # }
    

Playbooks