Tools and software
Creating Custom Container Images
Overview
Scalable Pixel Streaming does the heavy lifting of creating standardised container images for Pixel Streaming projects directly from a compressed UE project on supported cloud platforms (currently only on AWS) or with the help of our standalone Image Builder tool. However, advanced Pixel Streaming projects with complex external dependencies will require custom Dockerfiles before a container image can be built with standard tools, such as Docker.
To make this process easier, we provide a Dockerfile generator that can create code to act as a starting point when writing custom Dockerfiles. The generator can be accessed below and its output code will change dynamically as the input values get changed:
Custom Dockerfile generator
Dockerfile code:
Custom container example
For example, UE Lyra project has a variety of dependencies that will not allow it to run off of the base SPS container image, so we will need to create a new base image.
- Use this set of commands to create a docker file including additional dependencies:
# Use the SPS container image as a base
FROM tensorworks/sps-base:linux
# Change user to root
USER root
# Update the apt cache
RUN apt update -y
# Add all required dependicies. In this case, we list all Lyra libnss dependencies
RUN apt install libgconf-2-4 libatk1.0-0 libatk-bridge2.0-0 libgdk-pixbuf2.0-0 libgtk-3-0 libgbm-dev libnss3-dev libxss-dev -y
# Change user back to ue4
USER ue4
- Build the container:
docker build -t user/sps-lyra-base:0.0.0-devel lyra-base.dockerfile .
- Push the container to your registry:
docker push <your-user>/<your-repo>:<custom-base-container-tag>
- Now you can use the
--base-container-override
flag in the image builder tool to use the newly created image as a base, for example:
image-builder create --package /Path/to/LyraProject/Linux --tag <your-user>/<your-repo>:<project-image-tag> -base-container-override <your-user>/<your-repo>:<custom-base-container-tag>