...
- On your seed platform, clone the https://github.com/ewcloud/ewc-ecmwf-ai-stacks:
No Format git clone https://github.com/ewcloud/ewc-ecmwf-ai-stacks.git cd ewc-ecmwf-ai-stacks
- If you don't have Ansible installed, you may install it with pip:
or if you prefer to do it in a virtual environment:No Format pip install --user -r requirements.txt
No Format python3 -m venv ansible-venv source ansible-venv/bin/activate pip install -r requirements.txt
- Install the necessary Ansible roles that are going to be used by the playbooks:
No Format ansible-galaxy role install -r requirements.yml roles/
- Define If you don't have it already, define your Ansible inventory. The simplest approach would be to create a file called
inventory
, on the same directory where the plabooks are, containing the fully qualified domain name (FQDN) or IP address used to connect to the instance from your seed platform. If running on the same instance, you may use localhost. - Apply the desired playbook with
ansible-playbook:
You may pass additional options toNo Format ansible-playbook -i inventory playbookname.yml
ansible-playbook
, such as:-v
for verbose output-K
for asking sudo password, if your user does not have password-less sudo privileges on the target instance.-u yourremoteuser
if Ansible needs to use a specific user account to connect to the target instance.-e var=value
for add-hoc customisation of playbook variables to customise your installation.
...
- Make sure the necessary roles are installed. For that you may install them with
ansible-galaxy
either individually or writing your ownrequirements.yml
as shown above. See the official Ansible documentation for more details on how to create such file.No Format ansible-galaxy role install -r requirements.yml roles/
- In your playbook, you can include the roles that you are interested in. For example, here is a playbook that includes 3 4 roles and customises some variables :
See the official Ansible documentation for more information on roles and how to include them.Code Block language yaml --- - hosts: all become: yes vars: conda_prefix: /opt/conda tasks: - name: Mars client ansible.builtin.include_role: name: ewc-ansible-role-mars-client - name: ML basic stack ansible.builtin.include_role: name: ewc-ansible-role-ml-basic - name: Anemoi ansible.builtin.include_role: name: ewc-ansible-role-ecmwf-anemoi
...