Skip to content

Commit cc6a4f6

Browse files
committed
chore: finish update cloudflare actions?
1 parent 80ef42b commit cc6a4f6

File tree

1 file changed

+4
-52
lines changed

1 file changed

+4
-52
lines changed

.github/workflows/deploy.yml

Lines changed: 4 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,25 @@
11
name: Build documentation and publish to Cloudflare Pages
22

33
on:
4-
# If specified, the workflow will be triggered automatically once you push to the `main` branch.
5-
# Replace `main` with your branch’s name
64
push:
75
branches: [ "master" ]
8-
9-
# Specify to run a workflow manually from the Actions tab on GitHub
106
workflow_dispatch:
117

12-
# Gives the workflow permissions to clone the repo and create a page deployment
138
permissions:
149
id-token: write
1510
pages: write
1611

1712
env:
18-
# Name of module and id separated by a slash
1913
INSTANCE: Writerside/ccs
20-
# Replace HI with the ID of the instance in capital letters
2114
ARTIFACT: webHelpCCS2-all.zip
22-
# Writerside docker image version
2315
DOCKER_VERSION: 243.22562
2416

25-
# Add the variable below to upload Algolia indexes
26-
# Replace HI with the ID of the instance in capital letters
2717
ALGOLIA_ARTIFACT: algolia-indexes-CCS.zip
2818
ALGOLIA_APP_NAME: C86V8LU863
2919
ALGOLIA_INDEX_NAME: docs_cast_crafter_community_server
3020
ALGOLIA_KEY: ${{ secrets.ALGOLIA_KEY }}
3121
CONFIG_JSON_PRODUCT: CCS
32-
CONFIG_JSON_VERSION: 1.21.1
22+
CONFIG_JSON_VERSION: 1.21.1 # This value should be updated with the version of the product
3323

3424
jobs:
3525
build:
@@ -42,7 +32,6 @@ jobs:
4232
uses: actions/checkout@v4
4333
with:
4434
fetch-depth: 0
45-
4635
- name: Define instance id and artifacts
4736
id: define-ids
4837
run: |
@@ -69,7 +58,6 @@ jobs:
6958
instance: ${{ env.INSTANCE }}
7059
artifact: ${{ env.ARTIFACT }}
7160
docker-version: ${{ env.DOCKER_VERSION }}
72-
7361
- name: Save artifact with build results
7462
uses: actions/upload-artifact@v4
7563
with:
@@ -80,53 +68,21 @@ jobs:
8068
artifacts/${{ env.ALGOLIA_ARTIFACT }}
8169
retention-days: 7
8270

83-
# Add the job below and artifacts/report.json on Upload documentation step above if you want to fail the build when documentation contains errors
8471
test:
85-
# Requires build job results
8672
needs: build
8773
runs-on: ubuntu-latest
88-
8974
steps:
9075
- name: Download artifacts
9176
uses: actions/download-artifact@v4
9277
with:
9378
name: docs
9479
path: artifacts
95-
9680
- name: Test documentation
9781
uses: JetBrains/writerside-checker-action@v1
9882
with:
9983
instance: ${{ env.INSTANCE }}
10084

101-
# deploy:
102-
# environment:
103-
# name: cloudflare-pages
104-
# url: ${{ steps.deployment.outputs.page_url }}
105-
# Requires the build job results
106-
#needs: [build, test]
107-
#runs-on: ubuntu-latest
108-
#steps:
109-
# - name: Download artifact
110-
# uses: actions/download-artifact@v4
111-
# with:
112-
# name: docs
113-
# path: artifacts
114-
115-
#- name: Unzip artifact
116-
# run: unzip -O UTF-8 -qq "artifacts/${{ needs.build.outputs.artifact }}" -d cf-pages
117-
118-
#- name: Publish to Cloudflare Pages
119-
# uses: cloudflare/[email protected]
120-
# with:
121-
# apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
122-
# accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
123-
#projectName: community-server-docs
124-
#directory: cf-pages
125-
#branch: main
126-
# Optional: Change the Wrangler version, allows you to point to a specific version or a tag such as `beta`
127-
# wranglerVersion: '3.4.1'
128-
129-
deploy2:
85+
deploy:
13086
environment:
13187
name: cloudflare-pages
13288
url: ${{ steps.deployment.outputs.page_url }}
@@ -147,14 +103,10 @@ jobs:
147103
with:
148104
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
149105
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
150-
#projectName: community-server-docs
151-
# command: pages deploy YOUR_DIST_FOLDER --project-name=example
152-
command: pages deploy cf-pages --project-name=community-server-docs
153-
#directory: cf-pages
154-
branch: main
106+
command: pages deploy cf-pages --project-name=community-server-docs --branch=main
155107

156108
publish-indexes:
157-
needs: [ build, test, deploy2 ]
109+
needs: [ build, test, deploy ]
158110
runs-on: ubuntu-latest
159111
container:
160112
image: registry.jetbrains.team/p/writerside/builder/algolia-publisher:2.0.32-3

0 commit comments

Comments
 (0)