git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Pfeiffer <coding _ lirion.de> 2022-07-05 11:58:30 +0200
committerHarald Pfeiffer <coding _ lirion.de> 2022-07-05 11:58:30 +0200
commitf33cc920bd9c958106d0baca7b4892947cac0fb2 (patch)
treee378437b2a5c681c13783e4f41350e2367c68a93
parentfe6da3ba9eaff27a6330eb95f1418276170eda45 (diff)
downloaddotfiles-f33cc920bd9c958106d0baca7b4892947cac0fb2.tar.bz2
Do not execute any remote action on localhost
-rw-r--r--distrib.yml49
1 files changed, 25 insertions, 24 deletions
diff --git a/distrib.yml b/distrib.yml
index d5eb816..8c30982 100644
--- a/distrib.yml
+++ b/distrib.yml
@@ -73,30 +73,31 @@
vars:
ansible_python_interpreter: "auto_silent"
tasks:
- - name: "Copy dotfiles.tar.xz to remote"
- copy:
- src: "~/dotfiles.tar.xz"
- dest: "~/dotfiles.tar.xz"
- mode: "0640"
- tags:
- - "remote"
- - "all"
- - name: "Unpack dotfiles.tar.xz"
- unarchive:
- dest: "~/"
- src: "~/dotfiles.tar.xz"
- remote_src: "yes"
- list_files: "yes"
- tags:
- - "unpack"
- - "all"
- - name: "Remove tarball on remote"
- file:
- path: "~/dotfiles.tar.xz"
- state: "absent"
- tags:
- - "removal"
- - "all"
+ - block:
+ - name: "Copy dotfiles.tar.xz to remote"
+ copy:
+ src: "~/dotfiles.tar.xz"
+ dest: "~/dotfiles.tar.xz"
+ mode: "0640"
+ tags:
+ - "remote"
+ - "all"
+ - name: "Unpack dotfiles.tar.xz"
+ unarchive:
+ dest: "~/"
+ src: "~/dotfiles.tar.xz"
+ remote_src: "yes"
+ list_files: "yes"
+ tags:
+ - "unpack"
+ - "all"
+ - name: "Remove tarball on remote"
+ file:
+ path: "~/dotfiles.tar.xz"
+ state: "absent"
+ tags:
+ - "removal"
+ - "all"
when: inventory_hostname != hostvars['localhost']['ansible_fqdn'] and
inventory_hostname != hostvars['localhost']['ansible_hostname'] and
inventory_hostname != hostvars['localhost']['ansible_hostname'] | lower