---

- name: Checkout SSP source
  git:
    repo: "{{ ssp_repo_url }}"
    dest: "{{ ssp_path }}"
    version: "{{ ssp_repo_version }}"
    accept_hostkey: yes
    force: no
    update: no
  become: yes

- name: Download Composer
  get_url: url=https://getcomposer.org/installer dest={{ ssp_path }}/composer-installer validate_certs=no
  become: yes

- name: Install Composer
  command: php -f {{ ssp_path }}/composer-installer -- --install-dir={{ ssp_path }}
  args:
    creates: "{{ ssp_path }}/composer.phar"
  become: true

- name: Run Composer
  command: php "{{ ssp_path }}/composer.phar" install --no-dev --prefer-dist -o -d "{{ ssp_path }}"
  args:
    creates: "{{ ssp_path }}/vendor/autoload.php"
  become: true

- name: Ensure SSP config dir exists
  file: path={{ ssp_configdir }} state=directory
  become: yes

- name: Ensure SSP logging dir exists
  file: path={{ ssp_loggingdir }} state=directory
  become: yes

- name: Ensure SSP data dir exists
  file: path={{ ssp_datadir }} state=directory
  become: yes

- name: Ensure SSP metadata dir exists
  file: path={{ ssp_metadatadir }} state=directory
  become: yes

---

- name: Checkout SSP source
  git:
    repo: "{{ ssp_repo_url }}"
    dest: "{{ ssp_path }}"
    version: "{{ ssp_repo_version }}"
    accept_hostkey: yes
    force: no
    update: no
  become: yes

- name: Download Composer
  get_url: url=https://getcomposer.org/installer dest={{ ssp_path }}/composer-installer validate_certs=no
  become: yes

- name: Install Composer
  command: php -f {{ ssp_path }}/composer-installer -- --install-dir={{ ssp_path }}
  args:
    creates: "{{ ssp_path }}/composer.phar"
  become: true

- name: Run Composer
  command: php "{{ ssp_path }}/composer.phar" install --no-dev --prefer-dist -o -d "{{ ssp_path }}"
  args:
    creates: "{{ ssp_path }}/vendor/autoload.php"
  become: true

- name: Ensure SSP config dir exists
  file: path={{ ssp_configdir }} state=directory
  become: yes

- name: Ensure SSP logging dir exists
  file: path={{ ssp_loggingdir }} state=directory
  become: yes

- name: Ensure SSP data dir exists
  file: path={{ ssp_datadir }} state=directory
  become: yes

- name: Ensure SSP metadata dir exists
  file: path={{ ssp_metadatadir }} state=directory
  become: yes

- name: Ensure SSP cert dir exists
  file: path={{ ssp_certdir }} state=directory
  become: yes

Add missing task for creating ssp_certdir
Add missing task for creating ssp_certdir
