Set up composer.
curl
php
(5.3.2+)
composer_download_url
: [default:'https://getcomposer.org/composer-stable.phar'
]: Download url (e.g.'https://getcomposer.org/composer-1.phar'
)composer_install_dir
: [default:/usr/local/bin
]: Install directorycomposer_self_update
: [default:false
]: Whether or not to executeself-update
on every runcomposer_composer_json_map
: [default:[]
]: A list ofcomposer.json
files to copy, install and or updatecomposer_composer_json_map.{n}.src
: [required]: The local path of the file to copy, can be absolute or relative (e.g.../../../files/composer/.composer/composer.json
)composer_composer_json_map.{n}.dest
: [required]: The remote path of the file to copy (e.g.{{ ansible_env.HOME }}/.composer/composer.json
)composer_composer_json_map.{n}.owner
: [default:root
]: The name of the user that should own the file (optional)composer_composer_json_map.{n}.github_oauth
: A GitHub OAuth access token, to prevent hitting GitHub's rate limits on their API (optional)composer_composer_json_map.{n}.options
: [default:--prefer-dist
]: Additional composer options (optional)composer_composer_json_map.{n}.run_update
: [default:false
]: Whether or not to runupdate
on every run (optional)
None
---
- hosts: all
roles:
- oefenweb.composer
vars:
composer_self_update: true
---
- hosts: all
roles:
- oefenweb.composer
vars:
composer_composer_json_map:
- src: ../../../files/composer/.composer/composer.json
dest: "{{ ansible_env.HOME }}/.composer/composer.json"
github_oauth: 34eabe8ef6ef88999c1e7ed6692b4e7f36119bf9
options: '--prefer-source -vvv'
update: true
MIT
Mischa ter Smitten (based on work of Vinelab)
Are welcome!