DevopsArtFactory / goployer

AWS Deployer with Go
https://goployer.dev
Apache License 2.0
72 stars 13 forks source link

add instance restart #121

Closed GwonsooLee closed 3 years ago

GwonsooLee commented 3 years ago

Fixes: #120

Description Instance Refresh is the feature which changes instances of autoscaling without changing capacity manually. This helps when user wants to change instance with the new one or move VM to other place.

Usage

❯ goployer refresh hello -v debug --auto-apply --instance-warmup=120 --polling-interval=20s
INFO[0000] Goployer {Version: BuildDate: GitCommit: GitTreeState: Platform:darwin/amd64} 
DEBU[0000] Start to trigger instance refresh            
DEBU[0000] Instance Warmup time: 120s                   
DEBU[0000] Minimum healthy instance percentage: 90s     
DEBU[0003] Start to check instance refresh status       
DEBU[0003] Current time: 2020-11-18 11:05:01.878251 +0900 KST m=+3.880962992 / Timeout: 1h0m0s 
DEBU[0003] Polling interval: 20s                        
DEBU[0003] Current status: c47db010-18c8-4221-b117-xxxxx / InProgress 
DEBU[0024] Current status: c47db010-18c8-4221-b117-xxxxx / InProgress 
DEBU[0044] Current status: c47db010-18c8-4221-b117-xxxxx / InProgress 
...
DEBU[0367] Current status: c47db010-18c8-4221-b117-xxxxx / InProgress 
DEBU[0388] Current status: c47db010-18c8-4221-b117-xxxxx / InProgress 
DEBU[0408] Current status: c47db010-18c8-4221-b117-xxxxx / Successful 
DEBU[0408] Instance refresh is finished because the status is Successful 
Name:                  hello-artd_apne2-v001
Instance Refresh ID:   c47db010-18c8-4221-b117-xxxxx
Start Time:            2020-11-18 02:03:49 +0000 UTC
End Time:              2020-11-18 02:11:30 +0000 UTC
Status:                Successful
codecov[bot] commented 3 years ago

Codecov Report

Merging #121 (3a422e1) into main (6b116a6) will decrease coverage by 0.11%. The diff coverage is 0.00%.

Impacted file tree graph

@@           Coverage Diff            @@
##            main    #121      +/-   ##
========================================
- Coverage   5.30%   5.18%   -0.12%     
========================================
  Files         26      27       +1     
  Lines       4376    4474      +98     
========================================
  Hits         232     232              
- Misses      4133    4231      +98     
  Partials      11      11              
Impacted Files Coverage Δ
pkg/aws/ec2.go 0.00% <0.00%> (ø)
pkg/constants/constants.go 66.66% <ø> (ø)
pkg/inspector/inspector.go 0.00% <ø> (ø)
pkg/refresh/refresh.go 0.00% <0.00%> (ø)
pkg/runner/runner.go 4.45% <0.00%> (ø)
pkg/tool/common.go 12.32% <0.00%> (-1.74%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 6b116a6...3368fab. Read the comment docs.