File tree 2 files changed +16
-4
lines changed 2 files changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -20,14 +20,27 @@ ROOT=$( dirname "$DIR" )
20
20
# Work from the project root.
21
21
cd $ROOT
22
22
23
+ # Prevent it from overriding files.
24
+ # We recommend that sample authors use their own service account files and cloud project.
25
+ # In that case, they are supposed to prepare these files by themselves.
26
+ if [[ -f " testing/test-env.sh" ]] || \
27
+ [[ -f " testing/service-account.json" ]] || \
28
+ [[ -f " testing/client-secrets.json" ]]; then
29
+ echo " One or more target files exist, aborting."
30
+ exit 1
31
+ fi
32
+
23
33
# Use SECRET_MANAGER_PROJECT if set, fallback to cloud-devrel-kokoro-resources.
24
34
PROJECT_ID=" ${SECRET_MANAGER_PROJECT:- cloud-devrel-kokoro-resources} "
25
35
26
36
gcloud secrets versions access latest --secret=" python-docs-samples-test-env" \
37
+ --project=" ${PROJECT_ID} " \
27
38
> testing/test-env.sh
28
39
gcloud secrets versions access latest \
29
40
--secret=" python-docs-samples-service-account" \
41
+ --project=" ${PROJECT_ID} " \
30
42
> testing/service-account.json
31
43
gcloud secrets versions access latest \
32
44
--secret=" python-docs-samples-client-secrets" \
33
- > testing/client-secrets.json
45
+ --project=" ${PROJECT_ID} " \
46
+ > testing/client-secrets.json
Original file line number Diff line number Diff line change 4
4
"git": {
5
5
"name": ".",
6
6
"remote": "https://github.com/googleapis/python-datastore.git",
7
- "sha": "7df727d00dce7c022f2b6a3c03b31ff7c3836d49"
8
-
7
+ "sha": "9535abaa76924fd04a386a5fe7255fa846073ff5"
9
8
}
10
9
},
11
10
{
20
19
"git": {
21
20
"name": "synthtool",
22
21
"remote": "https://github.com/googleapis/synthtool.git",
23
- "sha": "d91dd8aac77f7a9c5506c238038a26fa4f9e361e "
22
+ "sha": "d302f93d7f47e2852e585ac35ab2d15585717ec0 "
24
23
}
25
24
}
26
25
],
You can’t perform that action at this time.
0 commit comments