Skip to content
This repository has been archived by the owner on Mar 30, 2023. It is now read-only.

Commit

Permalink
Fix the copying of the playbooks
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnGarbutt committed Sep 2, 2019
1 parent 342ee2f commit 33fefe7
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions internal/pkg/filesystem_impl/ansible.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,13 @@ func setupAnsible(fsType FSType, internalName string, bricks []datamodel.Brick)
return dir, err
}

cmd = exec.Command("cp", getAnsibleDir("*.yml"), dir)
output, err = cmd.CombinedOutput()
log.Println("copy playbooks", string(output))
if err != nil {
return dir, err
for _, playbook := range []string{"create.yml", "delete.yml", "restore.yml"} {
cmd = exec.Command("cp", getAnsibleDir(playbook), dir)
output, err = cmd.CombinedOutput()
log.Println("copy playbooks", playbook, string(output))
if err != nil {
return dir, err
}
}

cmd = exec.Command("cp", "-r", getAnsibleDir(".venv"), dir)
Expand Down

0 comments on commit 33fefe7

Please sign in to comment.