This role installs and configures PHP Composer.
This role is designed to work with merge "hash_behaviour". Make sure your ansible.cfg contains these settings
[defaults]
hash_behaviour = merge
This role has no dependencies, but you need PHP cli to be available.
This role uses two tags: build and configure
build
- Installs composer.configure
- Configures composer.
Simply install composer.
- name: Install PHP Composer
hosts: sandbox
roles:
- role: sansible.composer
composer:
user: my_application
install_dir: /home/my_application/bin
Install composer and configure github access
- name: Install and Configure PHP Composer
hosts: sandbox
roles:
- role: sansible.composer
composer:
user: my_application
install_dir: /home/my_application/bin
auth:
github:
github.com: qwerty654321
http:
repo.example.org:
username: username
password: secretP4ssword