I have configured CPanel with GitHub repository, but I can not write my .cpanel.yml file properly, because there is no execution when I try to deploy HEAD commit. Here it is my .yml:
---
deployment:
tasks:
- export DEPLOYPATH=/home/tita8rfx/public_html/try/protected
- /bin/cp -r components $DEPLOYPATH
- /bin/cp -r controllers $DEPLOYPATH
- export DEPLOYPATH=/home/tita8rfx/public_html/try/assets
- /bin/cp style.css $DEPLOYPATH
- /bin/cp app.js $DEPLOYPATH
- export DEPLOYPATH=/home/tita8rfx/public_html/try/protected/views
- /bin/cp -r app $DEPLOYPATH
I also have tried:
---
deployment:
tasks:
- export DEPLOYPATH=/home/tita8rfx/public_html/try
- /bin/cp -r /protected/components $DEPLOYPATH
- /bin/cp -r /protected/controllers $DEPLOYPATH
- /bin/cp /assets/style.css $DEPLOYPATH
- /bin/cp /assets/app.js $DEPLOYPATH
- /bin/cp -r /protected/views/app $DEPLOYPATH
What I want this code to do is to modify the following folders:
and the following files:
But there is no execution or error and I cannot get what the problem is.
I guess I have found my problem. Here it is the solution. I had to be more adverbial in the paths from which the updated data should be get.
---
deployment:
tasks:
- export DEPLOYPATH=/home/tita8rfx/public_html/titanbg-hs.com/protected
- /bin/cp -r /home/tita8rfx/repositories/hsapp/protected/components $DEPLOYPATH
- /bin/cp -r /home/tita8rfx/repositories/hsapp/protected/controllers $DEPLOYPATH
- /bin/cp -r /home/tita8rfx/repositories/hsapp/protected/models $DEPLOYPATH
- export DEPLOYPATH=/home/tita8rfx/public_html/titanbg-hs.com/assets
- /bin/cp /home/tita8rfx/repositories/hsapp/assets/style.css $DEPLOYPATH
- /bin/cp /home/tita8rfx/repositories/hsapp/assets/app.js $DEPLOYPATH
- export DEPLOYPATH=/home/tita8rfx/public_html/titanbg-hs.com/protected/views
- /bin/cp -r /home/tita8rfx/repositories/hsapp/protected/views/app $DEPLOYPATH
- /bin/cp -r /home/tita8rfx/repositories/hsapp/protected/views/tpl $DEPLOYPATH
I hope this will help someone with the same problem as mine.