Giter VIP home page Giter VIP logo

autodeploy's Introduction

AutoDeployer

Simple, easy deployment of software from a Git repo.

Requirements ๐Ÿ“ฆ

  • Node.JS 8 or newer
  • Tested on GNU/Linux and macOS

Install ๐Ÿ‘จ๐Ÿปโ€๐Ÿ’ป

Just clone this repository and run npm install, yarn or install the node modules with the package manager of your choice.

Configure ๐Ÿ› 

Edit the settings/config.json file, where you can change the port in which the service listens to requests, the secret it uses, and the directories where there's a repo to pull.

It is not recommended to set a different secret than the one generated, for security reasons. You can do that if you want, but it could be predicted with dictionaries.

If no config.json file is found, or if it gets corrupted, run the script with the --reconfigure parameter.

Configure on your Git provider

Make a Webhook pointing to your AutoDeploy URL (e.g. http://example.com:3000/deploy?key=SECRET). When you make a push, a request will be triggered to the service.

Running it ๐Ÿ’จ

Run it with a user that has permissions in all folders, in order for the pulls to succeed.

Post-Commit commands ๐Ÿ’พ

Do you need to run a post-commit command? Like cleaning cache or restarting a service? Create a script called postinstall.sh (UNIX) or postinstall.cmd (Windows) with the needed commands. This program will run it for you.

How to invoke it ๐Ÿ›ฐ

Make a GET request like this:

http://example.com:3000/deploy?key=SECRET

Contributions โœ…

If you want to contribute or have any suggestion/report, please make a pull request or open an issue. Donations are welcome!

Donate on PayPal

Donate on PayPal

FAQ ๐Ÿค”

Is it safe to make deploys automatically with this?

Depends. Do you just need to run git pull and a couple commands? Then yes. Do you need to recompile the whole kernel and do system-critical stuff? It can, but it's up to you.

Does it work with Google Code, Mercurial or Subversion?

Nope. If you do use such systems, please consider upgrade them to git.

Does it work with insert git provider here?

Yes it does! This only runs git pull on the directories you specify on its settings.

Why is the log filled with favicon requests?

This happens when the request to the auto-deploy server is done though a web browser (typing the URL and entering it, not making any sort of XHR). It can be prevented with a firewall or any sort of source IP whitelist.

autodeploy's People

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.