Skip to content

Commit

Permalink
Merge pull request #162 from gliderlabs/master
Browse files Browse the repository at this point in the history
release 0.3.14
  • Loading branch information
michaelshobbs authored Jun 28, 2016
2 parents 3032d4c + eec2c5e commit 6e4f142
Show file tree
Hide file tree
Showing 9 changed files with 48 additions and 21 deletions.
16 changes: 15 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,19 @@ All notable changes to this project will be documented in this file.
### Changed


## [0.3.14] - 2016-06-27
### Added
- @michaelshobbs implement heroku-like buildpack detect order and output. closes #133

### Fixed
- @michaelshobbs because nodejs matches before ember, manually set the ember buildpack

### Changed
- @michaelshobbs Update go to version v41
- @michaelshobbs Update grails to version v21
- @michaelshobbs Update php to version v107


## [0.3.13] - 2016-05-09
### Fixed
- @michaelshobbs ensure correct permissions on tgz buildpack directories
Expand Down Expand Up @@ -212,7 +225,8 @@ All notable changes to this project will be documented in this file.
- User for `buildpack-build` is `$USER` or randomized
- User for `procfile-exec` is `$USER` or detected from `/app`

[unreleased]: https://github.com/gliderlabs/herokuish/compare/v0.3.13...HEAD
[unreleased]: https://github.com/gliderlabs/herokuish/compare/v0.3.14...HEAD
[0.3.14]: https://github.com/gliderlabs/herokuish/compare/v0.3.13...v0.3.14
[0.3.13]: https://github.com/gliderlabs/herokuish/compare/v0.3.12...v0.3.13
[0.3.12]: https://github.com/gliderlabs/herokuish/compare/v0.3.11...v0.3.12
[0.3.11]: https://github.com/gliderlabs/herokuish/compare/v0.3.10...v0.3.11
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FROM heroku/cedar:14
RUN curl https://github.com/gliderlabs/herokuish/releases/download/v0.3.13/herokuish_0.3.13_linux_x86_64.tgz \
RUN curl https://github.com/gliderlabs/herokuish/releases/download/v0.3.13/herokuish_0.3.14_linux_x86_64.tgz \
--silent -L | tar -xzC /bin
RUN /bin/herokuish buildpack install \
&& ln -s /bin/herokuish /build \
Expand Down
13 changes: 11 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
NAME = herokuish
HARDWARE = $(shell uname -m)
VERSION ?= 0.3.13
VERSION ?= 0.3.14
IMAGE_NAME ?= $(NAME)
BUILD_TAG ?= dev

BUILDPACK_ORDER := multi ruby nodejs clojure python java gradle grails scala play php go erlang static emberjs
SHELL := /bin/bash

build:
cat buildpacks/*/buildpack* | sed 'N;s/\n/ /' | sort > include/buildpacks.txt
@count=0; \
for i in $(BUILDPACK_ORDER); do \
bp_count=$$(printf '%02d' $$count) ; \
echo -n "$${bp_count}_buildpack-$$i "; \
cat buildpacks/*-$$i/buildpack* | sed 'N;s/\n/ /'; \
count=$$((count + 1)) ; \
done > include/buildpacks.txt
go-bindata include
mkdir -p build/linux && GOOS=linux go build -a -ldflags "-X main.Version=$(VERSION)" -o build/linux/$(NAME)
mkdir -p build/darwin && GOOS=darwin go build -a -ldflags "-X main.Version=$(VERSION)" -o build/darwin/$(NAME)
Expand Down
1 change: 1 addition & 0 deletions buildpacks/buildpack-emberjs/tests/emberjs/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export BUILDPACK_URL=https://codon-buildpacks.s3.amazonaws.com/buildpacks/heroku/emberjs.tgz
2 changes: 1 addition & 1 deletion buildpacks/buildpack-go/buildpack-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v36
v41
2 changes: 1 addition & 1 deletion buildpacks/buildpack-grails/buildpack-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v20
v21
2 changes: 1 addition & 1 deletion buildpacks/buildpack-php/buildpack-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v102
v107
4 changes: 3 additions & 1 deletion buildpacks/test
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,15 @@ app-test() {

# runs the generic app test
run-test() {
[[ "$TRACE" ]] && set -x
declare app="$1"
local buildpack="buildpack-${1%%-*}"
cd "$(dirname $BASH_SOURCE)"
local app_path="$PWD/$buildpack/tests/$app"
cd - &> /dev/null
[[ "$CI" ]] || rmflag="--rm"
docker run $rmflag -v "$app_path:/tmp/app" herokuish:dev /bin/herokuish test / "$app"
[[ "$TRACE" ]] && debug_flag="-e TRACE=true"
docker run $rmflag $debug_flag -v "$app_path:/tmp/app" herokuish:dev /bin/herokuish test / "$app"
}

main() {
Expand Down
27 changes: 14 additions & 13 deletions include/buildpack.bash
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ buildpack-install() {
declare url="$1" commit="$2" name="$3"
ensure-paths
if [[ ! "$url" ]]; then
asset-cat include/buildpacks.txt | while read url commit; do
buildpack-install "$url" "$commit"
asset-cat include/buildpacks.txt | while read name url commit; do
buildpack-install "$url" "$commit" "$name"
done
return
fi
Expand Down Expand Up @@ -109,18 +109,19 @@ buildpack-execute() {

selected_name="$(unprivileged $selected_path/bin/detect $build_path || true)"
else
# force heroku-buildpack-multi to detect first if exists
if ls "$buildpack_path/heroku-buildpack-multi" > /dev/null 2>&1; then
selected_name="$(unprivileged $buildpack_path/heroku-buildpack-multi/bin/detect $build_path)" \
&& selected_path="$buildpack_path/heroku-buildpack-multi"
local buildpacks=($buildpack_path/*)
local valid_buildpacks=()
for buildpack in "${buildpacks[@]}"; do
unprivileged $buildpack/bin/detect $build_path &> /dev/null \
&& valid_buildpacks+=("$buildpack")
done
if [[ ${#valid_buildpacks[@]} -gt 1 ]]; then
title "Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used."
echo "Detected buildpacks: $(sed -e "s:/tmp/buildpacks/[0-9][0-9]_buildpack-::g" <<< "${valid_buildpacks[@]}")" | indent
fi
if [[ ! "$selected_path" ]]; then
local buildpacks=($buildpack_path/*)
for buildpack in "${buildpacks[@]}"; do
selected_name="$(unprivileged $buildpack/bin/detect $build_path)" \
&& selected_path="$buildpack" \
&& break
done
if [[ ${#valid_buildpacks[@]} -gt 0 ]]; then
selected_path="${valid_buildpacks[0]}"
selected_name=$(unprivileged $selected_path/bin/detect $build_path)
fi
fi
if [[ "$selected_path" ]] && [[ "$selected_name" ]]; then
Expand Down

0 comments on commit 6e4f142

Please sign in to comment.