Giter Site home page Giter Site logo

treeforest / gohotdeploy Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 4.6 MB

GoHotDeploy is a lightweight tool that enables hot deployment of Go applications using GitLab Webhooks.

License: GNU General Public License v3.0

Makefile 1.10% Go 95.54% Dockerfile 3.36%

gohotdeploy's Introduction

GoHotDeploy

GoHotDeploy is a lightweight tool that enables hot deployment of Go applications using GitLab Webhooks.

English | 简体中文

Usage

  1. Install GoHotDeploy:

    go get github.com/treeforest/gohotdeploy
  2. Create a configuration file config.yml with the following content:

    port: 8080
    repositories:
      my-repo:
        build_relative_dir: .
        build_args_bin: ""

    Replace . with the relative path to the build directory within your Git repository. If build_relative_dir is left empty, it defaults to the current directory of the repository.

    Modify the build_args_bin value to include the desired arguments to be passed when executing the built binary. If build_args_bin is left empty, no additional arguments will be passed during program execution.

  3. Start GoHotDeploy:

    gohotdeploy --config=config.yml

    GoHotDeploy will start an HTTP server listening on the specified port (default: 8080) for GitLab webhook events.

  4. Configure GitLab webhook:

    • Go to your GitLab project settings.
    • Navigate to "Webhooks" in the left sidebar.
    • Add a new webhook with the following settings:
      • URL: http://your-server-ip:8080/
      • Trigger: "Push events"
      • SSL verification: Enable or disable based on your server configuration
      • Save the webhook.

    Whenever a push event occurs in your GitLab repository, GoHotDeploy will automatically build and deploy your application.

License

GNU General Public License v3.0

gohotdeploy's People

Stargazers

Kenson avatar

Watchers

Ginkgo 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.