GithubHelp home page GithubHelp logo

sellsuki / codechic-cli Goto Github PK

View Code? Open in Web Editor NEW
4.0 6.0 2.0 788 KB

🐳 ⚓️ Easy way for deploy your docker image to Amazon Elastic Beanstalk with Codeship Pro

License: MIT License

JavaScript 95.87% Shell 4.13%
codeship codeship-pro cli docker aws elasticbeanstalk ecr ecs s3 jet codeship-aes-key

codechic-cli's Introduction

CodeChic CLI

Easy way for deploy your docker image to Amazon Elastic Beanstalk with Codeship Pro

NPM version NPM downloads CircleCI

codechic-cli

Easy way for deploy your docker image to Amazon Elastic Beanstalk with Codeship Pro

Requirement

  • AWS ACCOUNT ID
  • AWS ACCESS KEY ID
  • AWS SECRET ACCESS KEY
  • AWS Application name
  • AWS application enveronment name
  • S3 bucket name
  • AWS registry
  • Codeship aes key
  • dockerfile
  • npm

Installation

npm install codechic -g

Process of Codeship Pro deploy your docker image to EB

How to use

1. Encrypt your AWS credential

  • Step first you must create env file (in anywhere).

    Example: env

    AWS_ACCOUNT_ID=xxxxxxxxxxxxxxx
    AWS_ACCESS_KEY_ID=yyyyyyyyyyyyy
    AWS_SECRET_ACCESS_KEY=aaaaaaaaaaaaaa
    AWS_REGION=ur-region
    
  • Download Codeship AES Key

  • Install jet CLI. (Installing The Jet CLI)

  • Just encrypt file env with jet CLI. See More

    // Command:
    
    $jet encrypt ${YOUR_ENV_FILE} ${OUTPUT_FILE_NAME}
    
    // Example:
    
    $jet encrypt env aws_credes.encrypted
    

2. Use codechic CLI

  • Run this command :

    $cd {your-repository}
    $codechic init
    
  • Fill your information on console.

    1. Docker port
    2. AWS registry url
    3. Image name
    4. EB application name
    5. EB environment name
    6. S3 bucket
    7. Your encrypted file
    8. AWS region
    9. Do you have test command ? (y/N)
    10. Your test command (optional)
    
  • You will receive file & directory for deployment.

3. Create your Dockerfile

  • Move your DockerFile to your repository.

4. Copy file encrypted to

./deploy/${YOUR_FILE}

File structure

- my-project
  -/deploy
    -aws_deployment
    -Dockerrun.aws.json
    -aws_credes.encrypted
  -codeship-services.yml
  -codeship-steps.yml
  -Dockerfile

5. Push your code !!

⚠️ ️ BEWARE !!!

- Don't push your codeship.aes and your AWS credential file to git.

License

MIT

Developed with ❤️ and ☕️

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.