class Fastlane::Actions::DockerBuildAction
Public Class Methods
available_options()
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 22 def self.available_options [ FastlaneCore::ConfigItem.new(key: :repository, description: "The docker repository", env_name: "DOCKER_BUILD_REPOSITORY"), FastlaneCore::ConfigItem.new(key: :tag, description: "The tag for the new image", default_value: "latest", env_name: "DOCKER_BUILD_TAG"), FastlaneCore::ConfigItem.new(key: :path, description: "Path to the Dockerfile", default_value: ".", env_name: "DOCKER_BUILD_PATH") ] end
description()
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 18 def self.description "Build docker images in the current directory" end
is_supported?(platform)
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 54 def self.is_supported?(platform) true end
output()
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 38 def self.output [ ["DOCKER_BUILT_IMAGE", "The ID of the docker image that was built. Other docker actions pick this up automatically"], ["DOCKER_BUILT_REPO", "The Repository of the docker image that was built. Other docker actions pick this up automatically"], ["DOCKER_BUILT_TAG", "The Tag of the docker image that was built. Other docker actions pick this up automatically"] ] end
return_value()
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 46 def self.return_value "The ID of the created image" end
run(params)
click to toggle source
# File lib/fastlane/plugin/docker/actions/docker_build.rb, line 10 def self.run(params) UI.message "Building docker image..." Actions.lane_context[SharedValues::DOCKER_BUILT_IMAGE] = DockerClient.new.build(params[:repository], params[:path], tag: params[:tag]) Actions.lane_context[SharedValues::DOCKER_BUILT_REPO] = params[:repository] Actions.lane_context[SharedValues::DOCKER_BUILT_TAG] = params[:tag] end