GithubHelp home page GithubHelp logo

napcat-docker's People

Contributors

initialencounter avatar lietxia avatar mlikiowa avatar stapxs avatar wling-art avatar zanjie1999 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

napcat-docker's Issues

反向连接ws报错 Invalid URL

downloadPath /root/.config/QQ/NapCat/temp
{
  selfUin: '手动删除',
  selfUid: 'u_r0-e5BSdgvyhDTDjgrq1Zg',
  desktopPathConfig: { account_path: '/root/.config/QQ' },
  clientVer: '9.9.9-22578',
  a2: '',
  d2: '',
  d2Key: '',
  machineId: '',
  platform: 3,
  platVer: '5.15.0-91-generic',
  appid: '537213710',
  rdeliveryConfig: {
    appKey: '',
    systemId: 0,
    appId: '',
    logicEnvironment: '',
    platform: 3,
    language: '',
    sdkVersion: '',
    userId: '',
    appVersion: '',
    osVersion: '',
    bundleId: '',
    serverUrl: '',
    fixedAfterHitKeys: [ '' ]
  },
  defaultFileDownloadPath: '/root/.config/QQ/NapCat/temp',
  deviceInfo: {
    guid: '17755563-a24d-4005-aa53-1a462e014e70',
    buildVer: '3.2.7-22868',
    localId: 2052,
    devName: '09f5266a88e0',
    devType: 'Linux',
    vendorName: '',
    osVer: '5.15.0-91-generic',
    vendorOsName: 'Linux',
    setMute: false,
    vendorType: 0
  },
  deviceConfig: '{"appearance":{"isSplitViewMode":true},"msg":{}}'
}
linux-bugly: init bugly ...
InitBuglyManager
SetLogger
fatalSetup
GetDllPath: 33
pub_key_path: /opt/QQ/resources/app/pub.key
[BuglyManager.cpp][InitBuglyManager][212]InitBuglyManager path: /root/.config/QQ/crash_files/
BuglyManager/opt/QQ/resources/app/pub.key
[BuglyService.cpp][CreatDir][70]!!!begin to CreatDir 0: /root/.config/QQ/crash_files/
[BuglyService.cpp][registBugly][589]set signal stack
[BuglyService.cpp][registSignalHandler][520]regist native handler
registBugly/opt/QQ/resources/app/pub.key
[BuglyService.cpp][setParam][618]setParam, key:appVersion, value:9.9.9-22578..
setParam/opt/QQ/resources/app/pub.key
StartWithOptions s/opt/QQ/resources/app/pub.key
StartWithOptions e/opt/QQ/resources/app/pub.key
PostDelayedTask s/opt/QQ/resources/app/pub.key
PostDelayedTask e/opt/QQ/resources/app/pub.key
linux-bugly: init bugly done.
ob11 ready
get config {
  httpPort: 3000,
  httpPostUrls: [ '' ],
  httpSecret: '',
  wsPort: 3001,
  wsReverseUrls: [ 'WS_URLS' ],
  enableHttp: false,
  enableHttpPost: false,
  enableWs: false,
  enableWsReverse: true,
  messagePostFormat: 'array',
  reportSelfMessage: false,
  debug: false,
  enableLocalFile2Url: false,
  heartInterval: 60000,
  token: ''
}
开始连接反向ws WS_URLS
SyntaxError: Invalid URL: WS_URLS
    at initAsClient (/root/node_modules/ws/lib/websocket.js:692:13)
    at new WebSocket (/root/node_modules/ws/lib/websocket.js:85:7)
    at x5.connect (/root/napcat.cjs:3:387729)
    at new x5 (/root/napcat.cjs:3:385448)
    at /root/napcat.cjs:3:388899
    at new Promise (<anonymous>)
    at r5.start (/root/napcat.cjs:3:388735)
    at p5.onReady (/root/napcat.cjs:3:407062)
    at /root/napcat.cjs:3:106665
    at new Promise (<anonymous>)
ob11 msg listener added
ob11 buddy listener added
ob11 group listener added
login success
[BuglyManager.cpp][UploadBugly][107]!!!in UploadBugly.
[NativeCrashHandler.cpp][getCrashDetailBeanFromRecord][52]!!!! in NativeCrashHandler getCrashDetailBeanFromRecord, open file error!!!,dumpFilePath:/root/.config/QQ/crash_files/rqd_record.eup.
[NativeCrashHandler.cpp][uploadCrashEvent][331]get null crashDetailBean, return!

ws地址为

ws://172.17.0.4:8080/onebot/v11/ws

当在宿主机中直接clone napcatqq使用sh脚本启动时,没有报错(已配置反向ws地址)

使用docker启动后,请求被重置

docker compose HTTP POST

version: "3"
services:
napcat:
environment:
- ACCOUNT=<机器人qq>
- HTTP_ENABLE=true
- HTTP_POST_ENABLE=true
- HTTP_URLS="http://192.168.3.8:5140/onebot"
ports:
- 3000:3000
container_name: napcat
network_mode: bridge
image: mlikiowa/napcat-docker:latest
使用上述docker-compose启动后,

在宿主机上 发送
curl --request POST
--url http://127.0.0.1:3000/send_msg
--header 'Content-Type: application/json'
--header 'content-type: application/json'
--data '{
"message_type":"private",
"user_id": ******,
"message":"早上好"
}'

返回:curl: (56) Recv failure: Connection reset by peer

麻烦作者大大看看

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.