mint.yml 914 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. - name: "local compile"
  2. hosts: localhost
  3. connection: local
  4. tasks:
  5. - name: "install dashboard dependencies"
  6. ansible.builtin.shell:
  7. cmd: yarn install
  8. chdir: "{{ playbook_dir }}/../dashboard"
  9. - name: "build dashboard"
  10. ansible.builtin.shell:
  11. cmd: NODE_OPTIONS="--max_old_space_size=4096" PUBLIC_URL=/pcd yarn build
  12. chdir: "{{ playbook_dir }}/../dashboard"
  13. - hosts:
  14. - www
  15. - php_fpm
  16. tasks:
  17. - name: create deployment folder
  18. become: true
  19. ansible.builtin.file:
  20. path: "{{ app_deploy_root }}"
  21. state: directory
  22. owner: "{{ ansible_user }}"
  23. - name: create logs folder
  24. become: true
  25. ansible.builtin.file:
  26. path: "{{ app_deploy_root }}/logs"
  27. state: directory
  28. owner: "www-data"
  29. group: "www-data"
  30. - hosts: php_fpm
  31. roles:
  32. - laravel
  33. - hosts: www
  34. roles:
  35. - dashboard