- Build the simulation image locally with Docker and push it to Container Registry.
- Configure an Object Storage bucket for storing simulation results.
- Run a CUDA®-accelerated protein simulation as a Serverless AI job that reads a protein structure and writes the simulation results to the Object Storage bucket.
Costs
Nebius AI Cloud charges you for the following billing items:- Compute virtual machines (VMs)
- Boot disks attached to the VMs
- Used space in Standard storage in an Object Storage bucket
Prerequisites
- Web console
- CLI
-
Make sure you are in a group that has at least the
editorrole within your tenant or project; for example, the defaulteditorsgroup. You can check this in the Administration → IAM section of the web console. - Install Docker on your local machine. To do so, you can install Docker Desktop. If your local machine uses a different CPU architecture than AMD64 — for example, an Apple Silicon Mac or a Windows-on-ARM device — Docker Desktop builds the AMD64 image under emulation.
- Install the Nebius AI Cloud CLI. It is required to authenticate against Container Registry and to push the Docker image to it.
Steps
Prepare infrastructure
Locate all resources in the same project.
-
Create an Object Storage bucket to store simulation results.
Serverless AI deletes the container disk after the job completes. The bucket preserves the simulation artifacts generated by the job: the processed structure, trajectory, logs, metadata and plots.
- Web console
- CLI
- In the web console, go to
Storage → Object Storage.
- Click
Create bucket.
- Specify the
openmm-simulationname for the bucket. - In the Bucket size field, select Unlimited.
- Click Create bucket.
-
In Container Registry, create a registry to host the Docker image with OpenMM.
Hosting the image in Container Registry keeps image pulls inside the same region as your Serverless AI job, which reduces the image pull latency and improves the job start time. Serverless AI doesn’t bill for start time, so you can use Docker Hub or configure a private registry if the added pull latency doesn’t matter for your workflow.
- Web console
- CLI
- In the web console, go to
Storage → Container Registry.
- Click
Create registry.
- Specify the
openmmname for the registry. - Click Create registry.
Build and push the image
-
Configure the Docker credential helper for Container Registry so that
docker pushcan authenticate through the Nebius AI Cloud CLI: -
Clone the Serverless AI Cookbook repository and switch to the
openmm-simulationdirectory:Thesim/folder contains Python code with the OpenMM simulation settings. This tutorial uses the code as-is and lets you adjust the target protein and the simulation step count when you create the Serverless AI job. -
Export the region and the registry path to environment variables:
For the list of regions, see Regions.
-
Verify that Docker is available and the daemon is running:
If
docker psreturns a table of containers (can be empty), the daemon is running. If the daemon is not running, launch it. -
Build the image, targeting
linux/amd64:Serverless AI runs Docker images on thelinux/amd64architecture. Using the--platform linux/amd64parameter produces an AMD64 image regardless of the host architecture of your local machine. The resulting image runs natively in Serverless AI with no runtime penalty. For more information, see Docker official documentation on multi-platform builds. -
Push the image to the registry:
Run the simulation as a Serverless AI job
Create a CUDA-accelerated job that runs a short simulation on the1UBQ protein structure:
- Web console
- CLI
-
In the web console, go to
Storage → Container Registry, then open the
openmmregistry and theopenmm-serverlessimage. -
In the
v1tag row, click→ Deploy as job. The Create job page opens with Image path already filled in.
-
Specify the remaining job parameters:
- Name:
openmm-1ubq. - Entrypoint command:
bash -c "python -m sim.run --protein-id 1UBQ --steps 1000 && cp -r /openmm/results/. /mnt/data/". - Job timeout in hours:
4. - Computing resources: With GPU.
- Available platform: NVIDIA® L40S PCIe with Intel Ice Lake.
- Preset: 1 GPU — 8 CPUs — 32 GiB RAM.
- Mount volumes: Bucket.
- Mount path:
/mnt/data. After that, clickAttach bucket and then select the
openmm-simulationbucket.
/openmm/results/is the location of simulation results inside the Docker container. The command runs the simulation and copies the results to the mounted bucket at/mnt/data. You can adjust--protein-idand--stepsto target a different protein or change the simulation length. - Name:
- Click Create.
-
Follow the job logs to watch the simulation progress:
- In the sidebar, go to
AI Services → Jobs.
- Next to the job, click View logs. Alternatively, select the job that you want to view the logs for and switch to the Logs tab.
- In the sidebar, go to
CPU or Reference instead, the GPU runtime didn’t initialize and the simulation will be far slower than expected.
View results in the bucket
- Web console
- CLI
The job uploads the simulation results to the bucket in the folder named
<protein_id>_<timestamp>/ — for example, 1UBQ_20260512_192514/.To view results:- In the web console, go to
Storage → Object Storage.
- Open the
openmm-simulationbucket. - Open the output folder of the latest job.
<protein>_processed.pdb— the processed input structure.<protein>_trajectory.dcd— the trajectory of the simulation.<protein>_simulation.log— the simulation log.<protein>_metadata.txt— the simulation metadata.plots/— visualizations generated from the trajectory.
<protein_id>_processed.pdb and <protein_id>_trajectory.dcd files in a molecular visualization tool of your choice, for example, PyMOL.
