Sha256: a1ecb108129b5e8e7ee306b1d39503dee0d3d31ddf10b2988c1ef1f40570043c

Contents?: true

Size: 727 Bytes

Versions: 6

Compression:

Stored size: 727 Bytes

Contents

# frozen_string_literal: true

# takeltau docker image uppdate
module DockerImageUpdate
  # Backend method for docker image update.
  def docker_image_update
    return false unless docker_check_daemon

    cmd_docker_pull_latest = _docker_image_update_cmd_docker_pull_latest

    cmd_docker_remove_dangling =
      config.active['cmd_docker_image_update_docker_remove_dangling']

    run_and_exit "#{cmd_docker_pull_latest} && #{cmd_docker_remove_dangling}"
  end

  private

  # Prepare dpcker pull latest command.
  def _docker_image_update_cmd_docker_pull_latest
    format(
      config.active['cmd_docker_image_update_docker_pull_latest'],
      docker_user: @docker_user,
      docker_repo: @docker_repo
    )
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
takeltau-0.34.15 lib/takeltau/docker/image/update.rb
takeltau-0.34.14 lib/takeltau/docker/image/update.rb
takeltau-0.34.13 lib/takeltau/docker/image/update.rb
takeltau-0.34.12 lib/takeltau/docker/image/update.rb
takeltau-0.34.11 lib/takeltau/docker/image/update.rb
takeltau-0.34.9 lib/takeltau/docker/image/update.rb