Skip to content

Latest commit

 

History

History
48 lines (33 loc) · 1.83 KB

promote-to-production.adoc

File metadata and controls

48 lines (33 loc) · 1.83 KB

Promote To Production

The model is working properly in staging and can now be deployed to production. The production environment will be under the {{USER_ID}}-prod namespace.

Using container images allows us to have consistency across environments. Containers allows us to package our model and its dependencies into an image and will run the same regardless of their deployment environment.

We will be using {{ECLIPSE_CHE_URL}}[ CodeReady Workspaces^], and log in using the username and password you’ve been assigned (e.g. {{ USER_ID }}/{{ CHE_USER_PASSWORD }}):

Image Promotion

To promote the image from staging to production environment, we are going to merge our stage to prod deployment branch. If there is a need for an approval process, Red Hat Process Automation Manager can be used to approve the Pull Request before the changes are merged.

cd /projects/{{USER_DEPLOY_REPO_NAME}}
git checkout -b prod
git merge stage
git push -u -v origin prod

You can now login to {{ARGOCD_URL}}/applications/{{USER_ID}}-prod[Argo CD^] with your {{USER_ID}}/{{OPENSHIFT_USER_PASSWORD}} credential to view the changes that Argo CD is making to the production environment.

Model Testing

Once the model has been deployed and is running, you can now run some simple tests. The test will send sample data to the prediction endpoint.

/projects/{{USER_MODEL_REPO_NAME}}/bin/prod-mon-test.sh

Tag it!

Now the model has been tested in production, we now can tag it as v1.0.

cd /projects/{{USER_MODEL_REPO_NAME}}
git checkout stage
git tag -a v1.0 -m "v1.0"
git push -v origin v1.0

The tag has now been pushed to {{GIT_URL}}/{{USER_ID}}/{{USER_MODEL_REPO_NAME}}/src/v1.0[your^] git repository.

git-tag-1_0