Skip to content

Commit

Permalink
Updated code snippets to include package version fetch
Browse files Browse the repository at this point in the history
  • Loading branch information
cartyc committed Sep 14, 2023
1 parent 67deecb commit eb52255
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 15 deletions.
12 changes: 9 additions & 3 deletions docs/landing-zone-v2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,9 @@ cd pbmm-landingzone
The latest versions of the releases can be found in [Releases](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases). The provided versions are examples and may not be up to date.

```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/[email protected]
PACKAGE="solutions/gatekeeper-policies"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION}
```

All Gatekeeper Policy Package releases can be found [here](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=gatekeeper&expanded=true)
Expand All @@ -409,15 +411,19 @@ cd pbmm-landingzone
- Experimentation

```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/experimentation/[email protected]
PACKAGE="solutions/experimentation/core-landing-zone"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION}
```

[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=experimentation&expanded=true)

- DEV, PREPROD, PROD

```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/[email protected]
PACKAGE="solutions/core-landing-zone"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION}
```

[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=core-landing-zone&expanded=true)
Expand Down
21 changes: 15 additions & 6 deletions docs/landing-zone-v2/onboarding-client.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@ You will execute this procedure to provision the foundational resources in GCP f
- DEV, PREPROD, PROD
```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/[email protected] ./clients/<client name>
PACKAGE="solutions/client-setup"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
CLIENT_NAME=initial-client
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION} ./clients/${CLIENT_NAME}
```
[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=%22solutions%2Fclient-setup%22&expanded=true)
Expand All @@ -63,7 +66,7 @@ You will execute this procedure to provision the foundational resources in GCP f
1. Render the Configs
```shell
kpt fn render clients/<client name>/client-setup
kpt fn render clients/${CLIENT_NAME}/client-setup
```
1. Deploy the infrastructure using either kpt or gitops-git or gitops-oci
Expand All @@ -78,25 +81,31 @@ You will execute this procedure to provision the foundational resources in GCP f
- Experimentation

```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/experimentation/[email protected] ./clients/<client name>
PACKAGE="solutions/experimentation/client-landing-zone"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
CLIENT_NAME=initial-client
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION} ./clients/${CLIENT_NAME}
```

[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=experimentation%2Fclient-landing-zone&expanded=true)

- DEV, PREPROD, PROD

```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/[email protected] ./clients/<client name>
PACKAGE="solutions/client-landing-zone"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
CLIENT_NAME=initial-client
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION} ./clients/${CLIENT_NAME}
```

[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=solutions%2Fclient-landing-zone&expanded=true)

1. Customize the `clients/<client name>/client-landing-zone/setters.yaml` file
1. Customize the `clients/${CLIENT_NAME}/client-landing-zone/setters.yaml` file

2. Render the Configs

```shell
kpt fn render clients/<client name>/client-landing-zone
kpt fn render clients/${CLIENT_NAME}/client-landing-zone
```

3. Deploy the infrastructure using either kpt or gitops-git or gitops-oci
Expand Down
18 changes: 12 additions & 6 deletions docs/landing-zone-v2/onboarding-project.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,21 @@ You will execute this procedure to provision the service project in GCP for appl
- Experimentation
```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/experimentation/[email protected] ./projects/<project-id>
PACKAGE="solutions/experimentation/client-project"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
PROJECT_ID=project-id
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}@${VERSION} ./projects/${PROJECT_ID}
```
[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=%22experimentation%2Fclient-project%22&expanded=true)
- DEV, PREPROD, PROD
```shell
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/solutions/[email protected] ./projects/<project-id>
PACKAGE="solutions/client-project-setup"
VERSION=$(curl -s $URL | jq -r ".\"$PACKAGE\"")
PROJECT_ID=project-id
kpt pkg get https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit.git/${PACKAGE}p@${VERSION} ./projects/${PROJECT_ID}
```
[Releases List](https://github.com/GoogleCloudPlatform/pubsec-declarative-toolkit/releases?q=%22solutions%2Fclient-project-setup%22&expanded=true)
Expand All @@ -66,11 +72,11 @@ You will execute this procedure to provision the service project in GCP for appl
- Experimentation
`projects/<project-id>/client-project/setters.yaml`
`projects/${PROJECT_ID}/client-project/setters.yaml`
- DEV, PREPROD, PROD
`projects/<project-id>/client-project-setup/setters.yaml`
`projects/${PROJECT_ID}/client-project-setup/setters.yaml`
> **!!! There is a folder in the `client-project-setup` package called `root-sync-git`. This folder can be deleted if your are not using a `Gitops - Git` deployment solution. But, if you are, you should now create a new repository for this project and configure the setters.yaml file accordingly.**
Expand All @@ -79,13 +85,13 @@ You will execute this procedure to provision the service project in GCP for appl
- Experimentation
```shell
kpt fn render projects/<project-id>/client-project
kpt fn render projects/${PROJECT_ID}/client-project
```
- DEV, PREPROD, PROD
```shell
kpt fn render projects/<project-id>/client-project-setup
kpt fn render projects/${PROJECT_ID}/client-project-setup
```
1. Deploy the infrastructure using either kpt or gitops-git or gitops-oci

0 comments on commit eb52255

Please sign in to comment.