ezstream-full.xml 4.24 KB
Newer Older
1
2
<?xml version="1.0" encoding="UTF-8"?>

3
4
<!--
  EXAMPLE: A valid configuration that contains every configuration option
5
6
7

  NB: /ezstream/metadata/program is commented out so that this configuration
      can work without scripting.
8
9
10
  -->

<!-- Ezstream configuration root element -->
11
12
<ezstream>

13
14
15
  <!--
    Server configuration
    -->
16
  <server>
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
    <!-- Transport protocol: HTTP, HTTPS -->
    <protocol>HTTP</protocol>
    <!-- Server address -->
    <hostname>127.0.0.1</hostname>
    <!-- Server port -->
    <port>8000</port>

    <!-- Login user -->
    <user>source</user>
    <!-- Login password (check file permissions, or everyone can see this) -->
    <password>hackme</password>

    <!--
      Directory to use for server certificate verification in "hash format".
      See openssl(1)/verify(1) for details:
      -->
    <ca_dir>/etc/ssl/certs</ca_dir>

    <!--
      CA bundle for both server certificate verification and building the
      client certificate chain.
      -->
    <ca_file>/etc/ssl/certs/ca-certificates.crt</ca_file>

    <!-- Client certificate (with public key) for authentication -->
    <client_cert>/etc/ssl/ezstream.crt</client_cert>

    <!-- Client private key for authentication -->
    <client_key>/etc/ssl/private/ezstream.key</client_key>

    <!-- Number of reconnection attempts, before giving up: -->
    <reconnect_attempts>0</reconnect_attempts>
49
50
  </server>

51
52
53
  <!--
    Stream configuration
    -->
54
  <stream>
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
    <!-- Mount point on server -->
    <mountpoint>/stream.ogg</mountpoint>

    <!-- Various informational settings -->
    <name>Test Stream</name>
    <url>http://localhost:8000/</url>
    <genre>Beeps</genre>
    <description>Test tones and noise</description>
    <quality>1.5</quality>
    <bitrate>16</bitrate>
    <samplerate>44100</samplerate>
    <channels>2</channels>

    <!-- Setting to allow stream to be listed in public YP directory -->
    <server_public>No</server_public>

    <!-- Stream format: Vorbis, MP3, Theora -->
    <format>Vorbis</format>

    <!-- Encoder name (defined below) to use for (re)encoding -->
    <encoder>OggEnc-Q1.5</encoder>
76
77
  </stream>

78
79
80
  <!--
    Media configuration
    -->
81
  <media>
82
83
84
85
86
87
88
89
90
91
92
    <!-- Media type: autodetect, file, playlist, program, stdin -->
    <type>autodetect</type>

    <!-- Input file or program name -->
    <filename>playlist.m3u</filename>

    <!-- Setting to shuffle playlists -->
    <shuffle>Yes</shuffle>

    <!-- Setting whether to stream input indefinitely or only once -->
    <stream_once>No</stream_once>
93
94
  </media>

95
96
97
  <!--
    Metadata configuration
    -->
98
  <metadata>
99
100
101
102
103
104
105
106
107
108
109
110
111
112
    <!-- Program to query for metadata instead of from media files -->
    <!-- <program>metadata.sh</program> -->

    <!-- Metadata format -->
    <format_str>@a@ - @t@</format_str>

    <!-- Interval for additional metadata refreshes (-1 for none) -->
    <refresh_interval>-1</refresh_interval>

    <!-- Setting to clean up extraneous whitespace -->
    <normalize_strings>Yes</normalize_strings>

    <!-- Setting to suppress all metadata udpates -->
    <no_updates>No</no_updates>
113
114
  </metadata>

115
116
117
  <!--
    Decoder configurations
    -->
118
119
  <decoders>
    <decoder>
120
121
122
      <!-- Decoder name -->
      <name>OggDec</name>
      <!-- Program and options -->
123
      <program>oggdec -R -b 16 -e 1 -s 1 -o - @T@</program>
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
      <!-- File extensions to use this decoder for -->
      <file_ext>.ogg</file_ext>
      <file_ext>.oga</file_ext>
    </decoder>

    <decoder>
      <name>MadPlay</name>
      <program>madplay -b 16 -R 44100 -S -o raw:- @T@</program>
      <file_ext>.mp3</file_ext>
    </decoder>

    <decoder>
      <name>Flac</name>
      <program>flac -s -d --force-raw-format --sign=signed --endian=little -o - @T@</program>
      <file_ext>.flac</file_ext>
139
140
141
    </decoder>
  </decoders>

142
143
144
  <!--
    Encoder configurations
    -->
145
146
  <encoders>
    <encoder>
147
148
149
150
151
152
153
154
155
156
157
158
      <!-- Encoder name -->
      <name>OggEnc-Q1.5</name>
      <!-- Output stream format -->
      <format>Vorbis</format>
      <!-- Program and options -->
      <program>oggenc -r -B 16 -C 2 -R 44100 --raw-endianness 0 -q 1.5 -t @M@ -</program>
    </encoder>

    <encoder>
      <name>Lame-CBR128</name>
      <format>MP3</format>
      <program>lame --preset cbr 128 -r -s 44.1 --bitwidth 16 - -</program>
159
160
161
162
    </encoder>
  </encoders>

</ezstream>