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

Katacoda Scenario(?) for a brand new developer - basic tutorial #5576

Closed
dims opened this issue Feb 27, 2021 · 43 comments
Closed

Katacoda Scenario(?) for a brand new developer - basic tutorial #5576

dims opened this issue Feb 27, 2021 · 43 comments
Assignees
Labels
area/new-contributor-track lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. sig/contributor-experience Categorizes an issue or PR as relevant to SIG Contributor Experience.
Milestone

Comments

@dims
Copy link
Member

dims commented Feb 27, 2021

Other CNCF communities maintain katacoda courses, example:
https://github.com/thanos-io/thanos/issues?q=is%3Aissue++katacoda+

There are a lot of katacoda scenarios for kubernetes in general as a end user:
https://katacoda.com/kubernetes

ASK:
We need one where someone who has just starting out in kubernetes and wants to try their hand at making a patch and testing it.

Basic Steps:

  • Create a fork on github
  • Install basic tools like go, make (build-essential on ubuntu)
  • Checkout their personal fork
  • Add kubernete/kubernetes as a remote
  • Make some simple change
  • Run basic developer workflows like
    • Run a test using go
    • Run some verification and update scripts (hack/verify-gofmt.sh, hack/verify-typecheck.sh)
  • Create a branch and submit a PR

Optional :

  • Show how to start a kind cluster with the updated code
  • Update an existing PR to incorporate any changes during review

Why do we need to doing:

  • We have a LOT of documentation, it's hard to figure out what one has to do
  • Videos / Recordings help a bit, but there is no substitute for trying things yourself
  • There is a lot of beginners who have a basic laptop (say windows) and do not have access to a beefy linux box/vm. So give them a chance to participate/learn

Possible issues:

  • Not sure if Katacoda environments can support the CPU/Mem, we can hit up folks if we run into issues.
@k8s-ci-robot k8s-ci-robot added the needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. label Feb 27, 2021
@dims
Copy link
Member Author

dims commented Feb 27, 2021

/sig contributor-experience

@k8s-ci-robot k8s-ci-robot added sig/contributor-experience Categorizes an issue or PR as relevant to SIG Contributor Experience. and removed needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Feb 27, 2021
@dims
Copy link
Member Author

dims commented Feb 27, 2021

Idea thanks to conversations with @soniasingla @LappleApple @Darshnadas

@mrbobbytables
Copy link
Member

/area new-contributor-track
/assign @mrbobbytables @alisondy @jberkus

@soniasingla
Copy link

soniasingla commented Feb 27, 2021

hey @mrbobbytables @jberkus @alisondy! Want to collaborate on this with me? It would be a great addition to our developer community!

I have some experience in creating Katacoda tutorials. https://katacoda.com/thanos/courses/thanos/2-lts I created this last summer, it came out to be really helpful :)

@saiyam1814
Copy link
Contributor

I think this is great @dims and would be useful for the community!
There is a Kind scenario already -> https://www.katacoda.com/petermbenjamin/scenarios/kind
Kubernetes playground is also there, so we can over time actually create fully maintained Kubernetes Katakoda scenarios that we can use to teach other things as well

@mrbobbytables
Copy link
Member

I did a quick test of trying to build kubernetes, but unfortunately the instance just dies when doing so. I don't think katacoda can cope with our build requirements:

  • 8GB of RAM
  • 50GB of free disk space

If you want to try, I just went with vanilla instance and went through the dev procedure here to install our reqs and
https://github.com/kubernetes/community/blob/master/contributors/devel/development.md#building-kubernetes-on-a-local-osshell-environment

Then ran make all

@dims
Copy link
Member Author

dims commented Feb 27, 2021

@mrbobbytables make all may be a very heavy hammer. if we can do

  • make kubelet (like individual pieces)
  • make generated_files
  • hack/verify-* scripts (especially typecheck)

that should give us a decent start. make quick-release etc will be too heavy as well. hoping we can experiment with some low resource stuff at least for now

@dims
Copy link
Member Author

dims commented Feb 27, 2021

cc @BenHall

@BenHall
Copy link

BenHall commented Feb 27, 2021

@mrbobbytables thanks for the info. We do limit our free tier but the platform supports much larger instances. I will try in one of our large environments and see what happens.

@mrbobbytables
Copy link
Member

@BenHall Thanks! Are the instance types/resource allocations documented anywhere? I was trying to find it earlier, but didn't have any luck^^;;

@BenTheElder
Copy link
Member

re: kind, LMK if there's any issues 🙃
re: make quick-release is heavy: kubernetes/kubernetes#99517

@BenHall
Copy link

BenHall commented Mar 5, 2021

@mrbobbytables @dims I took a look today. With slightly CPU and Memory (8 cores, 8Gb) everything looked to build successfully within an environment, even make all.

I ran make test and most appear to work but some failed. Here is the output https://gist.github.com/BenHall/2896bf3012282deaae7f58508bfa7b8e

Anything failing due to Katacoda?

@dims
Copy link
Member Author

dims commented Mar 5, 2021

@BenHall thanks! i see 2 failures, please log an issue about them so we don't forget. i think this is fine, you don't have to dig into it yet. we are reworking a bunch of stuff (rip bazel, bump to golang 1.16) so i'd expect some hiccups right now.

@BenHall can you please check if this works?

kind build node-image
kind create cluster --image kindest/node:latest

documented here : https://github.com/kubernetes-sigs/kind/blob/master/README.md#L87

a really stretch goal would be this:
https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/conformance-tests.md#running-conformance-tests-with-kind

@BenHall
Copy link

BenHall commented Mar 5, 2021

@dims Looks like the node-image can build. It took 5mins, not sure what the normal time is.

Create Cluster however failed

ERROR: failed to create cluster: failed to init node with kubeadm: command "docker exec --privileged kind-control-plane kubeadm init --skip-phases=preflight --config=/kind/kubeadm.conf --skip-token-print --v=6" failed with error: exit status 1
Command Output: I0305 15:13:17.371346     210 initconfiguration.go:246] loading configuration from "/kind/kubeadm.conf"
[config] WARNING: Ignored YAML document with GroupVersionKind kubeadm.k8s.io/v1beta2, Kind=JoinConfiguration
I0305 15:13:17.378564     210 kubelet.go:259] setting the KubeletConfiguration cgroupDriver to "systemd"

The healthcheck appears to timeout after a while.

[kubelet-check] It seems like the kubelet isn't running or healthy.
[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp [::1]:10248: connect: connection refused.

@BenTheElder
Copy link
Member

BenTheElder commented Mar 5, 2021

If we're building Kubernetes sources at HEAD we need kind installed from HEAD. Kubeadm made a breaking change in Kubernetes 1.21 (unreleased) which kind at HEAD handles.

Edit: basically the kind sources must be roughly as new as the Kubernetes sources sometimes because we can't always predict and pre-mitigate these [Action Required] changes upstream.

Also 5 minutes is pretty excellent right now for building Kubernetes.

@BenHall
Copy link

BenHall commented Mar 5, 2021

@BenTheElder that would be it! Thanks, will give it a go.

@BenTheElder
Copy link
Member

BenTheElder commented Mar 5, 2021

Also I'm pretty sure for the contributor summit at least what we've done is used stable releases of both (checkout to kubernetes release-1.X branch, use latest kind stable release) to avoid surprises on the day of the session, that may be a good idea here (though might be nearly as tricky to do on a rolling basis?)

We also have pre-compiled binaries used by CI here: https://kind.sigs.k8s.io/dl/latest/linux-amd64 (not really advertised, since if you're not developing Kubernetes we'd prefer that people stick to a stable release).
Kubernetes PRs download and run a compressed copy along with an e2e script https://kind.sigs.k8s.io/dl/latest/linux-amd64.tgz (~2MB tgz vs ~7MB binary).

@mrbobbytables mrbobbytables added this to the Next milestone Mar 7, 2021
@alisondy
Copy link
Contributor

@hh @heyste fyi re: ncw build and test

@eddiezane
Copy link
Member

@napcs @katjuell @hazel-nut this might be a good place to contribute if DO folks are interested.

@dims
Copy link
Member Author

dims commented Apr 13, 2021

@BenHall Any updates? please let us know.

@2610aayushi
Copy link

/assign

@2610aayushi 2610aayushi removed their assignment Sep 20, 2021
@MadhavJivrajani
Copy link
Contributor

@dims there is a draft for this ready with a few kinks to iron out - would appreciate some feedback on what can be added/deleted/re-worded: https://hackmd.io/@uAHy4KDqQdaqL_eZX2nGSA/HkAvKY9bY
cc @Debanitrkl

@dims
Copy link
Member Author

dims commented Oct 21, 2021

Looks good @MadhavJivrajani

@Debanitrkl
Copy link
Member

According to the documentation of katacoda we need to have a Github repository in this format https://www.katacoda.community/essentials/author-profile.html#create-author-profile and have an author profile there to release a scenario, I was thinking if k8s repo has its own katacoda profile then it would be better. Also since we already have katacoda tutorials for downstream users I was trying to find out katacoda scenario repository in k8s org but couldn't find one. Also here's an example of katacoda scenario repository.

@Debanitrkl
Copy link
Member

I have created the katacoda scenario here, could anyone please review it.
cc @MadhavJivrajani @dims

@dims
Copy link
Member Author

dims commented Nov 8, 2021

@Debanitrkl please send an email to sig-contribex and sig-docs about creating a github repository like the one mentioned in the url above and let us see who can help. Also add it to their meeting agenda please.

@Debanitrkl
Copy link
Member

@Debanitrkl please send an email to sig-contribex and sig-docs about creating a github repository like the one mentioned in the url above and let us see who can help. Also add it to their meeting agenda please.

Yeah sure I will drop an email soon, Also I have already discussed it with folks at sig-contribex in our biweekly meetings, and a few people are presently reviewing the scenario and post-review I was advised to open an issue with steering as they are the ones responsible for opening a new repository.

@dims
Copy link
Member Author

dims commented Nov 9, 2021

see "Repository creation/migration" in https://github.com/kubernetes/org/issues/new/choose (no need to involve steering, you need a SIG to own this)

@Debanitrkl
Copy link
Member

The repository for the katacoda-scenario has been created and the first basic tutorial is prepared, so closing the issue.
/close

@k8s-ci-robot
Copy link
Contributor

@Debanitrkl: Closing this issue.

In response to this:

The repository for the katacoda-scenario has been created and the first basic tutorial is prepared, so closing the issue.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@Debanitrkl
Copy link
Member

/reopen
For LFX Mentorship applicants to go through the discussion on this issue and get a brief idea of the motive behind the contributor-katacoda.

@k8s-ci-robot
Copy link
Contributor

@Debanitrkl: Reopened this issue.

In response to this:

/reopen
For LFX Mentorship applicants to go through the discussion on this issue and get a brief idea of the motive behind the contributor-katacoda.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 5, 2022
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Jun 4, 2022
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue or PR with /reopen
  • Mark this issue or PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

@k8s-ci-robot
Copy link
Contributor

@k8s-triage-robot: Closing this issue.

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue or PR with /reopen
  • Mark this issue or PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/new-contributor-track lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. sig/contributor-experience Categorizes an issue or PR as relevant to SIG Contributor Experience.
Projects
None yet
Development

No branches or pull requests