Jibri is the component of jitsi which is used for recording and streaming. You can follow this instruction to install it. But there is a limitation to the jibri server.
You have to provide one jibri server for one conference recording or streaming. If you have 10 concurrent conferences you have to use 10 jibri servers to record or stream them. The number of conferences you need to record or stream may vary over time and having servers to meet the maximum capacity is an over kill. The best solution to this is to autoscale the jibri servers based on demand.
Here we have use aws services to achieve this scalability.
CloudWatch Metrics is the key component in this architecture that measure how many jibri servers are free. If a jibri server is free CloudWatch Metrics increase the count by 1. We can choose the number that call
RECORD_STEADY_STATE and it depends on how many jibri servers should always be free. If actual metrics count is less than
RECORD_STEADY_STATE we fire scale in alarm. If metrics count greater than
RECORD_STEADY_STATE we fire the scale out alarm. According to the scale in out alarm ASG spin and shutdown the servers.
You can configure the aws autoscaling group with relevant parameters to achieve this functionality.