Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
shawncal authored Jun 23, 2023
2 parents 5a35539 + 432edaa commit 29b4968
Show file tree
Hide file tree
Showing 533 changed files with 38,687 additions and 13,901 deletions.
4 changes: 3 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
"image": "mcr.microsoft.com/devcontainers/universal:2",
"features": {
"ghcr.io/devcontainers/features/node:1": {},
"ghcr.io/devcontainers/features/dotnet:1": {},
"ghcr.io/devcontainers/features/dotnet:1": {
"version": "7"
},
"ghcr.io/jlaundry/devcontainer-features/azure-functions-core-tools:1": {}
},
"customizations": {
Expand Down
19 changes: 19 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# @microsoft/octo-semantickernel-pr-dotnet owns any files in the dotnet
# directory at the root of the repository and any of its
# subdirectories.
/dotnet/ @microsoft/octo-semantickernel-pr-dotnet

# @microsoft/octo-semantickernel-pr-python owns any files in the python
# directory at the root of the repository and any of its
# subdirectories.
/python/ @microsoft/octo-semantickernel-pr-python

# @microsoft/octo-semantickernel-pr-python owns any files in the java
# directory at the root of the repository and any of its
# subdirectories.
/java/ @microsoft/octo-semantickernel-pr-java

# @microsoft/octo-semantickernel-pr-apps owns any files in the samples
# directory at the root of the repository and any of its
# subdirectories.
/samples/ @microsoft/octo-semantickernel-pr-apps
13 changes: 13 additions & 0 deletions .github/_typos.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,16 @@ extend-exclude = [

[default.extend-words]
ACI = "ACI" # Azure Container Instance

[default.extend-identifiers]
ags = "ags" # Azure Graph Service

[type.jupyter]
extend-ignore-re = [
'"[A-Fa-f0-9]{8}"', # cell id strings
]

[type.msbuild]
extend-ignore-re = [
'Version=".*"', # ignore package version numbers
]
24 changes: 22 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,34 @@

version: 2
updates:
# Maintain dependencies for nuget
- package-ecosystem: "nuget"
directory: "dotnet/"
schedule:
interval: "weekly"
interval: "daily"

# Maintain dependencies for nuget
- package-ecosystem: "nuget"
directory: "samples/"
schedule:
interval: "daily"

# Maintain dependencies for npm
- package-ecosystem: "npm"
directory: "samples/apps"
schedule:
interval: "daily"

# Maintain dependencies for pip
- package-ecosystem: "pip"
directory: "python/"
schedule:
interval: "daily"

# Maintain dependencies for github-actions
- package-ecosystem: "github-actions"
# Workflow files stored in the
# default location of `.github/workflows`
directory: "/"
schedule:
interval: "weekly"
interval: "daily"
59 changes: 59 additions & 0 deletions .github/workflows/copilot-chat-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
#
# This workflow will package the Copilot Chat application for deployment.
#

name: copilot-chat-package

on:
pull_request:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'
push:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- { dotnet: '6.0', configuration: Release, os: ubuntu-latest }

runs-on: ${{ matrix.os }}
env:
NUGET_CERT_REVOCATION_MODE: offline
steps:
- uses: actions/checkout@v3
with:
clean: true

- name: Pull container dotnet/sdk:${{ matrix.dotnet }}
run: docker pull mcr.microsoft.com/dotnet/sdk:${{ matrix.dotnet }}

- name: Package Copilot Chat WebAPI
run: |
chmod +x $(pwd)/samples/apps/copilot-chat-app/deploy/package-webapi.sh;
docker run --rm -v $(pwd):/app -w /app -e GITHUB_ACTIONS='true' mcr.microsoft.com/dotnet/sdk:${{ matrix.dotnet }} /bin/sh -c "/app/samples/apps/copilot-chat-app/deploy/package-webapi.sh --no-zip";
- name: Set version tag
id: versiontag
run: |
VERSION_TAG="$(date +'%Y%m%d').${{ github.run_number }}.${{ github.run_attempt }}"
echo $VERSION_TAG
echo "versiontag=$VERSION_TAG" >> $GITHUB_OUTPUT
- name: Upload package to artifacts
uses: actions/upload-artifact@v3
with:
name: copilotchat-webapi-${{ steps.versiontag.outputs.versiontag }}
path: ./samples/apps/copilot-chat-app/deploy/publish
86 changes: 86 additions & 0 deletions .github/workflows/copilot-chat-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
name: Copilot Chat Tests
on:
workflow_dispatch:
push:
branches: [ "main", "feature*" ]
paths:
- 'samples/apps/copilot-chat-app/**'

permissions:
contents: read

jobs:
test:
defaults:
run:
working-directory: samples/apps/copilot-chat-app/webapp
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v3

- uses: actions/setup-node@v3
with:
node-version: 16
cache-dependency-path: samples/apps/copilot-chat-app/webapp/yarn.lock
cache: 'yarn'

- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x

- name: Install dependencies
run: yarn install

- name: Install Playwright Browsers
run: yarn playwright install --with-deps

- name: Update AIService configuration
working-directory: samples/apps/copilot-chat-app/webapi
env:
AzureOpenAI__ApiKey: ${{ secrets.AZUREOPENAI__APIKEY }}
AzureOpenAI__Endpoint: ${{ secrets.AZUREOPENAI__ENDPOINT }}
run: |
dotnet dev-certs https
dotnet user-secrets set "AIService:Key" "$AzureOpenAI__ApiKey"
dotnet user-secrets set "AIService:Endpoint" "$AzureOpenAI__Endpoint"
- name: Start service in background
working-directory: samples/apps/copilot-chat-app/webapi
run: |
dotnet run > service-log.txt 2>&1 &
for attempt in {0..20}; do
jobs
echo 'Waiting for service to start...';
if curl -k https://localhost:40443/healthz; then
echo;
echo 'Service started';
break;
fi;
sleep 5;
done
- name: Run Playwright tests
env:
REACT_APP_BACKEND_URI: https://localhost:40443/
REACT_APP_AAD_CLIENT_ID: ${{ secrets.COPILOT_CHAT_REACT_APP_AAD_CLIENT_ID }}
REACT_APP_AAD_AUTHORITY: https://login.microsoftonline.com/common
REACT_APP_TEST_USER_ACCOUNT: ${{ secrets.COPILOT_CHAT_TEST_USER_ACCOUNT }}
REACT_APP_TEST_USER_PASSWORD: ${{ secrets.COPILOT_CHAT_TEST_USER_PASSWORD }}
run: yarn playwright test

- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: samples/apps/copilot-chat-app/webapp/playwright-report/
retention-days: 30

- uses: actions/upload-artifact@v3
if: always()
with:
name: service-log
path: samples/apps/copilot-chat-app/webapi/service-log.txt
retention-days: 30
3 changes: 3 additions & 0 deletions .github/workflows/dotnet-ci-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ on:
workflow_dispatch:
push:
branches: [ "main", "feature*" ]
paths:
- 'dotnet/**'
- 'samples/dotnet/**'

permissions:
contents: read
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/dotnet-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ on:
workflow_dispatch:
push:
branches: [ "main", "feature*" ]
paths:
- 'dotnet/**'
- 'samples/dotnet/**'

permissions:
contents: read
Expand Down
62 changes: 0 additions & 62 deletions .github/workflows/dotnet-format-on-slash.yml

This file was deleted.

26 changes: 0 additions & 26 deletions .github/workflows/dotnet-format-pr-2.yml

This file was deleted.

Loading

0 comments on commit 29b4968

Please sign in to comment.