Coder Social home page Coder Social logo

bryanyork / omnibus-flapjack Goto Github PK

View Code? Open in Web Editor NEW

This project forked from flapjack/omnibus-flapjack

0.0 2.0 0.0 437 KB

Flapjack packages for all! Build the packages, and update the repositories.

Home Page: http://flapjack.io

Ruby 88.00% Shell 12.00%

omnibus-flapjack's Introduction

Flapjack Omnibus project

This project creates full-stack platform-specific packages for Flapjack using omnibus and maintains appropriate package repositories at packages.flapjack.io

We highly recommend you build this with the included Rakefile, which uses Docker. If you prefer to build this manually, please see (Building Manually)[BuildManually.md]

You'll need a docker server and a local docker command that can talk to it. An easy way to get a docker server going is using boot2docker. A more complicated way is to use an EC2 instance, which is what we use for the official packages. There's a packer config for building the AMIs we use. See the Flapjack docs on package building and getting going with boot2docker.

AWS CLI Configuration

If you want the build rake task to publish to packages.flapjack.io then you'll need to have set up a valid configuration for aws cli. You can do this as follows:

./configure_awscli \
  --aws-access-key-id xxx \
  --aws-secret-access-key xxx \
  --default-region us-east-1

Build

Run the build rake task. It drives docker and omnibus to build packages.

The following environment variables affect what build does:

  • BUILD_REF - the branch, tag, or commit (on master) to build (Required). If a tag, it'll start with a v if it's a release tag, eg v1.0.0rc5
  • DISTRO - only "ubuntu" is currently supported (Optional, Default: "ubuntu")
  • DISTRO_RELEASE - the release name, eg "precise" (Optional, Default: "trusy")
  • DRY_RUN - if set, just shows what would be gone (Optional, Default: nil)
  • OFFICIAL_FLAPJACK_PACKAGE - if true, signs built packages, assuming that the Flapjack Signing Key is on the system

Eg:

export BUILD_REF="1.1.0"
export DISTRO="ubuntu"
export DISTRO_RELEASE="precise"
export OFFICIAL_FLAPJACK_PACKAGE="true"

bundle exec rake build

Publish

Run the publish rake task to publish a previously built package. The package is added to the experimental component of your apt package repo.

The following environment variable is required:

  • PACKAGE_FILE - the filename of the package file you've just built and want to publish. This is assumed to be in omnibus-flapjack/pkg (which is where the Rakefile build puts it)

Eg:

export PACKAGE_FILE=flapjack_1.1.0~+20141003112645-master-trusty-1_amd64.deb
bundle exec rake build

Testing Packages

The test task starts up a docker instance with a pristine copy of the distribution, installs the package given, and runs Serverspec against it.

The following environment variable is required:

  • PACKAGE_FILE - the filename of the package file you've just built and want to publish. This is assumed to be in omnibus-flapjack/pkg (which is where the Rakefile build puts it)

Build and Test

The rake task build_and_test just calls the build and test rake tasks sequentially. You don't need to set the PACKAGE_FILE environment variable however, as the package meta data is already determined.

Build and Publish

The rake task build_and_publish just calls the build, test and publish rake tasks sequentially. You don't need to set the PACKAGE_FILE environment variable however, as the package meta data is already determined.

The environment variables are as per the build rake task.

Eg:

export BUILD_REF="1.1.0"
export DISTRO="ubuntu"
export DISTRO_RELEASE="precise"
bundle exec rake build_and_publish

Promote from Experimental to Main

When testing of the package candidiate is completed, use the promote task to repackage the deb for the main component in the case of debs, or copy the package to flapjack from flapjack-experimental in the case of rpms.

You'll need the name of the candidate package, which will be in the output of build, or look in S3 to find it. Eg:

export PACKAGE_FILE=flapjack_1.1.0~+20141003112645-master-trusty-1_amd64.deb
bundle exec rake promote

Tests

Tests are fairly minimal right now, would you like to expand them? Check out the spec directory! Run with:

bundle install
bundle exec rspec

omnibus-flapjack's People

Contributors

ali-graham avatar auxesis avatar bernd avatar jessereynolds avatar jsoriano avatar krisbuytaert avatar michaelneale avatar sarahriley avatar someword avatar

Watchers

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