The number of applications that use virtualized cloud-based systems is growing, and one would like to use this kind of systems also for real-time applications with hard deadlines. There is scheduling on two levels in real-time applications executing in a virtualized environment: traditional real-time scheduling of the tasks in the real-time application, and scheduling of different Virtual Machines (VMs) on the hypervisor level. Traditional real-time scheduling is well understood, and most of the existing results calculate schedules based on periods, deadlines and worst-case execution times of the real-time tasks. In order to apply the existing theory also to cloud-based virtualized environments we must obtain periods and worst-case execution times for the VMs containing real-time applications. In this paper, we describe a technique for calculating a period and a worst-case execution time for a VM containing a real-time application with hard deadlines. This new result makes it possible to apply existing real-time scheduling theory when scheduling VMs on the hypervisor level, thus making it possible to guarantee that the real-time tasks in a VM meet their deadlines