Add rvm1_user so you can set the rvm directory owner
This commit is contained in:
@@ -40,6 +40,9 @@ rvm1_install_path: '/usr/local/lib/rvm'
|
|||||||
# make sure you ADD the --user-install flag below
|
# make sure you ADD the --user-install flag below
|
||||||
rvm1_install_flags: '--auto-dotfiles'
|
rvm1_install_flags: '--auto-dotfiles'
|
||||||
|
|
||||||
|
# Set the owner for the rvm directory
|
||||||
|
rvm1_user: 'root'
|
||||||
|
|
||||||
# URL for the latest installer script
|
# URL for the latest installer script
|
||||||
rvm1_rvm_latest_installer: 'https://raw.githubusercontent.com/wayneeseguin/rvm/master/binscripts/rvm-installer'
|
rvm1_rvm_latest_installer: 'https://raw.githubusercontent.com/wayneeseguin/rvm/master/binscripts/rvm-installer'
|
||||||
|
|
||||||
@@ -100,6 +103,12 @@ rvm1_install_flags: '--auto-dotfiles --user-install'
|
|||||||
rvm1_install_path: '/home/someuser/.rvm'
|
rvm1_install_path: '/home/someuser/.rvm'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### A quick note about `rvm1_user`
|
||||||
|
|
||||||
|
In some cases you may want the rvm folder and its files to be owned by a specific
|
||||||
|
user instead of root. Simply set `rvm1_user: 'foo'` and when ruby gets installed
|
||||||
|
it will ensure that `foo` owns the rvm directory.
|
||||||
|
|
||||||
## Upgrading and removing old versions of ruby
|
## Upgrading and removing old versions of ruby
|
||||||
|
|
||||||
A common work flow for upgrading your ruby version would be:
|
A common work flow for upgrading your ruby version would be:
|
||||||
|
|||||||
@@ -15,6 +15,9 @@ rvm1_install_path: '/usr/local/lib/rvm'
|
|||||||
# make sure you ADD the --user-install flag below
|
# make sure you ADD the --user-install flag below
|
||||||
rvm1_install_flags: '--auto-dotfiles'
|
rvm1_install_flags: '--auto-dotfiles'
|
||||||
|
|
||||||
|
# Set the owner for the rvm directory
|
||||||
|
rvm1_user: 'root'
|
||||||
|
|
||||||
# URL for the latest installer script
|
# URL for the latest installer script
|
||||||
rvm1_rvm_latest_installer: 'https://raw.githubusercontent.com/wayneeseguin/rvm/master/binscripts/rvm-installer'
|
rvm1_rvm_latest_installer: 'https://raw.githubusercontent.com/wayneeseguin/rvm/master/binscripts/rvm-installer'
|
||||||
|
|
||||||
|
|||||||
@@ -12,6 +12,7 @@
|
|||||||
command: '{{ rvm1_rvm }} install {{ item.item }}'
|
command: '{{ rvm1_rvm }} install {{ item.item }}'
|
||||||
when: rvm1_rubies and item.rc != 0
|
when: rvm1_rubies and item.rc != 0
|
||||||
with_items: detect_rubies.results
|
with_items: detect_rubies.results
|
||||||
|
sudo_user: '{{ rvm1_user }}'
|
||||||
|
|
||||||
- name: Detect default ruby version
|
- name: Detect default ruby version
|
||||||
command: '{{ rvm1_rvm }} alias list default'
|
command: '{{ rvm1_rvm }} alias list default'
|
||||||
|
|||||||
Reference in New Issue
Block a user