-
Notifications
You must be signed in to change notification settings - Fork 1
/
cloudbuild-custom.yaml
41 lines (41 loc) · 1.2 KB
/
cloudbuild-custom.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
31
32
33
34
35
36
37
38
39
40
41
steps:
- name: 'gcr.io/cloud-builders/git'
entrypoint: /bin/sh
args:
- '-c'
- |
git clone https://github.com/sofisl/testing-another-one.git && \
cd testing-another-one/ && \
git checkout -b dev && \
git branch
env:
- 'GITHUB_TOKEN=$_GITHUB_TOKEN'
- 'HOME=/workspace'
- name: ${_CONTAINER}
dir: /workspace/testing-another-one
- name: 'gcr.io/cloud-builders/gcloud'
entrypoint: 'bash'
args:
- '-c'
- |
ls
dir: /workspace/testing-another-one
env:
- 'GITHUB_TOKEN=$_GITHUB_TOKEN'
- name: 'gcr.io/cloud-builders/git'
entrypoint: /bin/sh
args:
- '-c'
- |
git config --global user.email "sofialeon@google.com" && \
git config --global user.name 'Sofia Leon' && \
echo>> https://x-access-token:$$GITHUB_TOKEN@github.com >> /workspace/.git-credentials && \
cat /workspace/.git-credentials && \
cat /workspace/.gitconfig && \
git config --global credential.helper 'store --file .git-credentials' && \
git add . && \
git commit -m 'do the thing' && \
git push --set-upstream origin dev
env:
- 'GITHUB_TOKEN=$_GITHUB_TOKEN'
dir: testing-another-one