pf-hubs / chutvrc-hubs

Mozilla Public License 2.0
8 stars 4 forks source link

Sora/Dialogの接続情報(channel idなど)をadminから設定できるようにする #8

Open YHhaoareyou opened 1 year ago

YHhaoareyou commented 1 year ago

Setup > Server Settings が開かない問題を修正しないと

YHhaoareyou commented 1 year ago

Server Settings画面はitaという公開されていないコンポーネントからスキーマを取得しないと表示されないらしいです。 hubsのdiscord/GitHubのissueなどを見たら、「自前ホストなら自分でいじればいいじゃん」のような返答しか見つかりません... https://github.com/mozilla/reticulum/issues/465#issuecomment-1243081526

一応admin画面は作り直す予定はあるという情報がdiscordで流れていましたが、いつ実現するかはわかりません

なので今の時点でこの件を修正するには、itaを介したところを、別のAPIを定義してreticulumとhubsが直接やりとりするように置き換える作業が必要です。 先生にお願いがありますが、Server Settings画面に入っているフィールドを、スクショとかでも大丈夫なので、ご共有いただけませんでしょうか

YHhaoareyou commented 1 year ago

0207自分用メモ

table app_configs in postgres: Image

AppConfigSchema: Image

What to do for server config:

  1. Create migration file, reference: https://elixirschool.com/ja/lessons/ecto/basics#マイグレーション-3
  2. Edit migration file (following format’s shown in the image) to include ita schema
  3. Add fields for Sora & switch between dialog and Sora
  4. Create table
  5. Copy app_config.ex to server_config.ex and edit
  6. API for get & post for server_config
  7. Use server_config’s values in other parts of reticulum
YHhaoareyou commented 1 year ago

https://github.com/pf-hubs/mozilla-hubs-hubs/issues/12 でServer Settings編集機能が回復したら、こちらの実装が続けられる