我创建了一个管理员用户的密码,其中包含一个特殊的字符。Gitea的安装是成功的,但我无法登录。我不能获得新密码,因为上面写着:
对不起,“注册邮件确认”已被禁用。
我试过命令gitea admin change-password,但是命令不被识别。
发布于 2021-01-09 17:36:20
这是现在的未来,其他的答案将不再有效。我找到这个答案是因为我有同样的问题。我知道我会再搞砸这件事,因为这已经是我的第二次了,所以你好,未来我!
非码头人士答覆:
gitea admin user change-password -u <username> -p <password>码头工人答覆:
docker exec -it <container ID> su git bash -c "gitea admin user change-password -u <username> -p <password>"用适当的值替换<container ID>、<username>和<password>。
发布于 2018-03-04 21:38:20
在你的问题中,任何gitea命令(如gitea admin change-password --username myusername --password asecurenewpassword)都以以下方式结束:
gitea: command not found如果您是从二进制安装,您将注意到$PATH没有被修改,gitea是直接从其安装文件夹调用的。
./gitea web因此,对于更改密码,您也可以这样做:
cd /path/to/gitea
./gitea admin change-password --username myusername --password asecurenewpassword请注意,罗伯特·兰詹添加了注释:
/path/to/gitea是gitea的主路径,在这里您可以找到文件夹custom。 就我而言,吉蒂亚的家是/var/lib/gitea。在这个路径中,您应该看到文件:custom/conf/app.ini,这在默认情况下是预期的。
发布于 2019-04-15 04:47:31
对于当前的GITEA,有时它将不起作用
cd /path/to/gitea
./gitea admin change-password --username myusername --password asecurenewpassword您还需要指定配置,例如:
cd /path/to/gitea
./gitea admin change-password --username myusername --password asecurenewpassword -c "/etc/gitea/app.ini"https://stackoverflow.com/questions/49057558
复制相似问题