devenv

command module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 28, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

README

Background

Getting really tiresome to experiment stuff with multiple scripts. This is an attempt for one cli to rule them all

Additionally it's is helping me learn how to write go command line interface using cobra (https://github.com/spf13/cobra)

Prerequisites

aws

How to add new commands

cobra add <cmdname>

Notes

In order to use logger, make sure startLog is called first

Useful scripts

remove images

docker images --filter "reference=<accountid>.dkr.ecr.ap-southeast-2.amazonaws.com/sample" --format "{{.ID}}"| %{ docker rmi $_ --force}

Using

Deploy front proxy

    devenv deploy --type front-proxy

Deploy apps

    devenv deploy appName --path <folder where Dockerfile is, exclude if current folder has it>

Start environment

    devenv start

Stop environment

    devenv stop

Initialise environment

    devenv init

Tear down environment

    devenv teardown

Initialise configuration

    devenv init config

Ssh into ec2 instance

    rm ~/.ssh/known_hosts
    ssh -i ~/.ssh/ecs-instance-ap-southeast-2.pem ec2-user@<domain>

Documentation

Overview

Copyright © 2020 kahgeh

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
cmd
aws
ctx

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL