Advertisement
Guest User

Untitled

a guest
May 31st, 2016
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. Add module to your Drupal installation via ZenCI deploy
  2.  
  3. So you have your own repo with module code
  4.  
  5. 1. You need to create a file to install module after deploy:
  6. ```
  7. #!/bin/sh
  8.  
  9. echo "Installing module to $DOCROOT"
  10.  
  11. # Create modules dir.
  12. mkdir -p $DOCROOT/sites/all/modules
  13. cd $DOCROOT/sites/all/modules
  14.  
  15. #link module folder
  16. ln -s $ZENCI_DEPLOY_DIR ./$ZENCI_REPO_NAME
  17.  
  18. #return to website root
  19. cd $DOCROOT
  20.  
  21. #enable module
  22. drush en -y $MODULENAME
  23. ```
  24.  
  25. If your module name is the same as repo name, you can replace $MODULENAME with $ZENCI_REPO_NAME
  26.  
  27. 2. Enable Zen.ci for this repo
  28. 3. set .ssh/authorized_keys with 600 permission and write there a public_key for this repo.
  29. 4. Create .zenci.yml file
  30. ```
  31. deploy:
  32. master:
  33. server: p1.zen.ci
  34. username: zen
  35. dir: '{home}/github/{repo_owner}/{repo_name}/{branch}'
  36. env_vars:
  37. docroot: '{home}/domains/zen.ci'
  38. domain: zen.ci
  39. modulename: billing_client
  40. scripts:
  41. init: '{home}/scripts/module_init.sh'
  42. ```
  43. When you commit .zenci.yml - module will be uploaded and enabled.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement