2020年末から開発されているビデオカンファレンスソフトウェア. Go製MITライセンス.
Galèneはエンドツーエンド暗号化はされない.サーバーで権限があればデータを覗き見ることが可能.
公式テストサーバ: https://galene.org:8443/
※要Go 1.13以降
$ git clone https://github.com/jech/galene $ cd galene $ CGO_ENABLED=0 go build -ldflags='-s -w'
linux/arm6向けにbuild(Raspberry Pi 1等)
$ GOARCH="arm" GOOS="linux" GOARM=6 CGO_ENABLED=0 go build -o galene_arm6_linux -ldflags='-s -w'
linux/arm7向けにbuild(Raspberry Pi 2等)
$ GOARCH="arm" GOOS="linux" GOARM=7 CGO_ENABLED=0 go build -o galene_arm7_linux -ldflags='-s -w'
linux/arm64向けにbuild(Raspberry Pi 2 model B 1.2〜 + 64bitOS等)
$ GOARCH="arm64" GOOS="linux" CGO_ENABLED=0 go build -o galene_arm64_linux -ldflags='-s -w'
※バイナリ以外に「static data groups」ディレクトリも必要.(groupsは下で作成している)
※Linux/mips, Windowsなどでも動作するらしい.
$ ./galene -h Usage of ./galene: -cpuprofile file store CPU profile in file -data directory data directory (default "./data/") -groups directory group description directory (default "./groups/") -http address web server address (default ":8443") -insecure act as an HTTP server rather than HTTPS -mdns gather mDNS addresses -memprofile file store memory profile in file -mutexprofile file store mutex profile in file -recordings directory recordings directory (default "./recordings/") -relay-only require use of TURN relays for all media traffic -static directory web server root directory (default "./static/") -turn address built-in TURN server address ("" to disable) (default "auto") -udp-range range UDP port range
test
というグループを作成するときの例
$ mksir groups $ vi groups/test.json
groups/test.json
{ "op": [{"username": "admin", "password": "1234"}], "presenter": [{}] }
$ ./galene
OR
「Group: test」
グループに参加した状態
右上の「︙(Setting)」からビデオやマイクの設定変更などが出来る.
※Activity detection
はFirefoxでは動作しない
右上の「Disable」で一時的に離脱?(自分のカメラ,マイクともに無効になるが視聴は可能)
「Mute」でマイクミュート
「Share Screen」で画面共有.同時に複数画面の共有も複数人での画面共有も可能
※画面共有終了はブラウザ内の画面共有画面の☓で行う,ウェブブラウザの共有停止ボタンを押すとウェブブラウザが落ちた(Linux上のChromiumベースのBrave 1.39.122)
マイクOnでカメラだけをOffにしたい場合,Setting → Camera Off
※モバイルブラウザでは画面共有は動作しない
/help: display this help /leave: leave group /msg user message: send a private message /presentfile: broadcast a video or audio file /raise: raise hand /renegotiate: renegotiate media streams /sendfile user: send a file (this will disclose your IP address) /unraise: unraise hand
いくつかの機能はメンバーリストからも操作できる
/helpに出てこないコマンド
※録画には allow-recording
の権限が必要,録画ファイルは recordings/グループ名/
以下に保存される
$ ls -s recordings/test/ total 1924 64 2022-06-19T00:07:38.797-jch.webm 4 2022-06-19T00:09:22.872-hoge.webm 4 2022-06-19T00:09:23.209-hoge.webm 1848 2022-06-19T00:09:27.458-hoge.webm 4 2022-06-19T00:10:03.374-jch.webm
※指定後ビデオの再起動(Disable/Enable)が必要
最低でも TCP: 8443
が必要
$ rsync -avcP galene static data groups galene@server.example.org:~
証明書をdata以下にコピー
ssh galene@server.example.org sudo install -m 400 -o `id -u` -g `id -g` /etc/letsencrypt/live/server.example.org/fullchain.pem data/cert.pem sudo install -m 400 -o `id -u` -g `id -g` /etc/letsencrypt/live/server.example.org/privkey.pem data/key.pem
※証明書ファイルがない場合起動時に毎回自己証明書が作られる
グローバル設定ファイル
.data/config.json
{ "canonicalHost": "galene.example.org", "admin":[{"username":"root","password":"secret"}] }
NOTE: canonicalHost
を間違えるとブラウザにキャッシュされてしまい面倒><
グループ設定
.groups/groupname.json
{ "op": [{"username":"jch","password":"1234"}], "presenter": [{}], "allow-recording": true, "allow-anonymous": true, "allow-subgroups": true, "public": true, "displayName": "Galenサンプル", "contact": "galene@example.org", "comment": "コメント", "codecs": ["vp8", "opus"] }
ユーザーの種類
詳細は README
を参照のこと
Galeneを実行
$ ulimit -n 65536 $ nohup ./galene &
3接続,ビデオx2,画面共有x1でしばらく動かしているGalèneのメモリ状況
$ pmap -x `pgrep galene` 196679: ./galene Address Kbytes RSS Dirty Mode Mapping 0000000000400000 4932 4928 0 r-x-- galene 00000000008d1000 4760 4724 0 r---- galene 0000000000d77000 272 272 84 rw--- galene 0000000000dbb000 276 108 108 rw--- [ anon ] 000000c000000000 16384 13076 13076 rw--- [ anon ] 000000c001000000 10240 2008 2008 rw--- [ anon ] 000000c001a00000 2048 0 0 rw--- [ anon ] 000000c001c00000 36864 0 0 ----- [ anon ] 00007f5da6ef0000 40132 11096 11096 rw--- [ anon ] 00007f5da9621000 263680 0 0 ----- [ anon ] 00007f5db97a1000 4 4 4 rw--- [ anon ] 00007f5db97a2000 293564 0 0 ----- [ anon ] 00007f5dcb651000 4 4 4 rw--- [ anon ] 00007f5dcb652000 36692 0 0 ----- [ anon ] 00007f5dcda27000 4 4 4 rw--- [ anon ] 00007f5dcda28000 4580 0 0 ----- [ anon ] 00007f5dcdea1000 4 4 4 rw--- [ anon ] 00007f5dcdea2000 508 0 0 ----- [ anon ] 00007f5dcdf21000 384 44 44 rw--- [ anon ] 00007ffc949c7000 132 12 12 rw--- [ stack ] 00007ffc949f1000 16 0 0 r---- [ anon ] 00007ffc949f5000 8 4 0 r-x-- [ anon ] ---------------- ------- ------- ------- total kB 715488 36288 26444
5人前後で繋いでいたVPSでのリソース状況(17:00過ぎから)
$ git clone https://github.com/garage44/pyrite $ cd pyrite/docker $ PYRITE_UID=`id -u` PYRITE_GID=`id -g` docker-compose up $ xdg-open http://localhost:3030/
OBS studioからローカルに配信してgalene-streamからGaleneに配信というのがよくある利用法だったと思うが,現在はOBS studioに仮想カメラ機能がついたのでそちらのほうが便利かもしれない.でもファイルやストリーミングをGaleneに配信するのに便利.
導入
$ sudo apt install python3-pip python3-gi python3-gi-cairo python3-websockets gir1.2-gst-plugins-bad-1.0 gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav gstreamer1.0-nice $ pip3 install --user galene-stream
help
$ galene-stream -h usage: galene-stream [-h] [--debug] -i INPUT -o OUTPUT [-b BITRATE] -g GROUP -u USERNAME [-p PASSWORD] Galène stream gateway. optional arguments: -h, --help show this help message and exit --debug debug mode: show debug messages -i INPUT, --input INPUT URI to use as GStreamer "uridecodebin" module input, e.g. "rtmp://localhost:1935/live/test" -o OUTPUT, --output OUTPUT Galène server to connect to, e.g. "wss://galene.example.com/ws" -b BITRATE, --bitrate BITRATE VP8 encoder bitrate in bit/s, you should adapt this to your network, default to 1048576 -g GROUP, --group GROUP Join this group -u USERNAME, --username USERNAME Group username -p PASSWORD, --password PASSWORD Group password
ローカルの udp://localhost:8888/
を galene.example.com:8443
の test
グループに bot
ユーザで転送
$ galene-stream --input "udp://localhost:8888" --output "wss://galene.example.com:8443/ws" --group test --username bot
ファイルをストリームする
$ galene-stream --debug --input "file:///mnt/home/matoken/Videos/HELLO.webm" --output "wss://galene.example.com:8443/ws" --group test --username bot
smg://〜
などもokだった
アスペクト比が合わなくて左右が切られてしまう場合.
テキストチャットで以下のコマンドで送信解像度を指定する.以下は640×320の場合.
/set resolution [640, 320]
この後,手動でビデオの再接続を行う.
今の所Galèneはモバイルブラウザでは画面共有が出来ない.
Androidで画面をスクリーンキャストするアプリケーションはいくつかあるようなので,これとgalene-streamを組み合わせることでAndroidの画面をGalèneに流すことができそう(未検証)
PHP製のGalène roomsや,
Nodejs製のGalène代替フロントエンドのPyriteにもグループ編集機能がある
<IfModule mod_ssl.c> <VirtualHost *:443> ServerAdmin webmaster@localhost DocumentRoot /var/www/html/meet ErrorLog ${APACHE_LOG_DIR}/galene/error.log CustomLog ${APACHE_LOG_DIR}/galene/access.log combined ServerName galene.serveur.com SSLCertificateFile /etc/letsencrypt/live/galene/fullchain.pem SSLCertificateKeyFile /etc/letsencrypt/live/galene/privkey.pem Include /etc/letsencrypt/options-ssl-apache.conf RewriteEngine on RewriteCond %{HTTP:UPGRADE} ^WebSocket$ [NC] RewriteCond %{HTTP:CONNECTION} ^Upgrade$ [NC] RewriteRule .* ws://localhost:3000%{REQUEST_URI} [P] SSLProxyEngine on SSLProxyVerify none SSLProxyCheckPeerCN off SSLProxyCheckPeerName off SSLProxyCheckPeerExpire off ProxyPassMatch ^/(ws)$ ws://localhost:3000/$1
受信側は,Setting → Receive:で「audio only」で声だけ聞くようにしたり,「screen share (low)」で声と画面共有(低画質)を視聴するなど出来る.
送信側は,Setting → Camera → offでカメラをoffに出来る.カメラの画質はSend:で「lowest」や「low」にすることで帯域を節約できる.
未対応
Pyriteはi18nに対応して現在3ヶ国語に対応している
Stylusでも実現できる?
Galène以外の方法を使う
コメント