From de3f1a41cb9fb8aea414ecf57dfa4ff40b6719f6 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Fri, 9 Aug 2019 14:18:28 -0700 Subject: [PATCH 01/17] Update iac-create-environment.yml for Azure Pipelines --- environment_setup/iac-create-environment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/environment_setup/iac-create-environment.yml b/environment_setup/iac-create-environment.yml index fffaf066..af2c2fcd 100644 --- a/environment_setup/iac-create-environment.yml +++ b/environment_setup/iac-create-environment.yml @@ -12,7 +12,7 @@ pool: variables: baseName: $[coalesce(variables['baseNameOverride'], 'mlops')] location: $[coalesce(variables['locationOverride'], 'centralus')] - azuresub: $[coalesce(variables['azuresubOverride'], 'davete02_sub')] + azuresub: $[coalesce(variables['azuresubOverride'], 'AzureResourceConnection')] steps: From c298a61e50d8c8fe257b40714e88587ba6bf5a59 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Mon, 12 Aug 2019 15:25:59 -0700 Subject: [PATCH 02/17] removed extra line from gitignore --- .gitignore | 1 - 1 file changed, 1 deletion(-) diff --git a/.gitignore b/.gitignore index b327895b..3a5a8879 100644 --- a/.gitignore +++ b/.gitignore @@ -104,5 +104,4 @@ venv.bak/ # mypy .mypy_cache/ -aml_config/config.json .DS_Store From 13b27eb221a1b7a612d181b53621b6d7154a6e8f Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 09:40:05 -0700 Subject: [PATCH 03/17] Update azdo-ci-build-train.yml for Azure Pipelines --- .pipelines/azdo-ci-build-train.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.pipelines/azdo-ci-build-train.yml b/.pipelines/azdo-ci-build-train.yml index 36e7ce86..09f90909 100644 --- a/.pipelines/azdo-ci-build-train.yml +++ b/.pipelines/azdo-ci-build-train.yml @@ -7,9 +7,7 @@ trigger: pool: vmImage: 'ubuntu-latest' -container: - image: mcr.microsoft.com/mlops/python:latest - endpoint: acrconnection +container: mcr.microsoft.com/mlops/python:latest variables: From 6670604b3d74a9fd96cbfc80509e75534a1968a1 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:11:36 -0700 Subject: [PATCH 04/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 31 ++++++++++++++-------- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index c036aefd..0106d3b4 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -3,22 +3,31 @@ import json import requests from azureml.core.authentication import AzureCliAuthentication +from azure.common.credentials import ServicePrincipalCredentials -try: - with open("train_pipeline.json") as f: - train_pipeline_json = json.load(f) -except Exception: - print("No pipeline json found") - sys.exit(0) + try: + with open("train_pipeline.json") as f: +# train_pipeline_json = json.load(f) +# except Exception: +# print("No pipeline json found") +# sys.exit(0) -experiment_name = os.environ.get("EXPERIMENT_NAME") -model_name = os.environ.get("MODEL_NAME") +# experiment_name = os.environ.get("EXPERIMENT_NAME") +# model_name = os.environ.get("MODEL_NAME") -cli_auth = AzureCliAuthentication() -token = cli_auth.get_authentication_header() +credentials = ServicePrincipalCredentials( + client_id = '368aaecc-1df8-4132-914c-6c42f8aa0f8b', + secret = 'e9ToDq-+0add3Oe6O=lwcqo=_Ppy*zim', + tenant = '72f988bf-86f1-41af-91ab-2d7cd011db47' +) + +# cli_auth = AzureCliAuthentication() +# token = cli_auth.get_authentication_header() +token = credentials.token['access_token'] +print("token", token) -rest_endpoint = train_pipeline_json["rest_endpoint"] +#rest_endpoint = train_pipeline_json["rest_endpoint"] response = requests.post( rest_endpoint, headers=token, From 023f1f2be29a4546ccf358336ace248321cea888 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:13:11 -0700 Subject: [PATCH 05/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index 0106d3b4..d6a04f93 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -8,13 +8,13 @@ try: with open("train_pipeline.json") as f: -# train_pipeline_json = json.load(f) -# except Exception: -# print("No pipeline json found") -# sys.exit(0) + train_pipeline_json = json.load(f) + except Exception: + print("No pipeline json found") + sys.exit(0) -# experiment_name = os.environ.get("EXPERIMENT_NAME") -# model_name = os.environ.get("MODEL_NAME") + experiment_name = os.environ.get("EXPERIMENT_NAME") + model_name = os.environ.get("MODEL_NAME") credentials = ServicePrincipalCredentials( client_id = '368aaecc-1df8-4132-914c-6c42f8aa0f8b', @@ -27,7 +27,7 @@ token = credentials.token['access_token'] print("token", token) -#rest_endpoint = train_pipeline_json["rest_endpoint"] +rest_endpoint = train_pipeline_json["rest_endpoint"] response = requests.post( rest_endpoint, headers=token, From cf379e130f3b3a807627c5986cd0de0664815017 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:20:07 -0700 Subject: [PATCH 06/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index d6a04f93..b9cc3d4d 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -6,15 +6,15 @@ from azure.common.credentials import ServicePrincipalCredentials - try: - with open("train_pipeline.json") as f: - train_pipeline_json = json.load(f) - except Exception: - print("No pipeline json found") - sys.exit(0) - - experiment_name = os.environ.get("EXPERIMENT_NAME") - model_name = os.environ.get("MODEL_NAME") +try: + with open("train_pipeline.json") as f: + train_pipeline_json = json.load(f) +except Exception: + print("No pipeline json found") + sys.exit(0) + +experiment_name = os.environ.get("EXPERIMENT_NAME") +model_name = os.environ.get("MODEL_NAME") credentials = ServicePrincipalCredentials( client_id = '368aaecc-1df8-4132-914c-6c42f8aa0f8b', From cdc8328e27c5047684ac446e80c25b31c7ee7560 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:23:12 -0700 Subject: [PATCH 07/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index b9cc3d4d..83c7c705 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -2,7 +2,6 @@ import os import json import requests -from azureml.core.authentication import AzureCliAuthentication from azure.common.credentials import ServicePrincipalCredentials @@ -17,9 +16,9 @@ model_name = os.environ.get("MODEL_NAME") credentials = ServicePrincipalCredentials( - client_id = '368aaecc-1df8-4132-914c-6c42f8aa0f8b', - secret = 'e9ToDq-+0add3Oe6O=lwcqo=_Ppy*zim', - tenant = '72f988bf-86f1-41af-91ab-2d7cd011db47' + client_id='368aaecc-1df8-4132-914c-6c42f8aa0f8b', + secret='e9ToDq-+0add3Oe6O=lwcqo=_Ppy*zim', + tenant='72f988bf-86f1-41af-91ab-2d7cd011db47' ) # cli_auth = AzureCliAuthentication() From bdc020483d51607b8b5c1578db237bbd62ea49a9 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:39:00 -0700 Subject: [PATCH 08/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index 83c7c705..9acc81dd 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -25,11 +25,12 @@ # token = cli_auth.get_authentication_header() token = credentials.token['access_token'] print("token", token) +auth_header = {"Authorization": "Bearer " + token} rest_endpoint = train_pipeline_json["rest_endpoint"] response = requests.post( - rest_endpoint, headers=token, + rest_endpoint, headers=auth_header, json={"ExperimentName": experiment_name, "ParameterAssignments": {"model_name": model_name}} ) From f17ae04bfd0c36995daf59b2ec45109f8e8373f0 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Thu, 15 Aug 2019 16:56:42 -0700 Subject: [PATCH 09/17] Update run_train_pipeline.py --- ml_service/pipelines/run_train_pipeline.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index 9acc81dd..a2d1e68f 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -5,6 +5,10 @@ from azure.common.credentials import ServicePrincipalCredentials +tenant_id = os.environ.get("TENANT_ID") +app_id = os.environ.get("SP_APP_ID") +app_secret = os.environ.get("SP_APP_SECRET") + try: with open("train_pipeline.json") as f: train_pipeline_json = json.load(f) @@ -16,13 +20,11 @@ model_name = os.environ.get("MODEL_NAME") credentials = ServicePrincipalCredentials( - client_id='368aaecc-1df8-4132-914c-6c42f8aa0f8b', - secret='e9ToDq-+0add3Oe6O=lwcqo=_Ppy*zim', - tenant='72f988bf-86f1-41af-91ab-2d7cd011db47' + client_id=app_id, + secret=app_secret, + tenant=tenant_id ) -# cli_auth = AzureCliAuthentication() -# token = cli_auth.get_authentication_header() token = credentials.token['access_token'] print("token", token) auth_header = {"Authorization": "Bearer " + token} From 8705329a9c6044931c81a2e6a41fbb2c270fcc07 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Fri, 16 Aug 2019 12:27:57 -0700 Subject: [PATCH 10/17] Update train.py --- code/training/train.py | 1 + 1 file changed, 1 insertion(+) diff --git a/code/training/train.py b/code/training/train.py index 2b541615..bfa25d6e 100644 --- a/code/training/train.py +++ b/code/training/train.py @@ -22,6 +22,7 @@ IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THE SOFTWARE CODE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +Yes """ from azureml.core.run import Run import os From 66f29c9de218afe75fe399be9dea62f4ba87080b Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Tue, 24 Sep 2019 15:55:36 -0700 Subject: [PATCH 11/17] playing with R --- code/training/r_train.r | 0 code/training/train_with_r.py | 3 + code/training/weight_data.csv | 30 ++++++++ ml_service/pipelines/build_train_pipeline.py | 73 ++++++++++---------- 4 files changed, 70 insertions(+), 36 deletions(-) create mode 100644 code/training/r_train.r create mode 100644 code/training/train_with_r.py create mode 100644 code/training/weight_data.csv diff --git a/code/training/r_train.r b/code/training/r_train.r new file mode 100644 index 00000000..e69de29b diff --git a/code/training/train_with_r.py b/code/training/train_with_r.py new file mode 100644 index 00000000..b51b70bb --- /dev/null +++ b/code/training/train_with_r.py @@ -0,0 +1,3 @@ +import os + +os.system("Rscript r_train.r") diff --git a/code/training/weight_data.csv b/code/training/weight_data.csv new file mode 100644 index 00000000..cc441ee9 --- /dev/null +++ b/code/training/weight_data.csv @@ -0,0 +1,30 @@ +height,weight +79,174 +63,250 +75,223 +75,130 +70,120 +76,239 +63,129 +64,185 +59,246 +80,241 +79,217 +65,212 +74,242 +71,223 +61,167 +78,148 +75,229 +75,116 +75,182 +72,237 +72,160 +79,169 +67,219 +61,202 +65,168 +79,181 +81,214 +78,216 +59,245 diff --git a/ml_service/pipelines/build_train_pipeline.py b/ml_service/pipelines/build_train_pipeline.py index a294a1c0..4f16ebbe 100644 --- a/ml_service/pipelines/build_train_pipeline.py +++ b/ml_service/pipelines/build_train_pipeline.py @@ -64,9 +64,9 @@ def main(): train_step = PythonScriptStep( name="Train Model", - script_name=train_script_path, + script_name="train_with_r.py", compute_target=aml_compute_cpu, - source_directory=sources_directory_train, + source_directory="code/training", arguments=[ "--config_suffix", config_suffix, "--json_config", jsonconfigs, @@ -79,42 +79,43 @@ def main(): ) print("Step Train created") - evaluate_step = PythonScriptStep( - name="Evaluate Model ", - script_name=evaluate_script_path, - compute_target=aml_compute_cpu, - source_directory=sources_directory_train, - arguments=[ - "--config_suffix", config_suffix, - "--json_config", jsonconfigs, - ], - runconfig=run_config, - inputs=[jsonconfigs], - # outputs=[jsonconfigs], - allow_reuse=False, - ) - print("Step Evaluate created") + # evaluate_step = PythonScriptStep( + # name="Evaluate Model ", + # script_name=evaluate_script_path, + # compute_target=aml_compute_cpu, + # source_directory=sources_directory_train, + # arguments=[ + # "--config_suffix", config_suffix, + # "--json_config", jsonconfigs, + # ], + # runconfig=run_config, + # inputs=[jsonconfigs], + # # outputs=[jsonconfigs], + # allow_reuse=False, + # ) + # print("Step Evaluate created") - register_model_step = PythonScriptStep( - name="Register New Trained Model", - script_name=register_script_path, - compute_target=aml_compute_cpu, - source_directory=sources_directory_train, - arguments=[ - "--config_suffix", config_suffix, - "--json_config", jsonconfigs, - "--model_name", model_name, - ], - runconfig=run_config, - inputs=[jsonconfigs], - # outputs=[jsonconfigs], - allow_reuse=False, - ) - print("Step register model created") + # register_model_step = PythonScriptStep( + # name="Register New Trained Model", + # script_name=register_script_path, + # compute_target=aml_compute_cpu, + # source_directory=sources_directory_train, + # arguments=[ + # "--config_suffix", config_suffix, + # "--json_config", jsonconfigs, + # "--model_name", model_name, + # ], + # runconfig=run_config, + # inputs=[jsonconfigs], + # # outputs=[jsonconfigs], + # allow_reuse=False, + # ) + # print("Step register model created") - evaluate_step.run_after(train_step) - register_model_step.run_after(evaluate_step) - steps = [register_model_step] + # evaluate_step.run_after(train_step) + # register_model_step.run_after(evaluate_step) + # steps = [register_model_step] + steps = [train_step] train_pipeline = Pipeline(workspace=aml_workspace, steps=steps) train_pipeline.validate() From e15fdcacc7e5e1127296b394f7b4dcac6007fb1c Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Tue, 24 Sep 2019 15:55:50 -0700 Subject: [PATCH 12/17] Playing with R --- code/training/r_train.r | 49 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/code/training/r_train.r b/code/training/r_train.r index e69de29b..1732a282 100644 --- a/code/training/r_train.r +++ b/code/training/r_train.r @@ -0,0 +1,49 @@ +# Databricks notebook source +print(R.version.string) + +# COMMAND ---------- + +mount_name = "kcmunninstoragev2-databricks" # Change this to the mount name in your Databricks workspace + +# COMMAND ---------- + +# Load Training Data +#path = paste("/dbfs/mnt/",mount_name,"/weight_data.csv",sep="") +path="../../../data/train/weight_data.csv" +print(paste("Reading file from",path)) + +routes<-read.csv(path, header=TRUE) + +# The predictor vector (height). +x <- routes$height +# The response vector (weight). +y <- routes$weight +# Apply the lm() function. +model <- lm(y~x) + +# COMMAND ---------- + +routes + +# COMMAND ---------- + +# Make Predictions +df_test_heights <- data.frame(x = as.numeric(c(115,20))) +result <- predict(model,df_test_heights) +print(result) + +# COMMAND ---------- + +# Save the model to blob storage +#model_path = paste("/dbfs/mnt/",mount_name,"/models/model.rds",sep="") +model_path="model.rds" +saveRDS(model, model_path) + +# COMMAND ---------- + +# View model details +print(model) + +# COMMAND ---------- + +print('Completed') \ No newline at end of file From cb6b488bc29681fad38bdedbcf01d46531b02bba Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Tue, 24 Sep 2019 15:58:05 -0700 Subject: [PATCH 13/17] Update azdo-ci-build-train.yml for Azure Pipelines --- .pipelines/azdo-ci-build-train.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.pipelines/azdo-ci-build-train.yml b/.pipelines/azdo-ci-build-train.yml index 09f90909..3bc0bd5b 100644 --- a/.pipelines/azdo-ci-build-train.yml +++ b/.pipelines/azdo-ci-build-train.yml @@ -15,8 +15,7 @@ variables: steps: -- template: azdo-base-pipeline.yml - + - bash: | # Invoke the Python building and publishing a training pipeline python3 $(Build.SourcesDirectory)/ml_service/pipelines/build_train_pipeline.py From 00895774240ac3583b65ce6089cc9ee975a10211 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Mon, 30 Mar 2020 15:20:40 -0700 Subject: [PATCH 14/17] Create main.yml --- .github/workflows/main.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 00000000..d6783e21 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,33 @@ +# This is a basic workflow to help you get started with Actions + +name: CI + +# Controls when the action will run. Triggers the workflow on push or pull request +# events but only for the master branch +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + build: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v2 + + # Runs a single command using the runners shell + - name: Run a one-line script + run: echo Hello, world! + + # Runs a set of commands using the runners shell + - name: Run a multi-line script + run: | + echo Add other actions to build, + echo test, and deploy your project. From 5b4251c187fb4befb2c45a4726a76541b16f3407 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Mon, 30 Mar 2020 15:29:06 -0700 Subject: [PATCH 15/17] merge --- ml_service/pipelines/run_train_pipeline.py | 40 ---------------------- 1 file changed, 40 deletions(-) diff --git a/ml_service/pipelines/run_train_pipeline.py b/ml_service/pipelines/run_train_pipeline.py index 39dce482..b68b9a15 100644 --- a/ml_service/pipelines/run_train_pipeline.py +++ b/ml_service/pipelines/run_train_pipeline.py @@ -1,22 +1,3 @@ -<<<<<<< HEAD -import sys -import os -import json -import requests -from azure.common.credentials import ServicePrincipalCredentials - - -tenant_id = os.environ.get("TENANT_ID") -app_id = os.environ.get("SP_APP_ID") -app_secret = os.environ.get("SP_APP_SECRET") - -try: - with open("train_pipeline.json") as f: - train_pipeline_json = json.load(f) -except Exception: - print("No pipeline json found") - sys.exit(0) -======= from azureml.pipeline.core import PublishedPipeline from azureml.core import Experiment, Workspace import argparse @@ -24,7 +5,6 @@ def main(): ->>>>>>> af2b77295365f449d535a4903f5516561e82b9fd parser = argparse.ArgumentParser("register") parser.add_argument( @@ -41,19 +21,7 @@ def main(): ) args = parser.parse_args() -<<<<<<< HEAD -credentials = ServicePrincipalCredentials( - client_id=app_id, - secret=app_secret, - tenant=tenant_id -) - -token = credentials.token['access_token'] -print("token", token) -auth_header = {"Authorization": "Bearer " + token} -======= e = Env() ->>>>>>> af2b77295365f449d535a4903f5516561e82b9fd aml_workspace = Workspace.get( name=e.workspace_name, @@ -61,17 +29,9 @@ def main(): resource_group=e.resource_group ) -<<<<<<< HEAD -response = requests.post( - rest_endpoint, headers=auth_header, - json={"ExperimentName": experiment_name, - "ParameterAssignments": {"model_name": model_name}} -) -======= # Find the pipeline that was published by the specified build ID pipelines = PublishedPipeline.list(aml_workspace) matched_pipes = [] ->>>>>>> af2b77295365f449d535a4903f5516561e82b9fd for p in pipelines: if p.name == e.pipeline_name: From d2411637631ad4039480054b03d4355d479b9ca1 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Mon, 30 Mar 2020 15:40:55 -0700 Subject: [PATCH 16/17] Update and rename main.yml to ci.yml --- .github/workflows/ci.yml | 29 +++++++++++++++++++++++++++++ .github/workflows/main.yml | 33 --------------------------------- 2 files changed, 29 insertions(+), 33 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..495de2ff --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,29 @@ +name: CI + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + model_ci: + # The type of runner that the job will run on + runs-on: ubuntu-latest + container: + image: mcr.microsoft.com/mlops/python:latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v2flake8 --output-file=lint-testresults.xml --format junit-xml + + # Runs a single command using the runners shell + - name: Run lint tests + run: flake8 --output-file=lint-testresults.xml --format junit-xml + + # Runs a set of commands using the runners shell +# - name: Run a multi-line script +# run: | +# echo Add other actions to build, +# echo test, and deploy your project. diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index d6783e21..00000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,33 +0,0 @@ -# This is a basic workflow to help you get started with Actions - -name: CI - -# Controls when the action will run. Triggers the workflow on push or pull request -# events but only for the master branch -on: - push: - branches: [ master ] - pull_request: - branches: [ master ] - -# A workflow run is made up of one or more jobs that can run sequentially or in parallel -jobs: - # This workflow contains a single job called "build" - build: - # The type of runner that the job will run on - runs-on: ubuntu-latest - - # Steps represent a sequence of tasks that will be executed as part of the job - steps: - # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 - - # Runs a single command using the runners shell - - name: Run a one-line script - run: echo Hello, world! - - # Runs a set of commands using the runners shell - - name: Run a multi-line script - run: | - echo Add other actions to build, - echo test, and deploy your project. From 37058ff0d0111f34eb9c93da40f188e360d26876 Mon Sep 17 00:00:00 2001 From: Eugene Fedorenko Date: Mon, 30 Mar 2020 15:43:41 -0700 Subject: [PATCH 17/17] flake8 --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 495de2ff..cacd0b94 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,7 @@ jobs: # Steps represent a sequence of tasks that will be executed as part of the job steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2flake8 --output-file=lint-testresults.xml --format junit-xml + - uses: actions/checkout@v2 # Runs a single command using the runners shell - name: Run lint tests