dify icon indicating copy to clipboard operation
dify copied to clipboard

Can't open homepage because of a wrong linkage 127.0.0.1:9000 at 22:00 2024-06-29

Open Tommickey2020gmail opened this issue 1 year ago • 8 comments

Self Checks

  • [X] This is only for bug report, if you would like to ask a question, please head to Discussions.
  • [X] I have searched for existing issues search for existing issues, including closed ones.
  • [X] I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [X] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • [X] Please do not modify this template :) and fill in all the required fields.

Dify version

0.6.12

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

  1. cd docker cp .env.example .env docker compose up -d
  2. open homepage
  3. check browse development page, some links forward to 127.0.0.1:9000

✔️ Expected Behavior

link to api:5001

❌ Actual Behavior

can not open homepage

Tommickey2020gmail avatar Jun 29 '24 14:06 Tommickey2020gmail

Hey @Tommickey2020gmail, by default, you should be able to access the local deployment at http://127.0.0.1, with the default port being 80. If you have more info, pls share it with us!

takatost avatar Jun 29 '24 17:06 takatost

Hey @Tommickey2020gmail, by default, you should be able to access the local deployment at http://127.0.0.1, with the default port being 80. If you have more info, pls share it with us!

Please find the error information when open homepage: 搜狗截图20240630181853

Tommickey2020gmail avatar Jun 30 '24 10:06 Tommickey2020gmail

Hey @Tommickey2020gmail, by default, you should be able to access the local deployment at http://127.0.0.1, with the default port being 80. If you have more info, pls share it with us!

same issue: can not access 模型供应商 page, 搜狗截图20240630194809

Tommickey2020gmail avatar Jun 30 '24 11:06 Tommickey2020gmail

Hey, can u paste the logs for the api service container? It'd help us pinpoint the issue.

Also, 0.6.12-fix1 is out! It fixes some bugs, so maybe try updating too.

takatost avatar Jun 30 '24 12:06 takatost

Hey, can u paste the logs for the api service container? It'd help us pinpoint the issue.

Also, 0.6.12-fix1 is out! It fixes some bugs, so maybe try updating too.


$ docker logs docker-api-1 Running migrations None of PyTorch, TensorFlow >= 2.0, or Flax have been found. Models won't be available and only tokenizers, configuration and file/data utilities can be used. Preparing database migration... Database migration skipped None of PyTorch, TensorFlow >= 2.0, or Flax have been found. Models won't be available and only tokenizers, configuration and file/data utilities can be used. [2024-06-30 13:37:54 +0000] [91] [INFO] Starting gunicorn 22.0.0 [2024-06-30 13:37:54 +0000] [91] [INFO] Listening at: http://0.0.0.0:5001 (91) [2024-06-30 13:37:54 +0000] [91] [INFO] Using worker: gevent [2024-06-30 13:37:54 +0000] [174] [INFO] Booting worker with pid: 174 2024-06-30 13:39:19,211.211 ERROR [Dummy-1] [app.py:838] - Exception on /console/api/apps [GET] Traceback (most recent call last): File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 146, in init self._dbapi_connection = engine.raw_connection() File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 3300, in raw_connection return self.pool.connect() File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 449, in connect return _ConnectionFairy._checkout(self) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 1263, in _checkout fairy = _ConnectionRecord.checkout(pool) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 712, in checkout rec = pool._do_get() File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/impl.py", line 179, in _do_get with util.safe_reraise(): File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/util/langhelpers.py", line 146, in exit raise exc_value.with_traceback(exc_tb) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/impl.py", line 177, in _do_get return self._create_connection() File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 390, in _create_connection return _ConnectionRecord(self) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 674, in init self.__connect() File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 900, in __connect with util.safe_reraise(): File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/util/langhelpers.py", line 146, in exit raise exc_value.with_traceback(exc_tb) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/pool/base.py", line 896, in __connect self.dbapi_connection = connection = pool._invoke_creator(self) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/engine/create.py", line 643, in connect return dialect.connect(*cargs, **cparams) File "/app/api/.venv/lib/python3.10/site-packages/sqlalchemy/engine/default.py", line 620, in connect return self.loaded_dbapi.connect(*cargs, **cparams) File "/app/api/.venv/lib/python3.10/site-packages/psycopg2/init.py", line 122, in connect conn = _connect(dsn, connection_factory=connection_factory, **kwasync) psycopg2.OperationalError: could not translate host name "db" to address: Name or service not known

Tommickey2020gmail avatar Jun 30 '24 13:06 Tommickey2020gmail

I have the same problem. The API does not start or writes the following error message. This means that the web frontend cannot access the API.

api-1         | None of PyTorch, TensorFlow >= 2.0, or Flax have been found. Models won't be available and only tokenizers, configuration and file/data utilities can be used.
api-1         |
api-1         | Aborted!

PKuebler avatar Jul 01 '24 14:07 PKuebler

From the logs you provide, it seems a network issue with the docker. And it failed to locate the db.

crazywoola avatar Jul 09 '24 14:07 crazywoola

I have the same problem. The API does not start or writes the following error message. This means that the web frontend cannot access the API.

api-1         | None of PyTorch, TensorFlow >= 2.0, or Flax have been found. Models won't be available and only tokenizers, configuration and file/data utilities can be used.
api-1         |
api-1         | Aborted!

This seems to be another problem, maybe it's related to the arch of the computer.

crazywoola avatar Jul 09 '24 14:07 crazywoola