Created
May 20, 2022 14:20
-
-
Save sleepless-se/31cbee5a449b1b17d0e5659264d56cd9 to your computer and use it in GitHub Desktop.
How to set python test on cloudbuild.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
steps: | |
# Install modules | |
- name: 'python' | |
entrypoint: pip | |
args: [ "install", "-r", "requirements.txt", "--user" ] | |
# Run unit tests | |
- name: python | |
args: ["python","-m","unittest"] | |
id: unittest | |
# build docker image | |
- name: 'gcr.io/kaniko-project/executor:latest' | |
args: | |
- --destination=gcr.io/${PROJECT_ID}/build-test | |
- --cache=true | |
- --cache-ttl=24h |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment