Skip to content

Minimum Rack based Cloud Native Build Pack sample

Notifications You must be signed in to change notification settings

peco8/minimum-rack-cnb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

minimum-rack-cnb Build

This repository contains instruction how to build image without Dockerfile (a bare minimum Rack app) using Cloud Native Buildpack.

Getting started

Usage

This buildpack is currently intended to be used with the heroku builder heroku/pack:18 via pack.

Locally

Build your app
git clone git@github.com:peco8/minimum-rack-cnb.git
cd minimum-rack-cnb
pack build sample \
     --builder heroku/buildpacks:18
     --path .
Quick test
docker run --rm -e PORT=8080 -p 8080:8080 sample
curl -s http://0.0.0.0:8080

GithubActions (CI)

Container images should be built in CI environment, not local. In this repo, we already have CI environment using GithubActions.

Push and Build
Fork and clone this repo locally
cd minimum-rack-cnb
git commit --allow-empty
git push origin master
Pull
docker pull docker.pkg.github.com/<USERNAME>/minimum-rack-cnb/sample:latest
Quick test
docker run --rm -e PORT=8080 -p 8080:8080 docker.pkg.github.com/<USERNAME>/minimum-rack-cnb/sample