ssbs

command module
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2015 License: MIT Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

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.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址