LoginSignup
1
0

More than 1 year has passed since last update.

Socket.IO サーバーのパスをドメインのサブディレクトリにした場合の Socket.IO Admin UI の接続方法

Last updated at Posted at 2022-11-05

前提

自分で建てたSocket.IOサーバーのURLが
https://hoge.com/fuga/socket.io
だったとする

サーバー側設定

instrument(io, {
  namespaceName: "/fuga/admin",
  auth: {
    type: "basic",
    username: {任意},
    password: {任意},
  },
});

username は完全任意だが、basic認証にした場合の password 設定方法は公式ドキュメントを参照
https://socket.io/docs/v4/admin-ui/#auth

Socket.IO Admin UI の接続設定

image.png

設定項目
Server URL https://hoge.com
Username サーバー側設定と同じ
Password サーバー側設定と同じ
Advanced options チェックを入れる
WebSocket only? チェックを入れる
Admin namespace /fuga/admin
Path /fuga/socket.io
Parser Built-in parser

WebSocket only? 以下の項目は Advanced options にチェックを入れると出現する

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0