Not sure what EC2 is, but, briefly, you can build emulator images on AWS, and than copy them to another machine, and run using Android emulator included in Android SDK.
My experience, probably is not the most correct one, but I did the following:
1. installed Android SDK
2. using sdkmanager, installed emulator, system images for similar platform (P or Q or R or whatever)
3. created similar structure in another folder, corrected the xmk file, copied images produced by the build procedure (but you need to rename system-qemu.img to system.img and vendor-qemu.img to vendor.img)
4. using avdmanager, created a virtual device based on the new images
5. run images using emulator.
The procedure probably can be improved:
* instead of item 3, when you run emulator, you can specify path to the system image, vendor image and so on. But this approach looks working only for emulator provided by the SDK.
* in Android S, Google introduced some scripts to pack the image as AVD. You can try to search this in the tree.