Coder Social home page Coder Social logo

shipit's Introduction

shipit :shipit:

Minimalistic SSH deployment.

shipit

Installation

$ pathtoshipit=/usr/local/bin/shipit; curl -o $pathtoshipit https://raw.githubusercontent.com/sapegin/shipit/master/bin/shipit; chmod +x $pathtoshipit; unset pathtoshipit

You can use this command to update shipit too.

Use sudo or replace /usr/local/bin/shipit to path somewhere inside your home directory.

Usage

shipit [command|option]

Options

Option Description
-V, --version Print program version
-h, --help Print help (this screen)

Commands

Command Description
<target> Executes <target> target on remote host (run shipit to execute 'deploy' target)
list Print list of available targets
console Open an SSH session on remote host
exec <cmd> Execute <cmd> on remote host

Examples

$ shipit

Will execute deploy target.

$ shipit status

Will execute status target.

$ shipit list

Will show a list of available targets.

$ shipit exec uptime

Will execute uptime command on remote host.

Configuration

You need to create .shipit file in your project’s directory.

Here is a typical config:

host='myhost'
path='sites/example.com'

[deploy]
git checkout master
git pull
npm install
node -e "require('grunt').cli()" _ deploy

[status]
uptime

The only required things is host and path parameters and [deploy] target.

Parameters

host

It’s the same host you use in ssh command. It could be string of format <username>@<ip>:<port> or just a name of ~/.ssh/config record.

path

Project path on remote host. shipit will cd to this directory before executing any command.

Targets

Target is just a bunch of shell command that will be executed on remote host via SSH. You can define as many targets as you want.

Note that you can’t use blank lines inside targets but you can use comments (#) and other things—it’s just a shell script.

Changelog

The changelog can be found in the Changelog.md file.


License

The MIT License, see the included License.md file.

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.