# HTTPS streaming and dynamic load balancer using Wowza and AWS VPC

**URL:** <https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469>\
**Category:** Wowza Streaming Engine\
**Created:** [January 12, 2016, 11:21am UTC](https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469 "2016-01-12T11:21:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Tim\_Gladkikh](https://avatars.discourse-cdn.com/v4/letter/t/ea5d25/32.png) [@Tim\_Gladkikh](https://community.wowza.com/u/Tim_Gladkikh)\
**Post date:** [January 12, 2016, 11:21am UTC](https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469/1 "2016-01-12T11:21:43Z")

</div>

We are using **Wowza** instances to perform live streaming on AWS infrastructure. We have a script that monitors load balancer and launches/kills instances when required based on the number of connections/viewers per edge server. It woks well for **HTTP/RTMP/RTMPT** streaming. We are now trying to implement dynamic load balancing for **HTTPS** streaming and automate the scaling process. The main question for us is how to automate it in a best possible way? We don’t know the IPs of the edge servers that will be launched, therefore, can’t create the DNS records in advance.

One possible solution would be to reserve some number of elastic IPs (i.e. 20) and the same number of **DNS** names and use them during scaling. But this will set a limit on the number of servers we can launch dynamically.

Is there a more elegant solution that we can try to implement?

Our LB infrastructure is inside **AWS VPC** and we have a star certificate that we can use. Also, **Wowza Load Balancer** only used to tell the viewer the IP of the available edge server. After that, the viewer connects to the edge server directly.

Is it possible to utilize **SteamLock** service for that and automate cert creation?

I’ve got an amazing reply to the same question on [SO](http://serverfault.com/questions/747874/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws) and was also wondering if Wowza has a built-in solution too.

---

<div class="post-metadata">

**Author:** ![Andrew\_Ramberg](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@Andrew\_Ramberg](https://community.wowza.com/u/Andrew_Ramberg)\
**Post date:** [January 22, 2016, 9:01am UTC](https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469/2 "2016-01-22T09:01:44Z")

</div>

Hello,

If your using AWS, you may want to look into using [Elastic Load Balancer with an auto-scaling group](http://docs.aws.amazon.com/AutoScaling/latest/DeveloperGuide/US_SetUpASLBApp.html).

Best regards,

Andrew

---

<div class="post-metadata">

**Author:** ![Tim\_Gladkikh](https://avatars.discourse-cdn.com/v4/letter/t/ea5d25/32.png) [@Tim\_Gladkikh](https://community.wowza.com/u/Tim_Gladkikh)\
**Post date:** [January 22, 2016, 11:20am UTC](https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469/3 "2016-01-22T11:20:01Z")

</div>

Hi Andrew,

Thank you for the reply. We actually decided to use this feature and based our scaling policy on bandwidth rather than connection count.

Thanks,

Tim

---

<div class="post-metadata">

**Author:** ![Usama\_Mushtaq](https://avatars.discourse-cdn.com/v4/letter/u/e8c25b/32.png) [@Usama\_Mushtaq](https://community.wowza.com/u/Usama_Mushtaq)\
**Post date:** [March 6, 2017, 9:06am UTC](https://community.wowza.com/t/https-streaming-and-dynamic-load-balancer-using-wowza-and-aws-vpc/43469/4 "2017-03-06T09:06:32Z")

</div>

Hi!

I am trying to implement the similar thing.  
I don’t have edge server, i have only origins, for edge purpose we are using CDN

I don’t see how can we use elastic load balancer to distribute rtmp traffic? it does not support long running connections?

plus auto scale group can scale down and terminate instance when your clients are still connected to it.

Well i am planning to use HAProxy instead of ELB, with automated script to update it.

But can i scale and downscale based on no of connections on amazon? (so client experience and disconnection).???

Thanks
