Created
July 1, 2021 14:54
-
-
Save nleiva/927c346def12e77b855f549ef1b723db to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: Download Containerlab | |
ansible.builtin.get_url: | |
url: "{{ clab_download_url }}" | |
dest: "/tmp/clab.tar.gz" | |
mode: '0644' | |
- name: Unarchive Containerlab | |
ansible.builtin.unarchive: | |
src: "/tmp/clab.tar.gz" | |
dest: "/tmp" | |
remote_src: yes | |
mode: '0755' | |
- name: Copy Containerlab binary | |
ansible.builtin.copy: | |
src: "/tmp/containerlab" | |
dest: "{{ clab_dir }}/containerlab" | |
remote_src: yes | |
owner: "{{ ansible_user }}" | |
group: "{{ ansible_user }}" | |
mode: a+x | |
- name: Create a symbolic link | |
ansible.builtin.file: | |
src: "{{ clab_dir }}/containerlab" | |
dest: "{{ clab_dir }}/clab" | |
owner: "{{ ansible_user }}" | |
group: "{{ ansible_user }}" | |
state: link |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment