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: add prometheus-operator example for jobset #629

Merged
merged 4 commits into from
Jul 28, 2024

Conversation

googs1025
Copy link
Member

Fix: #626

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 27, 2024
Copy link

netlify bot commented Jul 27, 2024

Deploy Preview for kubernetes-sigs-jobset canceled.

Name Link
🔨 Latest commit 348997c
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-jobset/deploys/66a5b7a6dca9890008f71eaf

type: NodePort
# Port mapping: Note if deploying with kind for testing, if docker mappings are not exposed when the cluster starts,
# kube port-forward needs to be used for port forwarding
# kubectl port-forward services/jobset-metrics 39090:9090 --address 0.0.0.0 -njobset-system
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
# kubectl port-forward services/jobset-metrics 39090:9090 --address 0.0.0.0 -njobset-system
# kubectl port-forward services/jobset-metrics 39090:9090 --address 0.0.0.0 -n jobset-system

Copy link
Member Author

Choose a reason for hiding this comment

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

done

name: jobset-metrics
namespace: jobset-system
spec:
serviceAccountName: prometheus-jobset
Copy link
Contributor

Choose a reason for hiding this comment

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

Does this service account need to be created before we apply the Prometheus CR? I see you create it lower in this file - have you tested this manually?

Copy link
Member Author

Choose a reason for hiding this comment

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

I split into rbac.yaml

Copy link
Contributor

Choose a reason for hiding this comment

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

Why not just put the service account and RBACs above the Prometheus CR in the same file?

Copy link
Member Author

Choose a reason for hiding this comment

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

done

@danielvegamyhre danielvegamyhre self-assigned this Jul 27, 2024
@danielvegamyhre
Copy link
Contributor

@googs1025 Can you add a short readme in this folder explaining the steps to demo this example?

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 28, 2024
@googs1025
Copy link
Member Author

@googs1025 Can you add a short readme in this folder explaining the steps to demo this example?
done

https://github.com/googs1025/jobset/tree/docs_prometheus/examples/prometheus-operator

NAME READY STATUS RESTARTS AGE
jobset-controller-manager-76767b599b-v8wcc 2/2 Running 0 6d22h
prometheus-jobset-metrics-0 2/2 Running 0 17s
root@VM-0-5-ubuntu:/home/ubuntu# kubectl get svc -njobset-system
Copy link
Contributor

Choose a reason for hiding this comment

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

Last nit: can you add a space between "-n" and "jobset-system" please? it is more readable

Copy link
Member Author

Choose a reason for hiding this comment

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

sorry. fixed.

@danielvegamyhre
Copy link
Contributor

/lgtm
/approve
Thanks!

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 28, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: danielvegamyhre, googs1025

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 28, 2024
@k8s-ci-robot k8s-ci-robot merged commit fee9b9d into kubernetes-sigs:main Jul 28, 2024
13 checks passed
@danielvegamyhre danielvegamyhre mentioned this pull request Aug 19, 2024
20 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

docs: added use cases for using prometheus-operator
3 participants