Skip to content

Commit

Permalink
Don't install buck as root
Browse files Browse the repository at this point in the history
Change-Id: I5b7ab1e16b5295947f625a6ec405534067e0b85e
  • Loading branch information
dpursehouse committed Dec 4, 2015
1 parent 54a06a5 commit 8fa28b2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ Role Variables
| Name | Default | Description |
|------------------------|-----------------------------------|---------------------------------------------|
| buck_repository_url | https://github.com/facebook/buck | URL of buck git repository |
| buck_installation_dir | /opt/buck | Source installation directory |
| buck_installation_dir | ~/buck | Source installation directory |
| buck_revision | master | Revision of buck to check out |
| buck_bin_dir | /usr/local/bin | Directory in which to symlink the binaries |
| buck_bin_dir | ~/bin | Directory in which to symlink the binaries |

Example Playbook
----------------
Expand Down
4 changes: 2 additions & 2 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
# default vars file for Buck

buck_repository_url: https://github.com/facebook/buck
buck_installation_dir: /opt/buck
buck_installation_dir: ~/buck
buck_revision: master
buck_bin_dir: /usr/local/bin/
buck_bin_dir: ~/bin
13 changes: 6 additions & 7 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
- name: Create Buck installation directory
file: >
path={{ buck_installation_dir }}
owner=root
group=root
mode=0755
state=directory
tags: buck

Expand All @@ -23,21 +20,23 @@
chdir={{ buck_installation_dir }}
tags: buck

- name: Create Buck bin directory
file: >
path={{ buck_bin_dir }}
state=directory
tags: buck

- name: Create buck symlink
file: >
src={{ buck_installation_dir }}/bin/buck
dest={{ buck_bin_dir }}/buck
owner=root
group=root
state=link
tags: buck

- name: Create buckd symlink
file: >
src={{ buck_installation_dir }}/bin/buckd
dest={{ buck_bin_dir }}/buckd
owner=root
group=root
state=link
tags: buck

0 comments on commit 8fa28b2

Please sign in to comment.