cnoe-io / idpbuilder

Spin up a complete internal developer platform with only Docker required as a dependency.
https://cloud-native.slack.com/archives/C05TN9WFN5S
Apache License 2.0
149 stars 45 forks source link

change gitea username #304

Open nimakaviani opened 1 week ago

nimakaviani commented 1 week ago

Currently, the username for gitea is giteaAdmin. This causes some complications when using it for logging in and utilizing images in the gitea OCI registry. See here: https://github.com/cnoe-io/idpbuilder/pull/302#discussion_r1640460167

To simplify things, we should just rename the username from giteaAdmin to root and update references and instructions where necessary.

When fixing this, make sure you search for both giteaAdmin and giteaadmin references to fix them.

blakeromano commented 1 week ago
k logs my-gitea-8674989bbc-xp4cq -c configure-gitea
==== BEGIN GITEA CONFIGURATION ====
2024/06/18 03:49:49 ...2@v2.27.1/command.go:272:Run() [I] PING DATABASE sqlite3
2024/06/18 03:49:49 cmd/migrate.go:33:runMigrate() [I] AppPath: /usr/local/bin/gitea
2024/06/18 03:49:49 cmd/migrate.go:34:runMigrate() [I] AppWorkPath: /data
2024/06/18 03:49:49 cmd/migrate.go:35:runMigrate() [I] Custom path: /data/gitea
2024/06/18 03:49:49 cmd/migrate.go:36:runMigrate() [I] Log path: /data/log
2024/06/18 03:49:49 cmd/migrate.go:37:runMigrate() [I] Configuration file: /data/gitea/conf/app.ini
2024/06/18 03:49:49 ...2@v2.27.1/command.go:272:Run() [W] Table system_setting Column version db default is , struct default is 1
No admin user 'admin' found. Creating now...
Command error: CreateUser: name is reserved [name: admin]

I am not sure how feasible this is with gitea. This was based off a quick look at trying an idpbuilder create after changing the admin username.

Even after spinning up locally with giteaAdmin and attempting to create a manual admin user it doesn't seem to let me

Screenshot 2024-06-17 at 9 03 46 PM
nimakaviani commented 1 week ago

interesting! yeah. looks like the username cannot come from this reserved list. maybe we call it administrator or root? root might be shorter and easier. kind of a bummer though. would have been nice to have the same username between argocd and gitea. thoughts on calling it root?

tapas4java commented 1 week ago

Can we move keycloak as core application and let ArgoCD and Gitea use managed accounts similar to other apps? I think when we add deployment to remote cluster support, this workflow will be seemless.

nimakaviani commented 1 week ago

yeah we discussed this in the past. Problem is, we have users who have done integrations with other SSO providers, including Okta, Cognito, etc. Bringing Keycloak into the mix as a core package, makes it confusing if folks choose to enable alternative SSO solutions in other stacks.

nabuskey commented 1 week ago

root sounds better to me. Shorter and easier to type :)

cmoulliard commented 1 week ago

root sounds better to me. Shorter and easier to type :)

admin is the default standard ;-)

nimakaviani commented 1 week ago

@cmoulliard yeah admin would have been great but it is a reserved word. see this

cmoulliard commented 1 week ago

Let's then use one of the followings: adminuser, gitadmin, supervisor ?