AirVideoサーバーの設定

AirVideoサーバーとは

サーバーに保存された動画をiPhoneやiPad用に変換しながらストリーミング配信するサーバ。

インストール

リポジトリを登録してインストール。

$ sudo apt-get install python-software-properties
$ sudo apt-add-repository ppa:rubiojr/airvideo
$ sudo apt-get update
$ sudo apt-get install airvideo-server

ファイヤーウォールの設定

ファイヤーウォールを設定している場合は、以下のコマンドでポートを開けます。

$ sudo ufw allow 45631
$ sudo ufw status

To                         Action      From
--                         ------      ----
80                         ALLOW       Anywhere
443                        ALLOW       Anywhere
22                         ALLOW       Anywhere
139                        ALLOW       Anywhere
445                        ALLOW       Anywhere
21                         ALLOW       Anywhere
989                        ALLOW       Anywhere
990                        ALLOW       Anywhere
45631                      ALLOW       Anywhere

設定とテスト

設定ファイルを作成します。

$ sudo vi /opt/airvideo-server/my.properties

パスワード(password)と、動画のフォルダ(folders)を自分の環境に合わせ修正。
動画のフォルダは、フォルダ名1:パス1,フォルダ名2:パス2…とカンマ区切りで指定可能。

path.ffmpeg = /opt/airvideo-server/bin/ffmpeg
path.mp4creator = /usr/bin/mp4creator
path.faac = /usr/bin/faac
password = xxxxx
subtitles.encoding = windows-1250
subtitles.font = Verdana
folders = PV:/var/samba/public/movie/PV,MOVIE:/var/samba/public/movie/MOVIE

テスト起動を行い、iPhoneやiPadから繋がることを確認してください。

$ cd /opt/airvideo-server
$ java -jar AirVideoServerLinux.jar my.properties

バックグラウンドでの動作

$ sudo vi /etc/init/airvideo.conf

hogehogの部分はユーザ名。

start on runlevel [2345]
stop on shutdown
respawn

exec sudo -H -n -u hogehoge env LANG=ja_JP.UTF-8 \
`which java` -jar /opt/airvideo-server/AirVideoServerLinux.jar \
/opt/airvideo-server/my.properties
上記ファイルを作り、以下のコマンドで起動します。
$ sudo start airvideo

ubuntu/v1010/airvideoサーバーの設定.txt · 最終更新: 2018/03/18 09:56 (外部編集)
 
特に明示されていない限り、本Wikiの内容は次のライセンスに従います: CC Attribution-Share Alike 4.0 International
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki