MLflow
Overview
MLflow is the widely adopted open-source platform for managing the end-to-end machine learning lifecycle. It covers experiment tracking for parameters, metrics and artifacts, a model registry to version and stage models, and tools to package and deploy them.
This SecureAnyCloud image installs MLflow 3.13 in a Python virtual environment at /opt/mlflow on Python 3.12, run by an unprivileged mlflow system account. An nginx reverse proxy on TCP 80 fronts it, all data lives on a dedicated Azure data disk, and every VM generates its own unique admin password on first boot.
The tracking server listens on the loopback address 127.0.0.1:5000 and is never exposed directly. nginx fronts it on port 80 with HTTP Basic Authentication. The unauthenticated /health probe stays open for load balancers, and everything else requires the admin password.
What you get:
- MLflow 3.13 tracking server and web UI in a Python venv at
/opt/mlflow - An nginx reverse proxy on
:80in front of the tracking server (bound to loopback:5000) - A dedicated Azure data disk at
/var/lib/mlflowholding the SQLite backend store (experiments, runs, registered models) and the artifact store, separate from the OS disk and re-provisioned with every VM - A per-VM admin password (
MLFLOW_ADMIN_PASSWORD) generated at first boot and stored in a root-only file mlflow.serviceandnginx.serviceas enabled, active systemd units- 24/7 SecureAnyCloud support
Prerequisites
You need an active Azure subscription, an SSH key pair, and a VNet with a subnet in the target region.
Standard_B2ms (2 vCPU / 8 GiB RAM) is a good starting size. Scale up for larger experiment volumes or heavier UI use.
Configure the network security group (NSG) to allow inbound 22/tcp from your management network and 80/tcp from the clients and browsers that reach MLflow. For public exposure, front port 80 with TLS, as described under Enabling HTTPS.
Step 1 - Deploy from the Azure Marketplace
Sign in to the Azure Portal, choose Create a resource, search the Marketplace for MLflow by SecureAnyCloud, and select Create.
On the Basics tab, pick your subscription, resource group, region and size. Under Administrator account, choose SSH public key and paste your key. Under Inbound port rules, allow SSH (22) and HTTP (80).
Review the dedicated data disk on the Disks tab, then select Review + create and Create.
Step 2 - Deploy from the Azure CLI
# Accept the Marketplace terms once per subscription (required before the first CLI deploy)
az vm image terms accept --urn sac1647283583153:mlflow-ubuntu-24-04:default:latest
az vm create \
--resource-group <your-rg> \
--name mlflow \
--image sac1647283583153:mlflow-ubuntu-24-04:default:latest \
--size Standard_B2ms \
--admin-username azureuser \
--ssh-key-values ~/.ssh/id_ed25519.pub \
--vnet-name <your-vnet> --subnet <your-subnet> \
--public-ip-sku Standard
az vm open-port --resource-group <your-rg> --name mlflow --port 80 --priority 1010Step 3 - Connect to your VM
ssh azureuser@<vm-public-ip>Step 4 - Confirm the services are running
systemctl is-active mlflow.service nginx.service curl -s http://127.0.0.1/healthBoth services report active, and the /health endpoint returns OK.
Step 5 - Retrieve your admin password
Your VM generated a unique admin password on first boot and wrote it to a root-only file. Read the file with sudo:
sudo cat /root/mlflow-credentials.txtThe MLFLOW_ADMIN_PASSWORD value is the password. Sign in as admin with it.
Step 6 - Open the MLflow UI
Browse to http://<vm-public-ip>/ and sign in as admin with the password from Step 5.
Step 7 - Log an experiment from the MLflow client
Install the client, point it at the VM with the admin credentials, and log a run. Replace <vm-public-ip> and <password> with your values:
pip install mlflow export MLFLOW_TRACKING_URI=http://<vm-public-ip>/ export MLFLOW_TRACKING_USERNAME=admin export MLFLOW_TRACKING_PASSWORD=<password> python3 - <<'PY' import mlflow mlflow.set_experiment("demo") with mlflow.start_run(): mlflow.log_param("alpha", 0.5) mlflow.log_metric("rmse", 0.27) PYThe run, its parameters, metrics and artifacts appear in the UI. Register a model from a run to version and stage it in the model registry. The backend store and artifacts persist on the dedicated data disk at /var/lib/mlflow.
You can also call the REST API directly with the admin credentials:
PASS=$(sudo grep '^MLFLOW_ADMIN_PASSWORD=' /root/mlflow-credentials.txt | cut -d= -f2-)
curl -s -o /dev/null -w '%{http_code}\n' -u "admin:$PASS" \
'http://127.0.0.1/api/2.0/mlflow/experiments/search?max_results=1'A 200 confirms that the authenticated REST API is serving.
Step 8 - Confirm the runtime
/opt/mlflow/venv/bin/pip show mlflow | grep ^VersionThe command prints Version: 3.13.0.
Production scale - PostgreSQL and Azure Blob Storage
The image defaults to a SQLite backend store and a local artifact store on the data disk. For team scale, repoint both in /etc/mlflow/mlflow.env:
MLFLOW_BACKEND_STORE_URI=postgresql://user:password@your-db-host:5432/mlflow MLFLOW_ARTIFACTS_DESTINATION=wasbs://your-container@your-account.blob.core.windows.net/mlflowThen restart MLflow with sudo systemctl restart mlflow.service. Grant the VM's managed identity access to the storage account.
Enabling HTTPS
For production, terminate TLS at nginx with a real domain pointed at the VM's public IP. Install certbot and request a certificate, replacing the domain with your own:
sudo apt-get update && sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.comcertbot edits the nginx site at /etc/nginx/sites-available/sac-mlflow to add the TLS listener and arranges automatic renewal.
Backup and maintenance
All MLflow state lives on the dedicated data disk at /var/lib/mlflow. That covers the SQLite backend store mlflow.db and the artifacts directory. Snapshot that disk in Azure to back up experiments, runs and registered models.
Keep the OS patched with sudo apt update && sudo apt upgrade.
The admin password is in the nginx htpasswd file /etc/nginx/.mlflow.htpasswd. Rotate it with sudo htpasswd /etc/nginx/.mlflow.htpasswd admin.
Restart the server cleanly with sudo systemctl restart mlflow.service. Read its logs with sudo journalctl -u mlflow.service.
Support
This image is backed by 24/7 SecureAnyCloud support. Contact us by email or chat for help with experiment tracking, the model registry, backend and artifact store configuration, scaling, TLS and backups.
All product and company names are trademarks or registered trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them.
Deploy on Azure
Launch MLflow on Ubuntu 24.04 LTS on Azure with 24/7 support from SecureAnyCloud.
View this image
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com
Overview
MLflow is the open-source platform for the machine learning lifecycle: experiment tracking, a model registry, and model packaging and deployment. This SecureAnyCloud image runs MLflow 3.13 on Ubuntu 24.04 LTS.
What you get:
- MLflow installed in a dedicated Python virtual environment under
/opt/mlflowon Python 3.12, run by an unprivilegedmlflowsystem account - A systemd service that starts the tracking server on boot and restarts it on failure
- A tracking server on the loopback address
127.0.0.1:5000, never exposed directly, with nginx in front of it on port 80 using HTTP Basic Authentication - An unauthenticated
/healthprobe for load balancers, with everything else requiring the admin password - A one-shot service on the first boot of every instance that generates a fresh admin password, unique to that instance, and writes it to
/root/mlflow-credentials.txt(mode0600, root only) - The SQLite backend store and the artifact store under
/var/lib/mlflow, on a dedicated, independently resizable EBS data volume - A default security group that opens only port 22 (SSH) and port 80 (HTTP)
Prerequisites
- An AWS account subscribed to this product in AWS Marketplace
- An EC2 key pair in your target region for SSH access
- A security group that allows inbound TCP 22 (SSH) from your IP and TCP 80 (HTTP) from your users
- An instance type of
m5.largeor larger (recommended) - The MLflow client (
pip install mlflow) on your workstation or training environment
Connecting to your instance
OS variant Login user Example
Ubuntu 24.04 ubuntu ssh -i your-key.pem ubuntu@<instance-public-ip>
Step 1 - Launch from the AWS Marketplace console
- Open the product page in AWS Marketplace and choose Continue to Subscribe, then Continue to Configuration.
- Select the MLflow 3.13 on Ubuntu 24.04 delivery option and your region, then choose Continue to Launch.
- Choose your instance type, VPC and subnet, key pair, and the security group described above, then launch.
Step 2 - Launch from the AWS CLI
aws ec2 run-instances \
--image-id ami-xxxxxxxxxxxxxxxxx \
--instance-type m5.large \
--key-name your-key \
--security-group-ids sg-xxxxxxxx \
--tag-specifications 'ResourceType=instance,Tags=[{Key=Name,Value=mlflow}]'Step 3 - Connect to your instance
ssh -i your-key.pem ubuntu@<instance-public-ip>Step 4 - Confirm the services are running
systemctl is-active mlflow.service nginx.service ss -tln | grep -E ':80 |:5000 ' curl -s http://127.0.0.1/healthThe expected output looks like this:
active active LISTEN 0 511 0.0.0.0:80 0.0.0.0:* LISTEN 0 2048 127.0.0.1:5000 0.0.0.0:* LISTEN 0 511 [::]:80 [::]:* OKStep 5 - Retrieve your admin password
sudo cat /root/mlflow-credentials.txt# MLflow - generated on first boot by mlflow-firstboot.service MLFLOW_URL=http://<instance-public-ip>/ MLFLOW_ADMIN_USER=admin MLFLOW_ADMIN_PASSWORD=<your-unique-password>Step 6 - Open the MLflow UI
Browse to http://<instance-public-ip>/ and sign in as admin with the password from Step 5.
Step 7 - Log an experiment from the MLflow client
Point the MLflow client at the instance with the admin credentials, and log a run:
export MLFLOW_TRACKING_URI=http://<instance-public-ip>/
export MLFLOW_TRACKING_USERNAME=admin
export MLFLOW_TRACKING_PASSWORD=<your-unique-password>import mlflow mlflow.set_experiment("demo") with mlflow.start_run(): mlflow.log_param("alpha", 0.5) mlflow.log_metric("rmse", 0.27)The run, its parameters, metrics and artifacts appear in the UI. Register a model from a run to version and stage it in the model registry.
You can also call the REST API directly with the admin credentials:
PASS=$(sudo grep '^MLFLOW_ADMIN_PASSWORD=' /root/mlflow-credentials.txt | cut -d= -f2-)
curl -s -o /dev/null -w '%{http_code}\n' -u "admin:$PASS" \
'http://127.0.0.1/api/2.0/mlflow/experiments/search?max_results=1'200Step 8 - Confirm the runtime
/opt/mlflow/venv/bin/pip show mlflow | grep ^VersionVersion: 3.13.0Production scale - PostgreSQL and Amazon S3
The image defaults to a SQLite backend store and a local artifact store on the data volume. For team scale, repoint both in /etc/mlflow/mlflow.env:
MLFLOW_BACKEND_STORE_URI=postgresql://user:password@your-db-host:5432/mlflow MLFLOW_ARTIFACTS_DESTINATION=s3://your-bucket/mlflowThen restart MLflow with sudo systemctl restart mlflow.service. Attach an instance role that grants access to the S3 bucket.
Enabling HTTPS
sudo apt-get update && sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.comcertbot edits the nginx site at /etc/nginx/sites-available/sac-mlflow to add the TLS listener and arranges automatic renewal.
Backup and maintenance
- All MLflow state lives under
/var/lib/mlflow(the SQLite backend storemlflow.dband theartifactsdirectory) on its own EBS volume. Snapshot that volume to back up experiments, runs and registered models. - The admin password is in the nginx htpasswd file
/etc/nginx/.mlflow.htpasswd. Rotate it withsudo htpasswd /etc/nginx/.mlflow.htpasswd admin. - Restart the server with
sudo systemctl restart mlflow.service. Read its logs withsudo journalctl -u mlflow.service.
Support
SecureAnyCloud provides 24/7 technical support for this image by email and chat. Support covers MLflow deployment, experiment tracking, the model registry, backend and artifact store configuration, TLS termination and scaling. Contact details are on the AWS Marketplace listing.
Deploy on AWS
Launch MLflow on AWS with 24/7 support from SecureAnyCloud.
View on Marketplace
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com