[英]Can we print the configurations on which the MLflow server has started?
I am using the following command to start the MLflow server:我正在使用以下命令来启动 MLflow 服务器:
mlflow server --backend-store-uri postgresql://mlflow_user:mlflow@localhost/mlflow --artifacts-destination <S3 bucket location> --serve-artifacts -h 0.0.0.0 -p 8000
Before production deployment, we have a requirement that we need to print or fetch the under what configurations the server is running.在生产部署之前,我们需要打印或获取服务器运行的配置。 For example, the above command uses localhost postgres connection and S3 bucket.
例如,上述命令使用 localhost postgres 连接和 S3 存储桶。
Is there a way to achieve this?有没有办法做到这一点?
Also, how do I set the server's environment as "production"?另外,如何将服务器的环境设置为“生产”? So finally I should see a log like this:
所以最后我应该看到这样的日志:
[LOG] Started MLflow server:
Env: production
postgres: localhost:5432
S3: <S3 bucket path>
You can wrap it in a bash script or in a Makefile script, eg您可以将其包装在 bash 脚本或 Makefile 脚本中,例如
start_mlflow_production_server:
@echo "Started MLflow server:"
@echo "Env: production"
@echo "postgres: localhost:5432"
@echo "S3: <S3 bucket path>"
@mlflow server --backend-store-uri postgresql://mlflow_user:mlflow@localhost/mlflow --artifacts-destination <S3 bucket location> --serve-artifacts -h 0.0.0.0 -p 8000
Additionally, it you can set and use environment variables specific to that server and print and use those in the command.此外,您可以设置和使用特定于该服务器的环境变量,并在命令中打印和使用这些变量。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.