Code Monkey home page Code Monkey logo

ssbs's Introduction

Super Simple Build Server GoDoc Build Status

An incredibly simple build server.

WARNING Don't run this in the wild! ANY command can be passed as a step.

Current features:

  • Build from GitHub (must work using git clone without passwords)
    • Either pre-configure SSH
    • Or use an OAuth token in the build request
  • Build a specific branch, tag or commit
  • Specify custom build and publish steps

Install ssbs:

go get github.com/ian-kent/ssbs

Start the server:

# Default port 5252
ssbs

# Custom interface/port
ssbs -bind=:5353

Build something:

curl -v -d '{"repo":"ian-kent/ssbs","commit":"master","build":[ ["make"], ["make","dist"] ], "artifacts": "ssbs-*.zip" }' http://localhost:5252/build

Build something with environment variables:

curl -v -d '{"repo":"ian-kent/ssbs","env":{"GOPATH", ".."},"commit":"master","build":[ ["make"], ["make","dist"] ], "artifacts": "ssbs-*.zip" }' http://localhost:5252/build

Or build something using HTTPS:

curl -v -d '{"repo":"ian-kent/ssbs","commit":"master","build":[ ["make"], ["make","dist"] ], "artifacts": "ssbs-*.zip", "token": "-" }' http://localhost:5252/build

Or build something with a GitHub token:

curl -v -d '{"repo":"ian-kent/ssbs","commit":"master","build":[ ["make"], ["make","dist"] ], "artifacts": "ssbs-*.zip", "token": "YOUR-GITHUB-TOKEN" }' http://localhost:5252/build

Or build something with publish steps:

curl -v -d '{"repo":"ian-kent/ssbs","commit":"master","build":[ ["make"], ["make","dist"] ], "publish":[ ["echo", "hi"] ] "artifacts": "ssbs-*.zip" }' http://localhost:5252/build

And get back the artifacts:

{
  "build": [
    {
      "step": ["make"],
      "stdout": "",
      "stderr": "",
      "error": "",
    },
    {
      "step": ["make", "dist"],
      "stdout": "",
      "stderr": "",
      "error": "",
    }
  ],
  "artifacts": {
    "ssbs-1.0.1.zip": "BASE64_ENCODED_DATA"
  }
}

Publishing artifacts

You can publish artifacts using the publish step, for example to upload the build artifacts to an imagestore.

curl -v -d '{"repo":"ian-kent/ssbs","env":{"GOPATH":"$WORKDIR/gopath", "PATH":"$PATH:$WORKDIR/gopath/bin"},"commit":"master","build":[ ["make"], ["make","dist"] ], "publish": [ ["curl", "-X", "POST", "--data-binary", "@ssbs-1.0.8.zip", "http://localhost:5253/images/ssbs-1.0.8.zip"] ] }' http://localhost:5252/build

Using Marathon

If you're using Mesos and Marathon, you can easily start ssbs:

Command:

./ssbs -bind=:$PORT

URI:

https://github.com/ian-kent/ssbs/releases/download/v1.0.8/ssbs-1.0.8_linux_amd64.zip

Licence

Copyright ยฉโ€Ž 2015, Ian Kent (http://www.iankent.eu).

Released under MIT license, see LICENSE for details.

ssbs's People

Contributors

ian-kent avatar

Watchers

 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.