railpack

Configure and troubleshoot Railpack builds, with emphasis on RAILPACK_* environment variables, railpack.json overlays, build-plan inspection, local CLI installation and usage, and local BuildKit containers. Use for Railpack provider configuration, custom install/build/start commands, Mise or Apt packages, build or runtime variables and secrets, generated-plan debugging, BUILDKIT_HOST errors, or running Railpack from a release or source checkout.

Install
npx skills add 'https://github.com/railwayapp/railpack/tree/main/.'
Incomplete bundle · no download
main · 21a254fScanned 2026-09-17

Contributors

GitHub-linked commit authors for this SKILL.md at the saved revision. Co-authors and history before file renames are not included.

File history ↗

buildkit/build_llb/build_graph_test.go

buildkit/build_llb/build_graph_test.goBrowse 1970 files
View on GitHub
← Back to SKILL.md
package build_llb import (	"testing" 	"github.com/moby/buildkit/client/llb"	specs "github.com/opencontainers/image-spec/specs-go/v1"	"github.com/railwayapp/railpack/core/plan"	"github.com/stretchr/testify/require") func TestBuildGraphNoCache(t *testing.T) {	p := &plan.BuildPlan{		Steps: []plan.Step{			{				Name:   "test",				Caches: []string{"test-cache"},			},		},		Caches: map[string]*plan.Cache{			"test-cache": {				Directory: "/root/.cache",			},		},	} 	localState := llb.Local("context")	cacheStore := NewBuildKitCacheStore("")	platform := specs.Platform{OS: "linux", Architecture: "amd64"} 	t.Run("with NoCache=false", func(t *testing.T) {		g, err := NewBuildGraph(p, &localState, cacheStore, "", &platform, "", false)		require.NoError(t, err)		require.False(t, g.NoCache)	}) 	t.Run("with NoCache=true", func(t *testing.T) {		g, err := NewBuildGraph(p, &localState, cacheStore, "", &platform, "", true)		require.NoError(t, err)		require.True(t, g.NoCache)		// NoCache should NOT affect if caches are enabled or not, it just affects the layer cache		opts, err := g.getCacheMountOptions([]string{"test-cache"})		require.NoError(t, err)		require.Len(t, opts, 1)	})}