Puppet Class: jitsi::containerized_server
- Defined in:
- manifests/containerized_server.pp
Summary
Install Jitsi as a containerized serviceOverview
This class downloads definitions from github.com/jitsi/docker-jitsi-meet and performs basic settings to produce a simple working setup of jitsi. The code in the repository uses docker-compose to start the services as containers.
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 |
# File 'manifests/containerized_server.pp', line 78
class jitsi::containerized_server (
Integer $http_port,
Integer $https_port,
String $timezone,
String $public_url,
String $domain,
String $version,
String $jibri_domain,
Boolean $disable_all_audio_processing,
Boolean $disable_echo_cancellation,
Boolean $disable_noise_supression,
Boolean $disable_auto_gain_control,
Boolean $disable_high_pass_filter,
Boolean $enable_breakout_rooms,
String $jwt_app_id,
String $jwt_app_secret,
Integer $allow_guests,
Boolean $disable_third_party_requests,
Boolean $noisy_mic_detection,
Integer $video_resolution,
Boolean $start_muted,
Boolean $start_without_video,
Boolean $enable_prejoin_page,
Boolean $enable_simulcast,
Boolean $require_display_name,
Integer $channel_last_n,
Optional[Hash[String, Variant[Integer, String, Boolean]]] $custom_variables,
Boolean $compose_jigasi,
Boolean $compose_jibri,
Boolean $compose_etherpad,
) {
include docker
include docker::compose
$slug = "${module_name}-jitsi"
$jicofo_component_secret = extlib::cache_data($slug, 'jicofo_component_secret', extlib::random_password(48))
$jicofo_auth_password = extlib::cache_data($slug, 'jicofo_auth_password', extlib::random_password(48))
$jvb_auth_password = extlib::cache_data($slug, 'jvb_auth_password', extlib::random_password(48))
$jigasi_xmpp_password = extlib::cache_data($slug, 'jigasi_xmpp_password', extlib::random_password(48))
$jibri_recorder_password = extlib::cache_data($slug, 'jibri_recorder_password', extlib::random_password(48))
$jibri_xmpp_password = extlib::cache_data($slug, 'jibri_xmpp_password', extlib::random_password(48))
# Determine effective value of variables
if ($jwt_app_id != '' and $jwt_app_secret != '') {
$auth_enabled = 1
$auth_type = 'jwt'
}
else {
$auth_enabled = 0
$auth_type = 'internal'
}
# ensure the correct version of the directory content
vcsrepo { '/srv/jitsi/':
ensure => present,
provider => git,
source => 'https://github.com/jitsi/docker-jitsi-meet',
revision => $version,
}
-> file { '/srv/jitsi/.env':
ensure => file,
content => template('jitsi/env.erb'),
notify => Service['jitsi'],
}
systemd::unit_file { 'jitsi.service':
content => template('jitsi/jitsi.service.erb'),
notify => Service['jitsi'],
}
if ($facts['jitsi']['version'] != $version and $facts['jitsi']['version'] != '0.0.0') {
notify { 'Need to restart jitsi because there is a version change.':
notify => Service['jitsi'],
}
}
service { 'jitsi':
ensure => running,
}
# do this at the end, otherwise the content is overwritten
# file { '/srv/jitsi/.jitsi-meet-cfg/web/config.js':
# ensure => present,
# content => template('jitsi/web_config.js.erb'),
# backup => '.puppet-bak',
# }
# TODO add these entries back to config.js
# disableThirdPartyRequests: <%= @disable_third_party_requests %>,
# config.disableAP = <%= @disable_all_audio_processing %>;
# config.disableAEC = <%= @disable_echo_cancellation %>;
# config.disableNS = <%= @disable_noise_supression %>;
# config.disableAGC = <%= @disable_auto_gain_control %>;
# config.disableHPF = <%= @disable_high_pass_filter %>;
}
|