Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(examples): Vertex Machine Learning Pipeline #66

Merged
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
Show all changes
77 commits
Select commit Hold shift + click to select a range
ec29d99
refacto ml-vertexpipeline
renato-rudnicki Jun 12, 2024
2de509f
fix empty spaces
renato-rudnicki Jun 13, 2024
1d87258
sync with main
renato-rudnicki Jun 13, 2024
7900b96
fix conflict
renato-rudnicki Jun 13, 2024
40aae11
fix lint
renato-rudnicki Jun 13, 2024
e1250c2
Add aditional instructions before run Notebooks
renato-rudnicki Jun 14, 2024
fbee309
Add aditional instructions before run Notebooks
renato-rudnicki Jun 14, 2024
fdf2895
change data to use variable as input
renato-rudnicki Jun 14, 2024
9d7e411
add new variables values for data filters
renato-rudnicki Jun 20, 2024
e29bbca
fixes for envs and iam roles
renato-rudnicki Jun 20, 2024
8f7fb1c
add missing variables
renato-rudnicki Jun 20, 2024
f834958
Merge branch 'main' into vertex-pipeline-example
renato-rudnicki Jun 21, 2024
ce9d823
fix conflicts
renato-rudnicki Jun 25, 2024
45a199c
README update
renato-rudnicki Jun 27, 2024
76f4ea0
update with tests
caetano-colin Jun 27, 2024
ec52448
Merge pull request #2 from caetano-colin/test-renato-example
renato-rudnicki Jun 27, 2024
a78b5d7
update tests
caetano-colin Jun 28, 2024
0496599
kfp==2.7.0
caetano-colin Jun 28, 2024
010c5f1
add vertex_model_sa as prod_sa
caetano-colin Jun 28, 2024
f6bf1be
updating PR
caetano-colin Jul 1, 2024
e2c90db
add vpc-sc rules
caetano-colin Jul 1, 2024
980d59a
update
caetano-colin Jul 1, 2024
431c1b9
update readme
caetano-colin Jul 1, 2024
506bc5b
update vpc-sc rules
caetano-colin Jul 2, 2024
0259623
Merge pull request #3 from caetano-colin/test-renato
renato-rudnicki Jul 2, 2024
f614399
small fixes for lint and documentation
renato-rudnicki Jul 2, 2024
a91ec14
update README
renato-rudnicki Jul 2, 2024
5c953f7
update README
renato-rudnicki Jul 3, 2024
d31e7c0
Update README for Github App ID and more details about Develop, Non-P…
renato-rudnicki Jul 8, 2024
cceb460
Add missing logging project at vpc-sc directional rule
renato-rudnicki Jul 8, 2024
b68671a
Set github_app_installation_id and github_remote_uri value as empty
renato-rudnicki Jul 8, 2024
393756f
fix github_app_installation_id format
renato-rudnicki Jul 11, 2024
1a46078
fix for_each for artifact_registry_iam_member
renato-rudnicki Jul 11, 2024
c00478c
fix lint
renato-rudnicki Jul 11, 2024
3aefff2
add terraform init for 1-org
renato-rudnicki Jul 16, 2024
3ef8bc6
fix for_each for google_storage_bucket_iam_member
renato-rudnicki Jul 16, 2024
ba92368
Fixes for machine-learning-pipeline/README.md
renato-rudnicki Jul 17, 2024
7763ece
fix for Github_app_id
renato-rudnicki Jul 18, 2024
1a1f1a7
READMEs update
renato-rudnicki Jul 19, 2024
bb36619
Update README
renato-rudnicki Jul 19, 2024
3fd53b9
add changes
caetano-colin Jul 19, 2024
65c9c5a
Merge pull request #4 from caetano-colin/adjust-ml-pipe-example
renato-rudnicki Jul 19, 2024
6892500
bump project-factory version
renato-rudnicki Jul 19, 2024
be90d7b
add note about bash terminal
renato-rudnicki Jul 19, 2024
69b343f
bump project-factory version
renato-rudnicki Jul 19, 2024
13ebe00
Note about inconsistent final plan
renato-rudnicki Jul 19, 2024
736c521
fix project-factory bump version
renato-rudnicki Jul 22, 2024
67418a5
remove hardcode data
renato-rudnicki Jul 22, 2024
ec4d4f8
Fix and improvements for Machine Learning Example
renato-rudnicki Jul 26, 2024
d8aee2a
Automated replacement of placeholders
renato-rudnicki Jul 29, 2024
269508a
add discalimers
caetano-colin Aug 6, 2024
fe49961
rewriting
caetano-colin Aug 6, 2024
58fd65c
rewrite
caetano-colin Aug 6, 2024
0e229d6
Merge pull request #5 from caetano-colin/add-disclaimer
renato-rudnicki Aug 7, 2024
e3123b6
Path fix
renato-rudnicki Aug 13, 2024
8cb74df
Update for deploy with terraform local and cloudbuild sections
renato-rudnicki Aug 13, 2024
bdeff1c
Fix indentation.
renato-rudnicki Aug 13, 2024
f7f8d1e
update steps to add SA in the service perimeter
renato-rudnicki Aug 15, 2024
87a9753
perma-diff in provider causes Cloud Functions in 1-org to always fail
renato-rudnicki Aug 16, 2024
ea02006
fix command path
renato-rudnicki Aug 22, 2024
dbffa63
Revert "fix command path"
renato-rudnicki Aug 22, 2024
324536c
add step to unset billing/quota_project
renato-rudnicki Aug 22, 2024
ef146c0
fix path for BQ commands
renato-rudnicki Aug 22, 2024
03ab845
fix placeholders for census_pipeline.ipynb
renato-rudnicki Aug 22, 2024
79fb92b
fix path for terraform local deploy
renato-rudnicki Aug 27, 2024
2e27be8
update notebook dependencies
renato-rudnicki Aug 27, 2024
f6e1c47
update placeholders
renato-rudnicki Aug 28, 2024
b898d52
fix typo
renato-rudnicki Aug 28, 2024
f6c0684
fix placeholders for compile_pipeline
renato-rudnicki Aug 28, 2024
fc7e708
add detail about https in the clone repo step for Vertex
renato-rudnicki Aug 29, 2024
279cdec
fix conflicts
renato-rudnicki Sep 27, 2024
8297213
update docker image
renato-rudnicki Sep 27, 2024
b1d7d00
update juniper notebooks
renato-rudnicki Sep 27, 2024
ccd511e
fix conflict
renato-rudnicki Sep 30, 2024
cf4eeea
Update steps from machine-learning-pipeline example
renato-rudnicki Sep 30, 2024
da49015
add README
renato-rudnicki Oct 1, 2024
437704f
update README for machine learning example
renato-rudnicki Oct 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions 2-environments/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ You will be doing this procedure for each environment (`development`, `non-produ
Make sure your git is checked out to the development branch by running `git checkout development` on `GCP_ENVIRONMENTS_PATH`.

```bash
(cd $GCP_ENVIRONMENTS_PATH && git checkout development)
(cd $GCP_ENVIRONMENTS_PATH && git checkout development && cd $GCP_ENVIRONMENTS_PATH/envs/development && terraform init)
renato-rudnicki marked this conversation as resolved.
Show resolved Hide resolved
```

2. Retrieve the bucket name and project id from terraform outputs.
Expand Down Expand Up @@ -244,7 +244,7 @@ You will be doing this procedure for each environment (`development`, `non-produ
Make sure your git is checked out to the `non-production` branch by running `git checkout non-production` on `GCP_ENVIRONMENTS_PATH`.

```bash
(cd $GCP_ENVIRONMENTS_PATH && git checkout non-production)
(cd $GCP_ENVIRONMENTS_PATH && git checkout non-production && cd $GCP_ENVIRONMENTS_PATH/envs/non-production && terraform init)
renato-rudnicki marked this conversation as resolved.
Show resolved Hide resolved
```

2. Retrieve the bucket name and project id from terraform outputs.
Expand Down Expand Up @@ -292,7 +292,7 @@ You will be doing this procedure for each environment (`development`, `non-produ
Make sure your git is checked out to the `production` branch by running `git checkout production` on `GCP_ENVIRONMENTS_PATH`.

```bash
(cd $GCP_ENVIRONMENTS_PATH && git checkout production)
(cd $GCP_ENVIRONMENTS_PATH && git checkout production && cd $GCP_ENVIRONMENTS_PATH/envs/production && terraform init)
renato-rudnicki marked this conversation as resolved.
Show resolved Hide resolved
```

2. Retrieve the bucket name and project id from terraform outputs.
Expand Down
17 changes: 0 additions & 17 deletions 5-app-infra/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,20 +222,17 @@ Once pushed, the pipeline build logs can be accessed by navigating to the artifa
#### Configuring Cloud Source Repository of Artifact Application

1. Grab the Artifact Project ID

```bash
export ARTIFACT_PROJECT_ID=$(terraform -chdir="gcp-projects/ml_business_unit/shared" output -raw common_artifacts_project_id)
echo ${ARTIFACT_PROJECT_ID}
```

1. Clone the freshly minted Cloud Source Repository that was created for this project.

```bash
gcloud source repos clone publish-artifacts --project=${ARTIFACT_PROJECT_ID}
```

1. Enter the repo folder and copy over the artifact files from `5-app-infra/source_repos/artifact-publish` folder.

```bash
cd publish-artifacts
git checkout -b main
Expand All @@ -254,7 +251,6 @@ Once pushed, the pipeline build logs can be accessed by navigating to the artifa
```

1. `cd` out of the `publish-artifacts` repository.

```bash
cd ..
```
Expand All @@ -271,7 +267,6 @@ Although Service Catalog itself must be manually deployed, the modules which wil
The resoning behind utilizing one repository with two deployment methodologies is due to how close interactive (`development`) and operational environments are.

The repository has the structure (truncated for brevity):

```
ml_business_unit
├── development
Expand Down Expand Up @@ -407,13 +402,11 @@ The pipeline also listens for changes made to `plan`, `development`, `non-produc
```

1. Clone the freshly minted Cloud Source Repository that was created for this project.

```bash
gcloud source repos clone service-catalog --project=${SERVICE_CATALOG_PROJECT_ID}
```

1. Enter the repo folder and copy over the service catalogs files from `5-app-infra/source_repos/service-catalog` folder.

```bash
cd service-catalog/
cp -RT ../terraform-google-enterprise-genai/5-app-infra/source_repos/service-catalog/ .
Expand All @@ -422,7 +415,6 @@ The pipeline also listens for changes made to `plan`, `development`, `non-produc
```

1. Commit changes and push main branch to the new repo.

```bash
git add modules
git commit -m 'Initialize Service Catalog Build Repo'
Expand All @@ -431,7 +423,6 @@ The pipeline also listens for changes made to `plan`, `development`, `non-produc
```

1. `cd` out of the `service_catalog` repository.

```bash
cd ..
```
Expand Down Expand Up @@ -547,20 +538,17 @@ unset GOOGLE_IMPERSONATE_SERVICE_ACCOUNT
1. The next instructions assume that you are at the same level of the `terraform-google-enterprise-genai` folder.

1. Grab the Artifact Project ID

```bash
export ARTIFACT_PROJECT_ID=$(terraform -chdir="terraform-google-enterprise-genai/4-projects/ml_business_unit/shared" output -raw common_artifacts_project_id)
echo ${ARTIFACT_PROJECT_ID}
```

1. Clone the freshly minted Cloud Source Repository that was created for this project.

```bash
gcloud source repos clone publish-artifacts --project=${ARTIFACT_PROJECT_ID}
```

1. Enter the repo folder and copy over the artifact files from `5-app-infra/source_repos/artifact-publish` folder.

```bash
cd publish-artifacts
git checkout -b main
Expand All @@ -579,7 +567,6 @@ unset GOOGLE_IMPERSONATE_SERVICE_ACCOUNT
```

1. `cd` out of the `publish-artifacts` repository.

```bash
cd ..
```
Expand Down Expand Up @@ -698,13 +685,11 @@ After executing this stage, unset the `GOOGLE_IMPERSONATE_SERVICE_ACCOUNT` envir
```

1. Clone the freshly minted Cloud Source Repository that was created for this project.

```bash
gcloud source repos clone service-catalog --project=${SERVICE_CATALOG_PROJECT_ID}
```

1. Enter the repo folder and copy over the service catalogs files from `5-app-infra/source_repos/service-catalog` folder.

```bash
cd service-catalog/
git checkout -b main
Expand All @@ -715,7 +700,6 @@ After executing this stage, unset the `GOOGLE_IMPERSONATE_SERVICE_ACCOUNT` envir
```

1. Commit changes and push main branch to the new repo.

```bash
git add modules
git commit -m 'Initialize Service Catalog Build Repo'
Expand All @@ -724,7 +708,6 @@ After executing this stage, unset the `GOOGLE_IMPERSONATE_SERVICE_ACCOUNT` envir
```

1. `cd` out of the `service-catalog` repository.

```bash
cd ..
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| instance\_region | The region where compute instance will be created. A subnetwork must exists in the instance region. | `string` | n/a | yes |
| log\_bucket | Log bucket to be used by Service Catalog Bucket | `string` | n/a | yes |
| remote\_state\_bucket | Backend bucket to load remote state information from previous steps. | `string` | n/a | yes |

## Outputs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| instance\_region | The region where compute instance will be created. A subnetwork must exists in the instance region. | `string` | n/a | yes |
| log\_bucket | Log bucket to be used by Service Catalog Bucket | `string` | n/a | yes |
| remote\_state\_bucket | Backend bucket to load remote state information from previous steps. | `string` | n/a | yes |

## Outputs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@
# limitations under the License.
#
FROM tensorflow/tensorflow:2.8.0
RUN pip install tensorflow-io==0.25.0 protobuf==3.20.0 google-cloud-bigquery==3.13.0 pandas==2.0.3 db-dtypes==1.2.0 google-cloud-aiplatform==1.36.0 google-cloud-storage==2.14.0 kfp google-cloud-pipeline-components
RUN pip install tensorflow-io==0.25.0 protobuf==3.20.0 google-cloud-bigquery==3.13.0 pandas==2.0.3 db-dtypes==1.2.0 google-cloud-aiplatform==1.36.0 google-cloud-storage==2.14.0 kfp==2.7.0 google-cloud-pipeline-components
Loading