-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom deployment Script kudu for Linux Azure web app Django #112
Comments
for kuduscript can you try Though I thought Kudu linux uses oryx not kuduscript, right @sanchitmehta? |
@ahmelsayed yes we do use Oryx Builds for python apps. @arislanIOT Are you using a post deployment script/custom deployment script to deploy the app ? |
@ahmelsayed Yes, kudu is using Oryx build for python apps. The above error comes when we use custom deployment, since I'm using linux web app for Django. The task I'm trying to achieve here is two things.
What should I do if I need to run python manage.py migrate.
the issue is that there is no deployment script available for deploy.sh, I found deploy.cmd also I generated one using the $ kuduscript --deployment --python command but this are not working and giving above error when using deploy.cmd generated using the kuduscript. Please note we cannot create bash script like this. |
kudu will not work because Linux will not execute the .deployment file since it is a dotfile. If you need to make a custom deployment you cand use the Oryx configuration in the App Setting of the web app. I deployed a web app using the Git Deployemt process. Then I updated the Deployment ARM template of the web app to have the variable POST_BUILD_COMMAND in the App Setting which will have the path to the script file to execute. |
As I'm aware default kudu build in Linux Azure web app last command is
$ python manage.py collectstatic.
I'm trying to add the command
$python manage.py migrate #This is a necessary command in kudu build.
I generated .deployment and deploy.cmd file using the kuduscript.
Issue.:
when I push the repo, the deployment in azure web app fails and give the following error
Command: deploy.cmd /opt/Kudu/Scripts/starter.sh: line 2: exec: deploy.cmd: not found /opt/Kudu/Scripts/starter.sh: line 2: exec: deploy.cmd: not found\n/opt/Kudu/Scripts/starter.sh deploy.cmd
Please assist to resolve this issue and guide me on this.
The text was updated successfully, but these errors were encountered: