flock icon indicating copy to clipboard operation
flock copied to clipboard

login username and password

Open ma14ch opened this issue 8 months ago • 8 comments

how to login after installation?

ma14ch avatar Apr 20 '25 12:04 ma14ch

how to login after installation?

The admin username and password settings are in the .env file, and by default, they are:

[email protected] FIRST_SUPERUSER_PASSWORD=123456

if you haven't modified them.

Onelevenvy avatar Apr 20 '25 12:04 Onelevenvy

Oh I see, but there is an error while logging in, it says:

Image

ma14ch avatar Apr 20 '25 13:04 ma14ch

Is it deployed on a local or remote server? What error does the front-end login page show?

Onelevenvy avatar Apr 20 '25 13:04 Onelevenvy

Is it deployed on a local or remote server? What error does the front-end login page show?

If you're using a remote server, you need to change "localhost" to your server's IP address in the .env file for the following settings:

API_URL=http://localhost:8000/

NEXT_PUBLIC_API_URL=http://localhost:8000/

Onelevenvy avatar Apr 20 '25 13:04 Onelevenvy

it has no error message on front end, I'll check the your hint

ma14ch avatar Apr 20 '25 13:04 ma14ch

same:

Image

Image

Image

ma14ch avatar Apr 20 '25 13:04 ma14ch

It should be an issue with my code. From the image you provided, I can see that your frontend address is ai:3000 I haven't tested whether the server name: port could be the problem yet. So far, I’ve only tested the server IP: port setup, and it works. The issue seems to be that the frontend isn't connected to the backend, which is causing the problem. The 404 error from the backend is due to a health check, which is a bug and is unrelated to the frontend login issue.

Onelevenvy avatar Apr 20 '25 13:04 Onelevenvy

good luck mate, I'll check for updates :)

ma14ch avatar Apr 20 '25 14:04 ma14ch

你好 我ip地址+port方式遇到一样的问题,怎么解决

scholarlords avatar Jun 10 '25 09:06 scholarlords

你好 我ip地址+port方式遇到一样的问题,怎么解决

你好,docker还是源码,如果是源码临时改下下面的后端访问地址,我这几天彻底修复一下这个问题

Image

Image 如果是docker,需要等我修复后 build新镜像哈

Onelevenvy avatar Jun 10 '25 09:06 Onelevenvy

docker,具体问题在哪呢

---Original--- From: @.> Date: Tue, Jun 10, 2025 17:50 PM To: @.>; Cc: @.@.>; Subject: Re: [Onelevenvy/flock] login username and password (Issue #202)

Onelevenvy left a comment (Onelevenvy/flock#202)

你好 我ip地址+port方式遇到一样的问题,怎么解决

你好,docker还是源码,如果是源码临时改下下面的后端访问地址,我这几天彻底修复一下这个问题

image.png (view on web) 如果是docker,需要等我修复后 build新镜像哈

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

scholarlords avatar Jun 10 '25 09:06 scholarlords

原因应该是NEXT_PUBLIC_API_URL 这个环境变量有时候在docker里没用生效

Onelevenvy avatar Jun 10 '25 09:06 Onelevenvy

好滴,那等你更新吧

---Original--- From: @.> Date: Tue, Jun 10, 2025 17:56 PM To: @.>; Cc: @.@.>; Subject: Re: [Onelevenvy/flock] login username and password (Issue #202)

Onelevenvy left a comment (Onelevenvy/flock#202)

原因应该是NEXT_PUBLIC_API_URL 这个环境变量有时候在docker里没用生效

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

scholarlords avatar Jun 10 '25 09:06 scholarlords

好滴,那等你更新吧

你好,我没重新build,就用dockerhub现成的镜像,我昨晚重新测试了一下,windows的dockers,和linux的docker 在A主机部署(ip:192.168.1.95),B主机(ip:192.168.1.166)局域网访问都ok,你要不有空也重新试一下,步骤:

cd flock/docker

cp ../.env.example .env

# 也就是将.env文件拷贝到docker目录下,然后更改API_URL,NEXT_PUBLIC_API_URL 这两个环境变量为你部署主机的ip

# 比如我的是
API_URL=http://192.168.1.95:8000 
NEXT_PUBLIC_API_URL=http://192.168.1.95:8000

如果还有问题,如果方便可以贴下你的主机,docker,网络等配置信息,我尽力去修复

Onelevenvy avatar Jun 11 '25 00:06 Onelevenvy

我是内网

---Original--- From: @.> Date: Wed, Jun 11, 2025 08:41 AM To: @.>; Cc: @.@.>; Subject: Re: [Onelevenvy/flock] login username and password (Issue #202)

Onelevenvy left a comment (Onelevenvy/flock#202)

好滴,那等你更新吧 …

你好,我就用现成的镜像,我昨晚重新测试了一下,windows的dockers,和linux的docker 在A主机部署(ip:192.168.1.95),B主机(ip:192.168.1.166)局域网访问都ok,你要不有空也重新试一下,步骤: cd flock/docker cp ../.env.example .env # 也就是将.env文件拷贝到docker目录下,然后更改API_URL,NEXT_PUBLIC_API_URL 这两个环境变量为你部署主机的ip # 比如我的是 API_URL=http://192.168.1.166:8000 NEXT_PUBLIC_API_URL=http://192.168.1.166:8000
如果还有问题,如果方便可以贴下你的主机,docker,网络等配置信息,我尽力去修复

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

scholarlords avatar Jun 11 '25 06:06 scholarlords

我是内网

内网外网是一样的啊,只要设置API_URL=http://192.168.1.95:8000 NEXT_PUBLIC_API_URL=http://192.168.1.95:8000 为你部署机器的ip地址即可

Onelevenvy avatar Jun 11 '25 06:06 Onelevenvy

我再试试,还是not found404 

---Original--- From: @.> Date: Wed, Jun 11, 2025 14:38 PM To: @.>; Cc: @.@.>; Subject: Re: [Onelevenvy/flock] login username and password (Issue #202)

Onelevenvy left a comment (Onelevenvy/flock#202)

我是内网 …

内网外网是一样的啊,只要设置API_URL=http://192.168.1.95:8000 NEXT_PUBLIC_API_URL=http://192.168.1.95:8000 为你部署机器的ip地址即可

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

scholarlords avatar Jun 11 '25 06:06 scholarlords

什么原因呢

---Original--- From: @.> Date: Wed, Jun 11, 2025 14:38 PM To: @.>; Cc: @.@.>; Subject: Re: [Onelevenvy/flock] login username and password (Issue #202)

Onelevenvy left a comment (Onelevenvy/flock#202)

我是内网 …

内网外网是一样的啊,只要设置API_URL=http://192.168.1.95:8000 NEXT_PUBLIC_API_URL=http://192.168.1.95:8000 为你部署机器的ip地址即可

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

scholarlords avatar Jun 11 '25 08:06 scholarlords