feat: support templates #235
No reviewers
Labels
No Label
has
backport
in progress
invalid
kind
breaking
kind
bug
kind
build
kind
dependency
kind
deployment
kind
docs
kind
enhancement
kind
feature
kind
lint
kind
proposal
kind
question
kind
refactor
kind
security
kind
testing
kind
translation
kind
ui
need
backport
priority
critical
priority
low
priority
maybe
priority
medium
reviewed
duplicate
reviewed
invalid
reviewed
wontfix
skip-changelog
status
blocked
status
needs-feedback
status
needs-reviews
status
wip
upstream
gitea
upstream
other
No Milestone
No Assignees
5 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: gitea/helm-chart#235
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "volker.raschek/helm-chart:feat/custom-labels"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hi @lunny and @justusbunsi,
this patch support the creation of template files for repository labels and the
.gitignore
,LICENSE
andREADME.md
files, which can be selected during the create of a new repository.Sideeffect of the PR is, that the the directory structure, created via kubernetes, is also listed in the drop down menue. Here a screenshot of my custom labels grouped as
myLabels
. This listing issue should be fixed directly via gitea. Here the related issue.Local files that should be excluded on a local machine could be added to .git/info/exclude file. That way it would keep the gitignore file clean. But I don't block this if it's kept that way. ?
Is there a reason to have several dedicated configmaps instead one customizing configmaps storing all those values? Would this make it more complicated to implement?
Hi @justusbunsi,
I tried first to use only one config map. With for example
labels/{{ key }}: {{ value }}
,gitignore/{{ key }}: {{ value }}
and so on as key value pairs. But the slash, which is required to place the file into the right directory is an unsupported char.Fot this reason I decided to create seperate config maps. I am open for suggestions for improvements if you or another developer has a better idea to solve the problem.
I wasn't aware of the required folder structure. That is a good point against one single configmap.
It could be possible to use key prefixes such as
labels_
and so on to distinguish between the different subdirectory structure. This would require using an additional init container to provide a corresponding file structure to Gitea or extend an existing one. As Gitea resolves symlinks (files colocated with..data
directory are and they do work in the drop down), we could work with symlinks inside anemptydir
with the correct directory structure. IIRC anemptydir
type doesn't contain that..data
folder and it would be possible to prevent having those in the drop down list.This implies a more complex implementation than just mount the configmaps to the correct place and I'm not 100% sure that this is really a good end result. What do you think @luhahn?
Hi and sorry for the late response. I was in hospital and therefore unavailable. Trying to catch up with the PRs right now :)
@volker.raschek
@justusbunsi
Wouldn't it be possible to just use a configmap like this:
And in the statefulset:
Not sure if Kubernetes interprets it that way. AFAIK the root key in the data area is the file name. Anything inside is considered file content. But I haven't tested it, so maybe it's something I didn't knew?
@ -471,0 +507,4 @@
#598546 renovate/rebase ; Rebase branch on base branch via renovate
```
#### Lizense templates
License
@volker.raschek Lot's of conflicts meanwhile but - any plans to continune here? :) I think the general concept/idea would definitely be a nice feature/enhancement.
Closing here after no response, feel free to open again if desired @volker.raschek.
Pull request closed