Giter Club home page Giter Club logo

Comments (9)

Issues-translate-bot avatar Issues-translate-bot commented on June 20, 2024

Bot detected the issue body's language is not English, translate it automatically.


Title: [Bug] After updating the Docker image to 2.12.3, the PROXY_URL field cannot be used

from chatgpt-next-web.

liu0050 avatar liu0050 commented on June 20, 2024

我也遇到了同样的问题,升级到2.12.3版本后容器无法再使用主机的代理。
image

from chatgpt-next-web.

Issues-translate-bot avatar Issues-translate-bot commented on June 20, 2024

Bot detected the issue body's language is not English, translate it automatically.


I also encountered the same problem. After upgrading to version 2.12.3, the container can no longer use the host's agent.
image

from chatgpt-next-web.

fred-bf avatar fred-bf commented on June 20, 2024

@liu0050 @yangxiang92 would you mind try rebuild the latest commit's docker image to see whether the issue have been resolved?

from chatgpt-next-web.

yangxiang92 avatar yangxiang92 commented on June 20, 2024

@liu0050 @yangxiang92 would you mind try rebuild the latest commit's docker image to see whether the issue have been resolved?

I have rebuild docker image with the latest commit of "main" branch (commit id: 3866448).
The issue is not resolved yet.

from chatgpt-next-web.

nutinshell avatar nutinshell commented on June 20, 2024

Just remove the quotes from the proxychains -f $conf line in the Dockerfile. Fixed for me.

from chatgpt-next-web.

yangxiang92 avatar yangxiang92 commented on June 20, 2024

Just remove the quotes from the proxychains -f $conf line in the Dockerfile. Fixed for me.

But I need the proxy to access the OpenAI server...

from chatgpt-next-web.

nutinshell avatar nutinshell commented on June 20, 2024

Just remove the quotes from the proxychains -f $conf line in the Dockerfile. Fixed for me.

But I need the proxy to access the OpenAI server...

Yes, that's the right fix for proxy...

from chatgpt-next-web.

yangxiang92 avatar yangxiang92 commented on June 20, 2024

Just remove the quotes from the proxychains -f $conf line in the Dockerfile. Fixed for me.

But I need the proxy to access the OpenAI server...

Yes, that's the right fix for proxy...

Sorry, I misunderstood your meaning. Removing the quotes solves this issue! Thank you!

For reference, here is the modified content:

CMD if [ -n "$PROXY_URL" ]; then \
    export HOSTNAME="127.0.0.1"; \
    protocol=$(echo $PROXY_URL | cut -d: -f1); \
    host=$(echo $PROXY_URL | cut -d/ -f3 | cut -d: -f1); \
    port=$(echo $PROXY_URL | cut -d: -f3); \
    conf=/etc/proxychains.conf; \
    echo "strict_chain" > $conf; \
    echo "proxy_dns" >> $conf; \
    echo "remote_dns_subnet 224" >> $conf; \
    echo "tcp_read_time_out 15000" >> $conf; \
    echo "tcp_connect_time_out 8000" >> $conf; \
    echo "localnet 127.0.0.0/255.0.0.0" >> $conf; \
    echo "localnet ::1/128" >> $conf; \
    echo "[ProxyList]" >> $conf; \
    echo "$protocol $host $port" >> $conf; \
    cat /etc/proxychains.conf; \
    proxychains -f $conf node server.js --host 0.0.0.0; \
    else \
    node server.js; \
    fi

from chatgpt-next-web.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.