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

docs: Added documentation for creating a local developer environment. #225

Open
wants to merge 17 commits into
base: main
Choose a base branch
from

Conversation

jacobbaek
Copy link
Contributor

Fixes #
#56

Description
Added documentation for creating a local developer environment.

How was this change tested?
Only the document side has changed.

Does this change impact docs?

  • Yes, PR includes docs updates
  • Yes, issue opened: #
  • No

Release Note
None


@coveralls
Copy link

coveralls commented Mar 21, 2024

Pull Request Test Coverage Report for Build 8924016783

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 97.774%

Totals Coverage Status
Change from base Build 8905676791: 0.0%
Covered Lines: 36281
Relevant Lines: 37107

💛 - Coveralls

CONTRIBUTING.md Outdated Show resolved Hide resolved
CONTRIBUTING.md Outdated Show resolved Hide resolved
CONTRIBUTING.md Outdated Show resolved Hide resolved
@Bryce-Soghigian
Copy link
Contributor

Willing to approve this, we have a policy to get two approvers if its a new contributor (someone without approval rights in the codebase)

cc: @charliedmcb , @rakechill , @tallaxes if you are interested in reviewing

@Bryce-Soghigian
Copy link
Contributor

@jacobbaek would you be interested in contributing some code or are you at the playing with the framework stage?

@jacobbaek
Copy link
Contributor Author

@Bryce-Soghigian I am interested in contributing code. :)

Makefile-az.mk Outdated Show resolved Hide resolved
* Add installing extension
* Add comparing if condition about golang version
* Remove installing the make command
@Bryce-Soghigian
Copy link
Contributor

lgtm

we have a policy to get two approvers if its a new contributor (someone without approval rights in the codebase), let me post internally to see if we can get another review

Copy link
Collaborator

@charliedmcb charliedmcb left a comment

Choose a reason for hiding this comment

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

Love the look of this! Have just a few questions on the current version though :)

Makefile-az.mk Show resolved Hide resolved
Makefile-az.mk Outdated Show resolved Hide resolved
Makefile-az.mk Outdated Show resolved Hide resolved
* Change incorrect comparison statement
* Add installing curl command
@@ -22,6 +23,23 @@ This project has adopted the [Microsoft Open Source Code of Conduct](https://ope
kubectl scale deployments/inflate --replicas=3
```

### Use local environment instead of GitHub Codespaces.
> Tested environment : WSL2
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should specify distribution, especially since package management is distribution-specific

Makefile-az.mk Outdated
Comment on lines 34 to 36
if test -z "$(shell which docker)"; then \
curl -fsSL https://get.docker.com | bash -; \
fi
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should not be needed in WSL2, Docker Desktop for Windows with WSL2 integration would be strongly preferred. (Plus docker client need here is extremely niche - only used for alternative Go helper build ...)

Makefile-az.mk Outdated
sudo apt update && sudo apt install curl jq -y
curl -Lo yq https://github.com/mikefarah/yq/releases/download/v4.43.1/yq_linux_amd64 && chmod +x yq && sudo mv yq /usr/local/bin
if test -z "$(shell which helm)"; then \
curl -sL https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash -
Copy link
Collaborator

Choose a reason for hiding this comment

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

For any of the tools that provide an alternative to piping into bash - please use the alternative.

Makefile-az.mk Outdated
@@ -25,6 +25,32 @@ az-all-custom-vnet: az-login az-create-workload-msi az-mkaks-custom-vnet az-crea

az-all-savm: az-login az-mkaks-savm az-perm-savm az-patch-skaffold-azure az-build az-run az-run-sample ## Provision the infra (ACR,AKS); build and deploy Karpenter; deploy sample Provisioner and workload - StandaloneVirtualMachines

install-tools: az-tool ## install tools to create a local developer environment
sudo apt update && sudo apt install curl jq -y
curl -Lo yq https://github.com/mikefarah/yq/releases/download/v4.43.1/yq_linux_amd64 && chmod +x yq && sudo mv yq /usr/local/bin
Copy link
Collaborator

Choose a reason for hiding this comment

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

yq is installed by make toolchain

Makefile-az.mk Outdated Show resolved Hide resolved
@@ -25,6 +25,32 @@ az-all-custom-vnet: az-login az-create-workload-msi az-mkaks-custom-vnet az-crea

az-all-savm: az-login az-mkaks-savm az-perm-savm az-patch-skaffold-azure az-build az-run az-run-sample ## Provision the infra (ACR,AKS); build and deploy Karpenter; deploy sample Provisioner and workload - StandaloneVirtualMachines

install-tools: az-tool ## install tools to create a local developer environment
Copy link
Collaborator

@tallaxes tallaxes Apr 9, 2024

Choose a reason for hiding this comment

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

Maybe consider a separate script (under hack) to be called from makefile?

Consider adding shellcheck and pre-commit (and maybe pprof & graphviz - though these may be a little niche ...)

Copy link
Collaborator

Choose a reason for hiding this comment

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

shellcheck was referring to this tool: https://www.shellcheck.net/; the name of the script in hack needs to be something else. (Maybe devtools.sh? A little hard to express the difference between this and toolchain.sh ...)

Makefile-az.mk Outdated Show resolved Hide resolved
CONTRIBUTING.md Show resolved Hide resolved
@tallaxes tallaxes added area/developer-guide Issues or PRs related to the developer guide area/devtools Issues or PRs related to devtools labels Apr 9, 2024
* Add the step to run ./hack/toolchain.sh
/usr/local/kubebuilder/bin
/usr/local/kubebuilder/bin/k8s
/usr/local/kubebuilder/bin/k8s/1.29.3-linux-amd64
/usr/local/kubebuilder/bin/k8s/1.29.3-linux-amd64/etcd
/usr/local/kubebuilder/bin/k8s/1.29.3-linux-amd64/kube-apiserver
/usr/local/kubebuilder/bin/k8s/1.29.3-linux-amd64/kubectl
/usr/local/kubebuilder/bin/k8s/1.27.1-linux-amd64
/usr/local/kubebuilder/bin/k8s/1.27.1-linux-amd64/etcd
/usr/local/kubebuilder/bin/k8s/1.27.1-linux-amd64/kube-apiserver
/usr/local/kubebuilder/bin/k8s/1.27.1-linux-amd64/kubectl
/usr/local/kubebuilder/bin/etcd
/usr/local/kubebuilder/bin/kube-apiserver
/usr/local/kubebuilder/bin/kubectl at the CONTRIBUTING.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/developer-guide Issues or PRs related to the developer guide area/devtools Issues or PRs related to devtools
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants