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

Prod 2450/how to use plural docs #289

Merged
merged 25 commits into from
Sep 22, 2024

Conversation

seemywingz
Copy link
Contributor

@seemywingz seemywingz commented Jul 29, 2024

Summary

Add How To for plural up , adding a workload cluster, scm connection, controllers and a few placeholders

Labels

enhancement

Test Plan

Viwed changes locally with yarn dev

Checklist

  • If required, I have updated the Plural documentation accordingly.
  • I have added tests to cover my changes.
  • I have added a meaningful title and summary to convey the impact of this PR to a user.
  • [x I have added relevant labels to this PR to help with categorization for release notes.

@seemywingz seemywingz requested a review from a team July 29, 2024 19:47
@seemywingz seemywingz self-assigned this Jul 29, 2024
@seemywingz seemywingz requested a review from a team as a code owner July 29, 2024 19:47
Copy link

linear bot commented Jul 29, 2024

Copy link

netlify bot commented Jul 29, 2024

Deploy Preview for pluraldocs ready!

Name Link
🔨 Latest commit 0733854
🔍 Latest deploy log https://app.netlify.com/sites/pluraldocs/deploys/66f0549b1bc93a00087a7fe2
😎 Deploy Preview https://deploy-preview-289--pluraldocs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@seemywingz
Copy link
Contributor Author

seemywingz commented Jul 29, 2024

I added the docs for How To/Set Up a New MGMT Cluster, I also added installing the Plural CLI and Console. there are also placeholders for How To/Use which I think are useful

the placeholders are not added in the NavData

```


### Create a New Repo for Plural
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We shouldn't recommend they do this, instead let plural up create the repo for them, which it does via oauth (and explain it can be cloned first if they can't do that due to permissioning constraints).

### Get Kubeconfig for the MGMT Cluster
AWS
```sh
aws eks update-kubeconfig --name [CLUSTER_NAME]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plural wkspace kube-init does that for you actually

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is really cool!
I didn't know this feature existed


##### Add the RBAC Helm Values in the MGMT Cluster Repo
```sh
./helm-values/ConsoleClusterRoleBindings.yaml
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not put this in the helm-values folder, that's git-crypted by default so should only be used for secret-ish things, create a new global service in a separate folder for rbac which contains this. Also don't camel-case filenames for k8s resources (not standard convention)

Copy link
Contributor Author

@seemywingz seemywingz Jul 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reference that Here: https://github.com/pluralsh/documentation/blob/main/pages/deployments/dashboard.md

should the doc just link to that or reiterate what the RBAC readme says?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this looks and reads better:
image

Copy link
Contributor Author

@seemywingz seemywingz Jul 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@seemywingz
Copy link
Contributor Author

@michaeljguarino I made the requested changes

Copy link
Member

@michaeljguarino michaeljguarino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

High level comments:

  • honestly feel like the docs for setting up a management cluster should probably just link to our already thorough docs elsewhere
  • there's a lot of incomplete content here I don't think we can merge and expose publicly

src/NavData.tsx Outdated Show resolved Hide resolved
pages/how-to/set-up/mgmt-cluster.md Outdated Show resolved Hide resolved
pages/how-to/set-up/mgmt-cluster.md Outdated Show resolved Hide resolved

##### Creating an RBAC Service
* **Create an `rbac` dir in your MGMT repo
and add the desired [k8s yaml](https://github.com/pluralsh/documentation/blob/main/pages/deployments/dashboard.md)**
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

relative link

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

address

pages/how-to/set-up/mgmt-cluster.md Outdated Show resolved Hide resolved
type: GITHUB
```
### **Add an SCM Provider Webhook**
If you navigate to `https://console.[YOUR DOMAIN].onplural.sh/pr/queue`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make these link urls: https://{your-console-domain}/pr/queue (most serious users bring their own domain)


# Troubleshooting

#### Get Kubeconfig for the MGMT Cluster
Copy link
Member

@michaeljguarino michaeljguarino Aug 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't make them troubleshoot w/ kubectl, they should be able to see this info in the CD ui (can also add the kubectl command as an addendum but should not be the primary flow as it's user-unfriendly)




# Troubleshooting
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

incomplete

![cluster-creator modal 2](/images/how-to/cluster-creator-modal-2.png)
* **Merge the PR**
* **Approve the Stack Run changes**
* Navigate to `https://console.[YOUR DOMAIN].onplural.sh/staacks`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use console urls formatted as above

@@ -0,0 +1,28 @@
---
title: Upgrading the Plural CLI
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't think we need these docs or at least not here if it's going to rabbithole users

* **Add a new `HelmRepository` CRD to your _infra_ repo `./apps/repositories`**
* Example: `ingress-nginx.yaml`
```yaml
apiVersion: source.toolkit.fluxcd.io/v1beta2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should use the native helm support not flux-based now that that's fully released. So this resource isn't necessary, and the repository field in the helm block below can just be replaced withurl pointing to the url in this CRD

src/NavData.tsx Outdated
href: '/how-to/set-up/workload-cluster',
},
{
title: 'SCM Connection',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you'll need to set up the scm connection before the workload cluster since it's a prereq. Also many users aren't going to understand the acronym, this should be titled something like Source Control Integration or something like that.

# Prerequisites
* **Plural Console `admin` Permissions**
* **SCM Provider Personal Access Token**
* [Github](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-personal-access-token-classic)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For github we should strongly nudge people to configure it via a github application which is technically more secure and not bound to a specific user.

* **Plural Console `admin` Permissions**
* **SCM Provider Personal Access Token**
* [Github](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-personal-access-token-classic)
* [GitLab](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html#create-a-personal-access-token)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should use group or project tokens not personal tokens

* **SCM Provider Personal Access Token**
* [Github](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-personal-access-token-classic)
* [GitLab](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html#create-a-personal-access-token)
* [Bitbucket](https://support.atlassian.com/bitbucket-cloud/docs/access-tokens/)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same, bitbucket has repo and org tokens that can be used

@michaeljguarino michaeljguarino force-pushed the PROD-2450/how-to-use-plural-docs branch 2 times, most recently from e874933 to 5aa334e Compare September 22, 2024 17:19
…s actually happening, corrects some mistakes and fixes the controller setup docs.
@michaeljguarino michaeljguarino force-pushed the PROD-2450/how-to-use-plural-docs branch from 5aa334e to 0733854 Compare September 22, 2024 17:32
@michaeljguarino michaeljguarino merged commit 99df69d into main Sep 22, 2024
8 of 9 checks passed
@michaeljguarino michaeljguarino deleted the PROD-2450/how-to-use-plural-docs branch September 22, 2024 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants