This repository was archived by the owner on May 13, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +50
-4
lines changed Expand file tree Collapse file tree 3 files changed +50
-4
lines changed Original file line number Diff line number Diff line change 1
- name : publish_to_pages_staging
2
- description : Publishes to cloudflare pages (staging)
1
+ name : publish_to_pages
2
+ description : Publishes to cloudflare pages
3
3
inputs :
4
4
CLOUDFLARE_ACCOUNT_ID :
5
5
description : Cloudflare account id
6
6
required : true
7
7
CLOUDFLARE_API_TOKEN :
8
8
description : Cloudflare token
9
9
required : true
10
+ CF_BRANCH :
11
+ description : Cloudflare branch
12
+ required : true
10
13
runs :
11
14
using : composite
12
15
steps :
17
20
run : |-
18
21
19
22
cd build
20
- npx wrangler pages deploy . --project-name=deriv-developers-portal-pages --branch=staging
23
+ npx wrangler pages deploy . --project-name=deriv-developers-portal-pages --branch=${{ inputs.CF_BRANCH }}
21
24
echo "New staging website - https://staging-api.deriv.com/"
22
25
shell : bash
Original file line number Diff line number Diff line change @@ -27,10 +27,11 @@ jobs:
27
27
RELEASE_TAG : ${{ github.sha }}
28
28
RELEASE_TYPE : staging
29
29
- name : Publish to Cloudflare Pages Staging
30
- uses : ./.github/actions/publish_to_pages_staging
30
+ uses : ./.github/actions/publish_to_pages
31
31
with :
32
32
CLOUDFLARE_ACCOUNT_ID : ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
33
33
CLOUDFLARE_API_TOKEN : ${{ secrets.CLOUDFLARE_API_TOKEN }}
34
+ CF_BRANCH : staging
34
35
- name : Publish to Docker
35
36
uses : ./.github/actions/publish_to_docker
36
37
with :
Original file line number Diff line number Diff line change
1
+ name : Deriv Api Docs Test/UAT Workflow
2
+ on :
3
+ pull_request :
4
+ branches :
5
+ - uat
6
+ workflow_dispatch :
7
+
8
+ env :
9
+ RELEASE_TYPE : Staging
10
+ jobs :
11
+ build_and_publish :
12
+ name : Builds and Publishes to Cloudflare Pages Test
13
+ environment : Staging
14
+ runs-on : ubuntu-latest
15
+ outputs :
16
+ RELEASE_VERSION : ${{ steps.extract_version.outputs.RELEASE_VERSION }}
17
+ steps :
18
+ - name : Checkout
19
+ uses : actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
20
+ - name : Setup Node
21
+ uses : ./.github/actions/setup_node
22
+ - name : Install dependencies
23
+ uses : ./.github/actions/npm_install_from_cache
24
+ - name : Build
25
+ uses : ./.github/actions/build
26
+ with :
27
+ NODE_ENV : staging
28
+ TRACKJS_TOKEN : ${{ secrets.TRACKJS_TOKEN }}
29
+ - name : Versioning
30
+ uses : ./.github/actions/versioning
31
+ with :
32
+ RELEASE_TAG : ${{ github.ref_name }}
33
+ RELEASE_TYPE : ${{ env.RELEASE_TYPE }}
34
+ - name : Extract version
35
+ id : extract_version
36
+ run : echo "RELEASE_VERSION=$(cat build/version.txt)" >> $GITHUB_OUTPUT
37
+ - name : Publish to Cloudflare Pages Test
38
+ uses : ./.github/actions/publish_to_pages
39
+ with :
40
+ CLOUDFLARE_ACCOUNT_ID : ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
41
+ CLOUDFLARE_API_TOKEN : ${{ secrets.CLOUDFLARE_API_TOKEN }}
42
+ CF_BRANCH : test
You can’t perform that action at this time.
0 commit comments