Skip to content

Latest commit

 

History

History
46 lines (35 loc) · 1.32 KB

README.md

File metadata and controls

46 lines (35 loc) · 1.32 KB

Introduction

Demo app using Azure functions as an API to fetch movies from third party source.

System components

Getting Started

Install first the azure functions core tools via npm

npm i -g azure-functions-core-tools@3 --unsafe-perm true

Local Azure functions development

Use the command line to start the functions locally by

func start

To test locally with the Azure Storage emulator, you will need the following local.settings.json file to be set up:

{
  "IsEncrypted": false,
  "Values": {
    "AzureWebJobsStorage": "UseDevelopmentStorage=true",
    "FUNCTIONS_WORKER_RUNTIME": "dotnet",
    "AzureWebJobs.FinnkinoMovieQueryFunction.Disabled": false,
    "AzureWebJobs.GetMovies.Disabled": false
  },
  "ConnectionStrings": {
    "AzureSqlConnectionString": "Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=FinnkinoMovies;Integrated Security=True;"
  },
  "AzureSqlSettings": {
    "ConnectionString": "Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=FinnkinoMovies;Integrated Security=True;"
  }
}

Additionally add this to project debug settings as input parameters to ensure CORS is in effect:

host start --build --port 7071 --cors * --pause-on-error