Azure / functions-action

Enable GitHub developers to deploy to Azure Function Apps using GitHub Actions
MIT License
156 stars 76 forks source link

Function app deployment causes internal server error #167

Closed austinh123123 closed 1 year ago

austinh123123 commented 1 year ago

Hello, I have a python 3.9 function app. I tried to automate its deployment with this action, only to be met with internal server errors or CORS errors after deployment. The curious this is; I can deploy with the VScode extension and all the code runs fine. I'm not sure if I have an error in configuration. For reference, I've added the action yaml, host.json, and function.json (there's only one function). deploy.yaml:

name: Deploy python function app to Azure Function App

on: push: branches:

jobs: build-and-deploy: runs-on: ubuntu-latest environment: dev steps:

host.json: { "version": "2.0", "logging": { "applicationInsights": { "samplingSettings": { "isEnabled": true, "excludedTypes": "Request" } } }, "extensionBundle": { "id": "Microsoft.Azure.Functions.ExtensionBundle", "version": "[3.*, 4.0.0)" } }

function.json: { "scriptFile": "__init__.py", "bindings": [ { "authLevel": "anonymous", "type": "httpTrigger", "direction": "in", "name": "req", "methods": [ "get", "post" ] }, { "type": "http", "direction": "out", "name": "$return" } ] }

github-actions[bot] commented 1 year ago

This issue is idle because it has been open for 14 days with no activity.

patelchandni commented 1 year ago

@austinh123123 Is this function app on Linux consumption sku? Also, please share the exact error message.