Skip to content

Commit 663b1e6

Browse files
attempt to add free disk space (#576)
1 parent c44080f commit 663b1e6

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

.github/workflows/preview-build.yml

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: preview-build
22

33
on:
4-
pull_request_target:
4+
pull_request_target:
55
types:
66
- opened
77
- synchronize
@@ -34,7 +34,7 @@ permissions:
3434

3535
jobs:
3636
build:
37-
concurrency:
37+
concurrency:
3838
group: ${{ github.workflow }}-${{ github.event.pull_request.head.ref || github.ref }}
3939
cancel-in-progress: ${{ github.event_name == 'pull_request_target' }}
4040
runs-on: ubuntu-latest
@@ -46,14 +46,19 @@ jobs:
4646
uses: tj-actions/changed-files@d6e91a2266cdb9d62096cebf1e8546899c6aa18f # v45.0.6
4747
with:
4848
files: ${{ inputs.path-pattern != '' && inputs.path-pattern || '**' }}
49-
49+
50+
- name: Free Disk Space
51+
uses: jlumbroso/free-disk-space@main
52+
with:
53+
tool-cache: false
54+
5055
- name: Checkout
5156
if: github.event_name == 'push' || steps.check-files.outputs.any_changed == 'true'
5257
uses: actions/checkout@v4
53-
with:
58+
with:
5459
ref: ${{ github.event.pull_request.head.sha || github.ref }}
5560
persist-credentials: false
56-
61+
5762
- name: Create Deployment
5863
if: github.event_name == 'push' || steps.check-files.outputs.any_changed == 'true'
5964
uses: actions/github-script@v7
@@ -86,7 +91,7 @@ jobs:
8691
log_url: `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`,
8792
})
8893
return deployment.data.id
89-
94+
9095
- name: Generate env.PATH_PREFIX
9196
if: steps.deployment.outputs.result
9297
env:
@@ -113,7 +118,7 @@ jobs:
113118
- name: Bootstrap Action Workspace
114119
if: github.repository == 'elastic/docs-builder' && steps.deployment.outputs.result
115120
uses: ./.github/actions/bootstrap
116-
121+
117122
# we run our artifact directly please use the prebuild
118123
# elastic/docs-builder@main GitHub Action for all other repositories!
119124
- name: Build documentation
@@ -142,7 +147,7 @@ jobs:
142147
--paths "${PATH_PREFIX}" "${PATH_PREFIX}/*"
143148
144149
- name: Update Link Index
145-
if: github.event_name == 'push' && github.ref == 'refs/heads/main' && steps.s3-upload.outcome == 'success'
150+
if: github.event_name == 'push' && github.ref == 'refs/heads/main' && steps.s3-upload.outcome == 'success'
146151
uses: elastic/docs-builder/actions/update-link-index@main
147152

148153
- name: Update deployment status

0 commit comments

Comments
 (0)