Skip to content

Commit

Permalink
addressing comments and trying to remove build yaml step
Browse files Browse the repository at this point in the history
  • Loading branch information
aishwaryabh committed Feb 27, 2024
1 parent 327ab16 commit 88423c3
Show file tree
Hide file tree
Showing 8 changed files with 4 additions and 142 deletions.
18 changes: 1 addition & 17 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:

env:
config: Release
newVersion: 99.99.99-test
fakeWebJobsPackageVersion: 99.99.99-test

jobs:
build:
Expand All @@ -30,9 +30,6 @@ jobs:
- name: Docker Run - Azurite
run: docker run -d -p 10000:10000 -p 10001:10001 -p 10002:10002 mcr.microsoft.com/azure-storage/azurite

- name: Docker Build - Chat Bot Sample Out of proc
run: docker build -f samples/chat/csharp-ooproc/Dockerfile -t openai-func-sample-csharp-ooproc .

- name: Docker Run - Chat Bot Sample Out of Proc
env:
AZURE_OPENAI_KEY: ${{ secrets.AZURE_OPENAI_KEY }}
Expand All @@ -49,19 +46,6 @@ jobs:
- name: Sleep for 10 seconds
run: sleep 10s

- name: Create new directory
run: mkdir ~/NuGetPackagesLocal

- name: Create/Copy NuGet Package to local directory and Build
run: |
dotnet build /home/runner/work/azure-functions-openai-extension/azure-functions-openai-extension/src/WebJobs.Extensions.OpenAI/WebJobs.Extensions.OpenAI.csproj --configuration $config -p:FileVersionRevision=$GITHUB_RUN_NUMBER -p:WebJobsVersion=$newVersion -p:Version=$newVersion
sudo cp "/home/runner/work/azure-functions-openai-extension/azure-functions-openai-extension/src/WebJobs.Extensions.OpenAI/bin/Release/Microsoft.Azure.WebJobs.Extensions.OpenAI.${newVersion}.nupkg" ~/NuGetPackagesLocal
dotnet nuget add source ~/NuGetPackagesLocal
dotnet nuget list source
dotnet build --configuration $config /p:WebJobsVersion=$newVersion;FileVersionRevision=$GITHUB_RUN_NUMBER

- name: E2E Test - Out of Proc Chat Bot Sample
run: dotnet test --configuration $config --no-build --verbosity normal
Expand Down
5 changes: 2 additions & 3 deletions samples/chat/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ Please refer to the root level [README](../../README.md#requirements) for prereq

| Language Worker | Command |
| --------------- | ------- |
| .NET in-proc | `cd samples/chat/csharp-inproc && dotnet build && cd bin/debug/net6.0 && func start` |
| .NET oo-proc | `cd samples/chat/csharp-ooproc && dotnet build && cd bin/debug/net6.0 && func start` |
| Node.js | `cd samples/chat/nodejs && npm install && dotnet build --output bin && npm run build && npm run start` |
| PowerShell | `cd samples/chat/powershell && dotnet build --output bin && func start` |
Expand All @@ -37,10 +36,10 @@ Please refer to the root level [README](../../README.md#requirements) for prereq
GetChatState: [GET] http://localhost:7071/api/chats/{chatId}
PostUserResponse: [POST] http://localhost:7071/api/chats/{chatId}
OpenAI::ChatBotEntity: entityTrigger
```

Note for running the post user response function provided in the sample, please specify a model name in the environment variable `AZURE_DEPLOYMENT_NAME`. This value can be an Azure deployment name or a GPT model name.

3. Use an HTTP client tool to send a request to the `CreateChatBot` function. The following is an example request:

```http
Expand Down
54 changes: 0 additions & 54 deletions samples/chat/csharp-inproc/ChatBot.cs

This file was deleted.

26 changes: 0 additions & 26 deletions samples/chat/csharp-inproc/ChatBotSample.csproj

This file was deleted.

20 changes: 0 additions & 20 deletions samples/chat/csharp-inproc/Dockerfile

This file was deleted.

14 changes: 0 additions & 14 deletions samples/chat/csharp-inproc/host.json

This file was deleted.

7 changes: 0 additions & 7 deletions samples/chat/csharp-inproc/local.settings.json

This file was deleted.

2 changes: 1 addition & 1 deletion samples/chat/csharp-ooproc/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build-env
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build-env

# Add support for .NET 6 (required for Azure Functions build process)
COPY --from=mcr.microsoft.com/dotnet/sdk:6.0 /usr/share/dotnet/shared /usr/share/dotnet/shared
Expand Down

0 comments on commit 88423c3

Please sign in to comment.