Sha256: 84f202fe342b250b144c94f7e4c06a041c45cf4c494eac85195b183641014e4a

Contents?: true

Size: 634 Bytes

Versions: 27

Compression:

Stored size: 634 Bytes

Contents

module EasyML
  class DeploysController < ApplicationController
    def create
      run = EasyML::RetrainingRun.find(params[:retraining_run_id])
      run.update(is_deploying: true)
      @deploy = EasyML::Deploy.create!(
        model_id: params[:easy_ml_model_id],
        retraining_run_id: params[:retraining_run_id],
        trigger: "manual",
      )
      @deploy.deploy

      flash[:notice] = "Model deployment has started"
      redirect_to easy_ml_model_path(@deploy.model)
    rescue => e
      flash[:alert] = "Trouble deploying model: #{e.message}"
      redirect_to easy_ml_model_path(@deploy.model)
    end
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
easy_ml-0.2.0.pre.rc27 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc26 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc25 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc24 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc23 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc22 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc21 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc20 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc19 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc18 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc17 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc16 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc15 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc14 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc13 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc12 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc11 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc10 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc9 app/controllers/easy_ml/deploys_controller.rb
easy_ml-0.2.0.pre.rc8 app/controllers/easy_ml/deploys_controller.rb