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

tidy up the template questions #10

Merged
merged 2 commits into from
Nov 26, 2024
Merged

tidy up the template questions #10

merged 2 commits into from
Nov 26, 2024

Conversation

gilesknap
Copy link
Member

@gilesknap gilesknap commented Nov 26, 2024

simplify the questions and add more help.

Points to note.
Target namespace, Apps namespace and Argo CD project are all the same string at DLS so I condensed down into a single question. If any external users want to set up ArgoCD we can recommend they use the same approach or generalize this template as necessary.

tested against i04 and p47.

Fixes #9

example interaction:

This template will create a new repository which describes the set of IOCs and services that Argo CD will track on a Kubernetes cluster.

🎤 A name for the group of IOC and service instances that this
   repository will track.

   At DLS this should be the short beamline name or the technical area
   for accelerator repos.
   i04
🎤 A One line description of the module
   i04 IOC Instances and Services Deployment Repository for Argo CD
🎤 Argocd server DNS Name.

   At DLS this is always "argocd.diamond.ac.uk"
   argocd.diamond.ac.uk
🎤 Cluster in which Argo CD Apps are deployed.

   At DLS this is always "argus"
   argus
🎤 The Kubernetes cluster where the IOCs and services will run.

   At DLS this should be "{beamline shortname}", "acastus" for the
   accelerator or "pollux" for test beamlines.
   i04
🎤 Kubernetes namespace in which the IOCs and services will run.

   At DLS this should be "{beamline shortname}-beamline" or "accelerator".
   i04-beamline
🎤 Git platform hosting this repository.
   gitlab.diamond.ac.uk
🎤 The DLS technical area
   beamline
🎤 Remote URI of this repository.
   https://gitlab.diamond.ac.uk/controls/containers/beamline/i04-deployment.git
🎤 Remote URI of the services repository that defines the IOCs and services,
   that this repository will track.
   https://gitlab.diamond.ac.uk/controls/containers/beamline/i04-services.git
🎤 The initial release of the services repository to track e.g. "2024.12.1" or "main"
   main
🎤 URL for centralized logging.
   DLS

@GDYendell
Copy link
Member

🎤 URL for centralized logging.
DLS

What is this?

I think this is better. The only thing I would question is that it is halfway between being generic and being DLS-specific. I don't think this would be used by an external site as is, so we could either make it more convenient to use at DLS (more strict defaults instead of saying "at DLS ..."), or make it completely generic and then probably write some internal documentation to know what to use at DLS.

copier.yml Show resolved Hide resolved
copier.yml Outdated Show resolved Hide resolved
copier.yml Outdated
@@ -147,11 +136,11 @@ services_repo:

services_release:
type: str
help: The initial release of the services repository to track e.g. "2024.1.1"
help: The initial release of the services repository to track e.g. "2024.12.1" or "main"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Im second guessing the use of "initial". Should updates to the release not be done by a copier update as best practice?

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 dont think so - this is just what you will start with. I think that is what Initial means ?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes that is currently what is implied - but the question is should it? Should we not encourage updating the release rather through a copier update?

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 feel that dirties the idea of what the template is for. But that's because I've not considered using this way before. But I think I prefer the idea that ec updates what we track, the template updates what the generic parts of the repo look like.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Thats fine. Its not used in more places so copier probably wont break. I imagine ec only updating on a service level though so its two different places

template/apps/values.yaml.jinja Show resolved Hide resolved
template/apps.yaml.jinja Show resolved Hide resolved
@gilesknap
Copy link
Member Author

gilesknap commented Nov 26, 2024

I don't think this would be used by an external site as is, so we could either make it more convenient to use at DLS (more strict defaults instead of saying "at DLS ..."), or make it completely generic and then probably write some internal documentation to know what to use at DLS.

I think this is a valid point and I considered switching to totally DLS specific for this for the moment. We could always make a new more generic version if anyone ever ends up adopting.

Making it DLS specific removes around half of the questions

But I have tried to make epics-containers site agnostic - I think it is fair to have 'at DLS we would use this' because it is a useful example to DLS people and outside users.

So I vote for sticking with what this PR has:

  • mostly generic choices (but with namespaces and projects fixed as equal)
  • hints that describe what we do at DLS

@GDYendell @marcelldls let me know if you feel differently.

@gilesknap
Copy link
Member Author

🎤 URL for centralized logging.
DLS

What is this?

IT is the Graylog URL used when you type ec log-history xxxx

@marcelldls
Copy link
Collaborator

So I vote for sticking with what this PR has:

  • mostly generic choices (but with namespaces and projects fixed as equal)
  • hints that describe what we do at DLS

I agree that the PR does this. Its a decent middle ground. Changes LGTM

@gilesknap
Copy link
Member Author

Thanks @marcelldls. Merging.

@gilesknap gilesknap merged commit 73d8514 into main Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tidy and Simplify
3 participants