|
| 1 | +pipeline: |
| 2 | + projectIdentifier: IPA_Release |
| 3 | + orgIdentifier: default |
| 4 | + tags: {} |
| 5 | + stages: |
| 6 | + - stage: |
| 7 | + name: Build Docs Container |
| 8 | + identifier: Build_Docs_Container |
| 9 | + description: "" |
| 10 | + type: CI |
| 11 | + spec: |
| 12 | + cloneCodebase: true |
| 13 | + execution: |
| 14 | + steps: |
| 15 | + - step: |
| 16 | + type: BuildAndPushDockerRegistry |
| 17 | + name: BuildAndPushDockerRegistry_1 |
| 18 | + identifier: BuildAndPushDockerRegistry_1 |
| 19 | + spec: |
| 20 | + connectorRef: account.harbor |
| 21 | + repo: harbor.devops.indico.io/indico/indico-client-csharp |
| 22 | + tags: |
| 23 | + - <+codebase.commitSha> |
| 24 | + dockerfile: readme_docs/Dockerfile |
| 25 | + platform: |
| 26 | + os: Linux |
| 27 | + arch: Amd64 |
| 28 | + runtime: |
| 29 | + type: Cloud |
| 30 | + spec: {} |
| 31 | + - stage: |
| 32 | + name: Build Csharp Docs |
| 33 | + identifier: Build_Python_Docs |
| 34 | + description: "" |
| 35 | + type: Custom |
| 36 | + spec: |
| 37 | + execution: |
| 38 | + steps: |
| 39 | + - step: |
| 40 | + type: Container |
| 41 | + name: PR To Readme |
| 42 | + identifier: PR_To_Readme |
| 43 | + spec: |
| 44 | + connectorRef: account.harbor |
| 45 | + image: harbor.devops.indico.io/indico/indico-client-csharp:<+codebase.commitSha> |
| 46 | + command: | |
| 47 | + cd /indico-client-csharp |
| 48 | + chmod +x ./readme_docs/build_docs.sh |
| 49 | + ./readme_docs/build_docs.sh |
| 50 | +
|
| 51 | + cp -r docfx_project/apiV2 $DOCS_PATH |
| 52 | + git clone https://user:$GITHUB_TOKEN@github.com/IndicoDataSolutions/indico-readme.git |
| 53 | + cd indico-readme |
| 54 | + git config --global user.email "engineering@indico.io" |
| 55 | + git config --global user.name "cat-automation" |
| 56 | + git checkout -b docs-version-$TAG |
| 57 | +
|
| 58 | + mkdir -p markdown |
| 59 | + cp -r $DOCS_PATH ./markdown/$LANGUAGE |
| 60 | + bash add_frontmatter_yaml.sh |
| 61 | +
|
| 62 | + git add ./markdown/$LANGUAGE |
| 63 | + git commit -m "a set of doc changes" |
| 64 | +
|
| 65 | + git push --set-upstream origin docs-version-$TAG |
| 66 | + curl -L \ |
| 67 | + -X POST \ |
| 68 | + -H "Accept: application/vnd.github+json" \ |
| 69 | + -H "Authorization: Bearer $GITHUB_TOKEN" \ |
| 70 | + -H "X-GitHub-Api-Version: 2022-11-28" \ |
| 71 | + https://api.github.com/repos/IndicoDataSolutions/indico-readme/pulls \ |
| 72 | + -d '{"title":"Amazing new feature","body":"Please pull these awesome changes in!","head":"docs-version-'"$TAG"'","base":"main"}' |
| 73 | + shell: Bash |
| 74 | + infrastructure: |
| 75 | + type: KubernetesDirect |
| 76 | + spec: |
| 77 | + connectorRef: account.Dev_Cluster |
| 78 | + namespace: default |
| 79 | + resources: |
| 80 | + limits: |
| 81 | + cpu: "0.5" |
| 82 | + memory: 500Mi |
| 83 | + annotations: {} |
| 84 | + labels: {} |
| 85 | + containerSecurityContext: |
| 86 | + capabilities: |
| 87 | + drop: [] |
| 88 | + add: [] |
| 89 | + nodeSelector: {} |
| 90 | + reports: |
| 91 | + type: JUnit |
| 92 | + spec: |
| 93 | + paths: [] |
| 94 | + outputVariables: [] |
| 95 | + envVariables: |
| 96 | + GITHUB_TOKEN: <+secrets.getValue("account.indicomachineuser_github_token")> |
| 97 | + TAG: <+codebase.commitSha> |
| 98 | + LANGUAGE: c-sharp |
| 99 | + README_API_KEY: <+secrets.getValue("meghanhickeyreadmepat")> |
| 100 | + DOCS_PATH: /harness/c-sharp |
| 101 | + timeout: 1m 30s |
| 102 | + tags: {} |
| 103 | + properties: |
| 104 | + ci: |
| 105 | + codebase: |
| 106 | + connectorRef: account.Indico |
| 107 | + repoName: indico-client-csharp |
| 108 | + build: <+input> |
| 109 | + identifier: Generate_CSharp_Docs |
| 110 | + name: Generate CSharp Docs |
0 commit comments