From ebddb8b7d46028539f6300e083ae487f202f6e5d Mon Sep 17 00:00:00 2001 From: ikarulus Date: Mon, 7 Jan 2019 14:56:08 +0100 Subject: [PATCH] add version var --- defaults/main.yml | 2 ++ tasks/main.yml | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/defaults/main.yml b/defaults/main.yml index dc9b083..26b16ca 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,3 +1,5 @@ +gitea_version: "1.0.1" + gitea_app_name: "Gitea" gitea_user: "gitea" gitea_home: "/var/lib/gitea" diff --git a/tasks/main.yml b/tasks/main.yml index efdf105..26a8e43 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -1,11 +1,12 @@ # TODO: variabilize this - name: "Download the binary" get_url: - url: "https://github.com/go-gitea/gitea/releases/download/v1.0.1/gitea-1.0.1-linux-amd64" + url: "https://github.com/go-gitea/gitea/releases/download/v{{ gitea_version }}/gitea-{{ gitea_version }}-linux-{{ 'amd64' if ansible_architecture == 'x86_64' else ansible_architecture }}" dest: /usr/local/bin/gitea owner: root group: root mode: 0755 + force: yes notify: "Restart gitea" - include: create_user.yml