aboutsummaryrefslogtreecommitdiff
path: root/roles/factorio/tasks/update.yml
blob: 4f4c4d386e6a954c15e3e9d5fef9adc8b62a55cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
---
- name: Stop factorio
  systemd:
    name: factorio.service
    state: stopped
  become: yes

- name: Download factorio
  get_url:
    url: "https://factorio.com/get-download/stable/headless/linux64"
    dest: /opt/factorio/factorio.tar.gz
  become_user: factorio
  become: yes

- name: Unpack factorio
  unarchive:
    src: /opt/factorio/factorio.tar.gz
    dest: /opt/factorio/
    remote_src: yes
  become_user: factorio
  become: yes
  notify:
    - Handle systemd