From 149344afd8bbaa9a203ce439ccc9a17badbb04a0 Mon Sep 17 00:00:00 2001 From: "Glenn Y. Rolland" Date: Tue, 3 Mar 2020 17:56:10 +0100 Subject: [PATCH] Fix config file name & add colors --- src/pushokku.cr | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/pushokku.cr b/src/pushokku.cr index e0c38ee..fe0721e 100644 --- a/src/pushokku.cr +++ b/src/pushokku.cr @@ -1,6 +1,7 @@ # file: help.cr require "option_parser" require "yaml" +require "colorize" class Pushokku alias Options = { @@ -16,7 +17,7 @@ class Pushokku } def parse_options(args) : Options - config_file = ".pushokku" + config_file = ".pushokku.yml" docker_compose_yml = "docker-compose.yml" environment = "production" @@ -91,6 +92,7 @@ class Pushokku p3_out = IO::Memory.new p3_err = IO::Memory.new + puts "Pushing image...".colorize(:yellow) p3 = Process.new "ssh", [host, "gunzip | docker load"], input: pipe2_reader, output: p3_out, error: p3_err @@ -135,10 +137,13 @@ class Pushokku STDERR.puts "- exit status: #{status.exit_status}" STDERR.puts "- err: #{p3_err}" end + puts "Image pushed successfully!".colorize(:green) end def image_deploy(host, app, version) + puts "Deploying image...".colorize(:yellow) Process.run "ssh", [host, "dokku tags:deploy #{app} #{version}"] + puts "Image deployed successfully!".colorize(:green) end def self.run(args)