---
# file: roles/rust/tasks/main.yml

- name: "download rustup-init"
  get_url:
    url: https://static.rust-lang.org/rustup/dist/x86_64-unknown-linux-gnu/rustup-init
    dest: /dev/shm/rustup-init
    mode: 0755
  tags: rust

- name: "install rust"
  command: "/dev/shm/rustup-init -q -y --default-toolchain stable"
  tags: rust

- name: "remove /dev/shm/rustup-init"
  file:
    path: "/dev/shm/rustup-init"
    state: absent
  tags: tags
