Skip to content

Commit 8ee3ffe

Browse files
authored
Install quest (#434)
* Install quest. * Correct comment.
1 parent 8a00577 commit 8ee3ffe

File tree

3 files changed

+109
-0
lines changed

3 files changed

+109
-0
lines changed

.github/workflows/quest-bulk.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: "bulk quest import"
2+
on:
3+
schedule:
4+
- cron: '0 6 * * *' # UTC time, that's 6pm UTC, 1pm EST.
5+
workflow_dispatch:
6+
inputs:
7+
reason:
8+
description: "The reason for running the bulk import workflow"
9+
required: true
10+
default: "Initial import into Quest (Azure DevOps)"
11+
12+
jobs:
13+
bulk-import:
14+
runs-on: ubuntu-latest
15+
permissions:
16+
issues: write
17+
if: ${{ github.repository_owner == 'dotnet' }}
18+
19+
steps:
20+
- name: "Print manual bulk import run reason"
21+
if: ${{ github.event_name == 'workflow_dispatch' }}
22+
run: |
23+
echo "Reason: ${{ github.event.inputs.reason }}"
24+
25+
- name: bulk-sequester
26+
id: bulk-sequester
27+
uses: dotnet/docs-tools/actions/sequester@main
28+
env:
29+
ImportOptions__ApiKeys__GitHubToken: ${{ secrets.GITHUB_TOKEN }}
30+
ImportOptions__ApiKeys__OSPOKey: ${{ secrets.OSPO_KEY }}
31+
ImportOptions__ApiKeys__QuestKey: ${{ secrets.QUEST_KEY }}
32+
ImportOptions__ApiKeys__SequesterPrivateKey: ${{ secrets.SEQUESTER_PRIVATEKEY }}
33+
ImportOptions__ApiKeys__SequesterAppID: ${{ secrets.SEQUESTER_APPID }}
34+
with:
35+
org: ${{ github.repository_owner }}
36+
repo: ${{ github.repository }}
37+
issue: '-1'

.github/workflows/quest.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: "quest import"
2+
on:
3+
workflow_dispatch:
4+
inputs:
5+
reason:
6+
description: "The reason for running the workflow"
7+
required: true
8+
default: "Manual run"
9+
issue:
10+
description: "The issue number to manually test"
11+
required: true
12+
13+
jobs:
14+
import:
15+
if: |
16+
github.event_name == 'workflow_dispatch' ||
17+
github.event.label.name == ':world_map: reQUEST' ||
18+
github.event.label.name == ':pushpin: seQUESTered' ||
19+
contains(github.event.issue.labels.*.name, ':world_map: reQUEST') ||
20+
contains(github.event.issue.labels.*.name, ':pushpin: seQUESTered')
21+
runs-on: ubuntu-latest
22+
permissions:
23+
issues: write
24+
25+
steps:
26+
- name: "Print manual run reason"
27+
if: ${{ github.event_name == 'workflow_dispatch' }}
28+
run: |
29+
echo "Reason: ${{ github.event.inputs.reason }}"
30+
echo "Issue number: ${{ github.event.inputs.issue }}"
31+
32+
# This step occurs when ran manually, passing the manual issue number input
33+
- name: manual-sequester
34+
if: ${{ github.event_name == 'workflow_dispatch' }}
35+
id: manual-sequester
36+
uses: dotnet/docs-tools/actions/sequester@main
37+
env:
38+
ImportOptions__ApiKeys__GitHubToken: ${{ secrets.GITHUB_TOKEN }}
39+
ImportOptions__ApiKeys__OSPOKey: ${{ secrets.OSPO_KEY }}
40+
ImportOptions__ApiKeys__QuestKey: ${{ secrets.QUEST_KEY }}
41+
ImportOptions__ApiKeys__SequesterPrivateKey: ${{ secrets.SEQUESTER_PRIVATEKEY }}
42+
ImportOptions__ApiKeys__SequesterAppID: ${{ secrets.SEQUESTER_APPID }}
43+
with:
44+
org: ${{ github.repository_owner }}
45+
repo: ${{ github.repository }}
46+
issue: ${{ github.event.inputs.issue }}
47+
48+
# This step occurs automatically, passing the issue number from the event
49+
- name: auto-sequester
50+
if: ${{ github.event_name != 'workflow_dispatch' }}
51+
id: auto-sequester
52+
uses: dotnet/docs-tools/actions/sequester@main
53+
env:
54+
ImportOptions__ApiKeys__GitHubToken: ${{ secrets.GITHUB_TOKEN }}
55+
ImportOptions__ApiKeys__OSPOKey: ${{ secrets.OSPO_KEY }}
56+
ImportOptions__ApiKeys__QuestKey: ${{ secrets.QUEST_KEY }}
57+
ImportOptions__ApiKeys__SequesterPrivateKey: ${{ secrets.SEQUESTER_PRIVATEKEY }}
58+
ImportOptions__ApiKeys__SequesterAppID: ${{ secrets.SEQUESTER_APPID }}
59+
with:
60+
org: ${{ github.repository_owner }}
61+
repo: ${{ github.repository }}
62+
issue: ${{ github.event.issue.number }}
63+

quest-config.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"AzureDevOps": {
3+
"Org": "msft-skilling",
4+
"Project": "Content",
5+
"AreaPath": "Production\\Digital and App Innovation\\DotNet and more\\MAUI"
6+
},
7+
"ImportTriggerLabel": ":world_map: reQUEST",
8+
"ImportedLabel": ":pushpin: seQUESTered"
9+
}

0 commit comments

Comments
 (0)