-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcloudbuild.yaml
30 lines (30 loc) · 1.11 KB
/
cloudbuild.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
steps:
# Google Cloud doesn't natively support Git LFS, so we have to manually enable it
- name: 'gcr.io/public-side-projects/git-lfs'
args: ['install']
dir: '/workspace'
- name: 'gcr.io/public-side-projects/git-lfs'
args: ['pull']
dir: '/workspace'
- name: 'gcr.io/public-side-projects/git-lfs'
entrypoint: /bin/rm
args: ['-r', 'public/pdfs/']
dir: '/workspace'
- name: 'gcr.io/public-side-projects/git-lfs'
args: ['checkout', '.']
dir: '/workspace'
- name: 'gcr.io/public-side-projects/git-lfs'
entrypoint: /bin/bash
args:
- -c
- |
ls -lh public/pdfs/QAW_Download_Library_Jan26_2021/ ;
(( $$(stat -c%s public/pdfs/QAW_Download_Library_Jan26_2021/whiteness.pdf) > 5000000 )) ;
dir: '/workspace'
- name: 'gcr.io/cloud-builders/npm'
args: ['install']
- name: 'gcr.io/cloud-builders/npm'
args: ['run' , 'build']
# Deploy to the Google Cloud Storage bucket that serves the web app at https://zines.garrettheath4.com
- name: 'gcr.io/cloud-builders/gsutil'
args: ["-m", "rsync", "-r", "-c", "-d", "./build", "gs://zines.garrettheath4.com"]