paketo-community / bootstrapper Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
We currently generate a repo that does not include integration tests. This may lead developers to just jump head first into implementing their buildpack without thinking about a set of integration tests that would help to verify its user-facing feature set.
Let's generate a failing integration test suite so that folks will have a place to start writing integration tests.
This is what's in the README:
├── build.go
├── buildpack.toml
├── build_test.go
├── detect.go
├── detect_test.go
├── go.mod
├── init_test.go
├── integration
│ ├── default_test.go
│ ├── init_test.go
│ └── testdata
│ └── default_app
│ └── my-app
├── integration.json
├── LICENSE
├── NOTICE
├── package.toml
├── run
│ └── main.go
└── scripts
├── build.sh
├── integration.sh
├── package.sh
└── unit.sh
This is what was generated:
.github/*
.gitignore
.packit/*
LICENSE
NOTICE
build.go
build_test.go
buildpack.toml
detect.go
detect_test.go
go.mod
go.sum
init_test.go
integration/*
integration.json
run/*
scripts/*
I think the key thing missing is the required .packit/
directory which might get lost in the copy from the generated /tmp/buildpack
directory to the actual working directory the buildpack will be developed in.
Bootstrapper requires you to specify a Github organization and buildpack name to run it, which is effectively the URL the buildpack will live in Github. Could we enhance bootstrapper to include homepage field (i.e https://github.com/<organization>/<buildpack>
)
The bootstrapper has fallen out of date in a number of ways including
go.mod
.github
directoryThese should be resolved so buildpack authors have a seamless and up-to-date bootstrapping experience. First-time contributors likely won't have enough context to un-tangle the issues they run into caused by out-of-date setup.
In #34 @ryanmoran brought up the idea of creating releases of the bootstrapper so that we can make it available as a compiled CLI. This could make the bootstrapper easier to use.
Opening this issue so this suggestion doesn't get forgotten now that #34 is closed.
We're actively moving away from the full-cf
(AKA cflinuxfs3) stack. Could we stop listing org.cloudfoundry.stacks.cflinuxfs3
in the supported stacks list?
It might be useful to have a required tools section for installing bootstrapper that includes installing jam.
I originally tried installing jam with brew and got the wrong one leading to this issue #73
Right now we take in the <organization>/<buildpack-name>
in a yaml file. This is clunky and overkill for the small amount of information that we need.
We should instead allow the user to pass this info in as a command line argument.
$ go run executer/main.go --buildpack <organization>/<buildpack-name>
We should default all buildpacks generated using the Bootstrapper to have the name "Paketo Buildpack" so that we ensure that all buildpacks conform to the Paketo naming convention (see paketo-buildpacks/rfcs#16)
Please upgrade to the latest packit v2 release to enable new features and extended support.
If I give my buildpack the name some-buildpack
, it produces Go code that includes a package some-buildpack
directive. This is not a valid package name as they cannot have a -
. The bootstrapper should remove this -
from the buildpack name for the package name itself while leaving it everywhere else.
I created a new repo with bootstrapper and am trying to run go test ./...
. The first error was missing jam
so I ran brew install jam
. The second error is pasted below. Is the Jamfile something we should be expected to create or can bootstrapper create it?
go test ./...
ok github.com/paketo-buildpacks/git (cached)
Jamfile: No such file or directory
don't know how to make pack
don't know how to make --buildpack
don't know how to make --output
don't know how to make /Users/g/.freezer-cache/git/git-01f2j8rm88jzv2xj85n5m8x9hn.tgz
don't know how to make --version
don't know how to make 1.2.3
...found 8 target(s)...
...can't find 6 target(s)...
--- FAIL: TestIntegration (0.11s)
init_test.go:57:
Unexpected error:
<*fmt.wrapError | 0xc000072aa0>: {
msg: "failed to package buildpack: exit status 1",
err: <*exec.ExitError | 0xc000072a80>{
ProcessState: {
pid: 59102,
status: 256,
rusage: {
Utime: {
Sec: 0,
Usec: 2528,
Pad_cgo_0: [0, 0, 0, 0],
},
Stime: {
Sec: 0,
Usec: 1566,
Pad_cgo_0: [0, 0, 0, 0],
},
Maxrss: 1560576,
Ixrss: 0,
Idrss: 0,
Isrss: 0,
Minflt: 542,
Majflt: 0,
Nswap: 0,
Inblock: 0,
Oublock: 0,
Msgsnd: 0,
Msgrcv: 0,
Nsignals: 0,
Nvcsw: 1,
Nivcsw: 8,
},
},
Stderr: nil,
},
}
failed to package buildpack: exit status 1
occurred
FAIL
FAIL github.com/paketo-buildpacks/git/integration 0.295s
? github.com/paketo-buildpacks/git/run [no test files]
FAIL
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.