forked from AICoE/prometheus-anomaly-detector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
79 lines (68 loc) · 2.79 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
ENV_FILE := .env
include ${ENV_FILE}
export $(shell sed 's/=.*//' ${ENV_FILE})
export PIPENV_DOTENV_LOCATION=${ENV_FILE}
oc_build_image:
oc process --filename=openshift/oc-image-build-template.yaml \
--param APPLICATION_NAME=${OC_APP_IMAGE_NAME} \
| oc apply -f -
oc_trigger_build:
oc start-build ${OC_APP_IMAGE_NAME}
oc_delete_image:
oc process --filename=openshift/oc-image-build-template.yaml \
--param APPLICATION_NAME=${OC_APP_IMAGE_NAME} \
| oc delete -f -
oc_deploy_app:
oc process --filename=openshift/oc-deployment-template.yaml \
--param FLT_PROM_URL=${FLT_PROM_URL} \
--param FLT_PROM_ACCESS_TOKEN=${FLT_PROM_ACCESS_TOKEN} \
--param FLT_METRICS_LIST="${FLT_METRICS_LIST}" \
--param FLT_DEBUG_MODE="${FLT_DEBUG_MODE}" \
--param OC_APP_IMAGE_NAME="${OC_APP_IMAGE_NAME}" \
| oc apply -f -
oc_delete_app:
oc process --filename=openshift/oc-deployment-template.yaml \
--param FLT_PROM_URL=${FLT_PROM_URL} \
--param FLT_PROM_ACCESS_TOKEN=${FLT_PROM_ACCESS_TOKEN} \
--param FLT_METRICS_LIST="${FLT_METRICS_LIST}" \
--param FLT_DEBUG_MODE="${FLT_DEBUG_MODE}" \
--param OC_APP_IMAGE_NAME="${OC_APP_IMAGE_NAME}" \
| oc delete -f -
oc_run_model_test:
oc process --filename=openshift/oc-model-test-job-template.yaml \
--param APPLICATION_NAME="${APPLICATION_NAME}" \
--param NB_USER="`oc whoami`" \
--param MLFLOW_TRACKING_URI="${MLFLOW_TRACKING_URI}" \
--param OC_APP_IMAGE_NAME="${OC_APP_IMAGE_NAME}" \
--param FLT_PROM_URL=${FLT_PROM_URL} \
--param FLT_PROM_ACCESS_TOKEN=${FLT_PROM_ACCESS_TOKEN} \
--param FLT_METRICS_LIST="${FLT_METRICS_LIST}" \
--param FLT_DATA_START_TIME="${FLT_DATA_START_TIME}" \
--param FLT_DATA_END_TIME="${FLT_DATA_END_TIME}" \
--param FLT_ROLLING_TRAINING_WINDOW_SIZE="${FLT_ROLLING_TRAINING_WINDOW_SIZE}" \
--param FLT_RETRAINING_INTERVAL_MINUTES="${FLT_RETRAINING_INTERVAL_MINUTES}" \
--param FLT_DEBUG_MODE="${FLT_DEBUG_MODE}" \
| oc apply -f -
oc_delete_model_test:
oc process --filename=openshift/oc-model-test-job-template.yaml \
--param APPLICATION_NAME="${APPLICATION_NAME}" \
--param NB_USER="`oc whoami`" \
--param MLFLOW_TRACKING_URI="${MLFLOW_TRACKING_URI}" \
--param OC_APP_IMAGE_NAME="${OC_APP_IMAGE_NAME}" \
--param FLT_PROM_URL=${FLT_PROM_URL} \
--param FLT_PROM_ACCESS_TOKEN=${FLT_PROM_ACCESS_TOKEN} \
--param FLT_METRICS_LIST="${FLT_METRICS_LIST}" \
--param FLT_DATA_START_TIME="${FLT_DATA_START_TIME}" \
--param FLT_DATA_END_TIME="${FLT_DATA_END_TIME}" \
--param FLT_ROLLING_TRAINING_WINDOW_SIZE="${FLT_ROLLING_TRAINING_WINDOW_SIZE}" \
--param FLT_RETRAINING_INTERVAL_MINUTES="${FLT_RETRAINING_INTERVAL_MINUTES}" \
--param FLT_DEBUG_MODE="${FLT_DEBUG_MODE}" \
| oc delete -f -
run_app_pipenv:
pipenv run python app.py
run_test_pipenv:
pipenv run python test_model.py
run_app:
python app.py
run_test:
python test_model.py