Coder Social home page Coder Social logo

docker-remote-deployment-action's Introduction

Docker Deployment Action

A GitHub Action for docker-compose deployments on a remote host using SSH.

The Action is adapted from work by wshihadeh

Example

Below is an example of how the action can be used

- name: Start Deployment
  uses: TapTap21/[email protected]
  with:
    remote_docker_host: [email protected]
    ssh_private_key: ${{ secrets.DOCKER_SSH_PRIVATE_KEY }}
    ssh_public_key: ${{ secrets.DOCKER_SSH_PUBLIC_KEY }}
    stack_file_name: docker-compose.yml
    docker_login_password: ${{ secrets.DOCKER_REPO_PASSWORD }}
    docker_login_user: ${{ secrets.DOCKER_REPO_USERNAME }}
    docker_login_registry : ${{ steps.login-ecr.outputs.registry }}
    args: -p myapp up -d

Use the latest tag to run the latest build or a specific version tag. The action pulls a docker image instead of building one to improve performance.

Input

Below is a breakdown of the expected action inputs.

args

Docker-compose runtime arguments and options. Below is a common usage example:

  • -p app_stack_name -d up

remote_docker_host

Specify Remote Docker host. The input value must be in the following format (user@host)

ssh_public_key

Remote Docker SSH public key.

ssh_private_key

SSH private key used to connect to the docker host.

SSH key must be in PEM format (begins with -----BEGIN RSA PRIVATE KEY-----)

ssh_port

The SSH port to be used. Default is 22.

stack_file_name

Docker stack file used. Default is docker-compose.yml

docker_login_user

The username for the container repository user. (DockerHub, ECR, etc.)

docker_login_password

The password for the container repository user.

docker_login_registry

The docker container registry to authenticate against

License

This project is licensed under the MIT license. See the LICENSE file for details.

docker-remote-deployment-action's People

Contributors

taptap21 avatar

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.