mint.yml 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. - name: "local compile"
  2. hosts: building
  3. tasks:
  4. - name: "install dashboard dependencies"
  5. ansible.builtin.shell:
  6. cmd: yarn install
  7. chdir: "{{ playbook_dir }}/../dashboard"
  8. - name: "build dashboard"
  9. ansible.builtin.shell:
  10. cmd: yarn build
  11. chdir: "{{ playbook_dir }}/../dashboard"
  12. environment:
  13. NODE_OPTIONS: "--max_old_space_size=4096"
  14. PUBLIC_URL: "{{ app_dashboard_base_path }}"
  15. REACT_APP_DEFAULT_LOCALE: "zh-Hans"
  16. REACT_APP_LANGUAGES: "en-US,zh-Hans,zh-Hant"
  17. REACT_APP_ENABLE_LOCAL_TOKEN: "true"
  18. REACT_APP_TOKEN_KEY: "token.20230919"
  19. REACT_APP_DOCUMENTS_SERVER: "{{ app_documents_server }}"
  20. REACT_APP_RPC_SERVER: "{{ app_grpc_web_server }}"
  21. REACT_APP_ASSETS_SERVER: "{{ app_assets_server }}"
  22. REACT_APP_API_SERVER: "https://{{ app_domain }}"
  23. REACT_APP_ICP_CODE: "{{ app_icp_code }}"
  24. REACT_APP_QUESTIONNAIRE_LINK: "{{ app_questionnaire_link }}"
  25. - name: deploy php-fpm servers
  26. hosts:
  27. - php_fpm
  28. roles:
  29. - mint-v2
  30. - name: run db migration
  31. hosts:
  32. - dbm
  33. tasks:
  34. - name: run db-migrate
  35. run_once: true
  36. become: true
  37. ansible.builtin.shell:
  38. cmd: su www-data -pc "php artisan migrate"
  39. chdir: "{{ app_deploy_root }}/htdocs"