首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >我可以使用HTTPS而不是HTTP来实现主机可用性吗?

我可以使用HTTPS而不是HTTP来实现主机可用性吗?
EN

Stack Overflow用户
提问于 2022-05-23 14:40:12
回答 1查看 555关注 0票数 0

我刚刚开始在我的Centos 7服务器上设置Flutter (信道稳定,3.0.0)。我已经设置了代理配置,并添加了铬作为连接设备。我没有安装Android,因为我不会在这个服务器上使用它。

使用以下命令运行我的时

代码语言:javascript
运行
复制
flutter run -d chrome

我得到以下错误:

代码语言:javascript
运行
复制
Proxy failed to establish tunnel (407 Proxy Authentication Required)
---- Log transcript ----
FINE: Pub 2.17.0
MSG : Resolving dependencies...
SLVR: fact: rob_chatbot is 1.0.0+1
SLVR: derived: rob_chatbot
SLVR: fact: rob_chatbot depends on flutter from sdk
SLVR: fact: rob_chatbot depends on cupertino_icons ^1.0.2
SLVR: fact: rob_chatbot depends on flutter_test from sdk
SLVR: fact: rob_chatbot depends on flutter_lints ^1.0.0
SLVR:   selecting rob_chatbot
SLVR:   derived: flutter_lints ^1.0.0
SLVR:   derived: flutter_test from sdk
SLVR:   derived: cupertino_icons ^1.0.2
SLVR:   derived: flutter from sdk
IO  : Get versions from https://pub.dartlang.org/api/packages/flutter_lints.
IO  : HTTP GET https://pub.dartlang.org/api/packages/flutter_lints
    | Accept: application/vnd.pub.v2+json
    | X-Pub-OS: linux
    | X-Pub-Command: get
    | X-Pub-Session-ID: 9143CA91-A5EC-4620-A2C9-817E982427C0
    | X-Pub-Environment: flutter_bot:flutter_cli:verify:run
    | X-Pub-Reason: dev
    | user-agent: Dart pub 2.17.0
IO  : Get versions from https://pub.dartlang.org/api/packages/lints.
IO  : HTTP GET https://pub.dartlang.org/api/packages/lints
    | Accept: application/vnd.pub.v2+json
    | X-Pub-OS: linux
    | X-Pub-Command: get
    | X-Pub-Session-ID: 9143CA91-A5EC-4620-A2C9-817E982427C0
    | X-Pub-Environment: flutter_bot:flutter_cli:verify:run
    | user-agent: Dart pub 2.17.0
SLVR: Version solving took 0:00:00.160384 seconds.
    | Tried 1 solutions.
FINE: Resolving dependencies finished (0.1s).
ERR : Proxy failed to establish tunnel (407 Proxy Authentication Required)
FINE: Exception type: ClientException
FINE: package:pub/src/source/hosted.dart 946:7                       HostedSource._throwFriendlyError
    | package:pub/src/source/hosted.dart 368:7                       HostedSource._fetchVersionsNoPrefetching
    | ===== asynchronous gap ===========================
    | dart:async                                                     Future.catchError
    | package:pub/src/utils.dart 109:52                              captureErrors.wrappedCallback
    | package:stack_trace                                            Chain.capture
    | package:pub/src/utils.dart 122:11                              captureErrors
    | package:pub/src/command.dart 183:13                            PubCommand.run
    | package:args/command_runner.dart 209:27                        CommandRunner.runCommand
    | package:pub/src/command_runner.dart 174:24                     PubCommandRunner.runCommand
    | package:pub/src/command_runner.dart 159:20                     PubCommandRunner.run
    | package:dartdev/dartdev.dart 45:56                             runDartdev
    | /b/s/w/ir/cache/builder/sdk/pkg/dartdev/bin/dartdev.dart 11:9  main
---- End log transcript ----

当我运行颤栗医生-v,我得到:

代码语言:javascript
运行
复制
[✓] Flutter (Channel stable, 3.0.0, on CentOS Linux 7 (Core) 3.10.0-1160.59.1.el7.x86_64, locale en_PH.UTF-8)
    • Flutter version 3.0.0 at /home/appadm/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ee4e09cce0 (2 weeks ago), 2022-05-09 16:45:18 -0700
    • Engine revision d1b9a6938a
    • Dart version 2.17.0
    • DevTools version 2.12.2

[✗] Android toolchain - develop for Android devices
    ✗ Unable to locate Android SDK.
      Install Android Studio from: https://developer.android.com/studio/index.html
      On first launch it will assist you in installing the Android SDK components.
      (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions).
      If the Android SDK has been installed to a custom location, please use
      `flutter config --android-sdk` to update to that location.


[✓] Chrome - develop for the web
    • Chrome at google-chrome

[!] Linux toolchain - develop for Linux desktop
    • clang version 3.4.2 (tags/RELEASE_34/dot2-final)
    • cmake version 3.22.4
    • ninja version 1.10.2
    • pkg-config version 0.27.1
    ✗ pkg-config 0.29.0 or later is required.

[!] Android Studio (not installed)
    • Android Studio not found; download from https://developer.android.com/studio/index.html
      (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions).

[✓] Proxy Configuration
    • HTTP_PROXY is set
    • NO_PROXY is localhost,127.0.0.1,::1,https://pub.dartlang.org
    • NO_PROXY contains localhost
    • NO_PROXY contains 127.0.0.1
    • NO_PROXY contains ::1

[✓] Connected device (2 available)
    • Linux (desktop) • linux  • linux-x64      • CentOS Linux 7 (Core) 3.10.0-1160.59.1.el7.x86_64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 101.0.4951.64

[!] HTTP Host Availability
    ✗ HTTP host "https://cocoapods.org/" is not reachable. Reason: An error occurred while checking the HTTP host: Proxy
      failed to establish tunnel (407 Proxy Authentication Required)
    ✗ HTTP host "https://maven.google.com/" is not reachable. Reason: An error occurred while checking the HTTP host:
      Proxy failed to establish tunnel (407 Proxy Authentication Required)
    ✗ HTTP host "https://pub.dev/" is not reachable. Reason: An error occurred while checking the HTTP host: Proxy
      failed to establish tunnel (407 Proxy Authentication Required)
    ✗ HTTP host "https://cloud.google.com/" is not reachable. Reason: An error occurred while checking the HTTP host:
      Proxy failed to establish tunnel (407 Proxy Authentication Required)

我找到了一个可以将https://pub.dartlang.org/添加到代理规则中的答案,尽管我不知道在哪里可以找到它。

EN

回答 1

Stack Overflow用户

发布于 2022-10-17 08:58:48

您的代理密码是否包含URL编码的符号,如@?使用不包含符号的密码。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/72350405

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档