use runtime base image

This commit is contained in:
Jake Runzer
2025-02-13 13:25:26 -07:00
parent 5b13f95e0e
commit e8e0e9e20d
5 changed files with 51 additions and 564 deletions
+1 -1
View File
@@ -137,7 +137,7 @@ func getBaseState(plan *p.BuildPlan, platform specs.Platform) llb.State {
)
state = state.AddEnv("DEBIAN_FRONTEND", "noninteractive")
state = state.Run(llb.Shlex("sh -c 'apt-get update && apt-get install -y --no-install-recommends ca-certificates && rm -rf /var/lib/apt/lists/*'")).Root()
// state = state.Run(llb.Shlex("sh -c 'apt-get update && apt-get install -y --no-install-recommends ca-certificates && rm -rf /var/lib/apt/lists/*'")).Root()
state = state.Dir(WorkingDir)
return state
File diff suppressed because it is too large Load Diff
+4 -20
View File
@@ -1,7 +1,7 @@
[TestGenerateContext - 1]
{
"baseImage": "debian:stable-slim",
"baseImage": "ghcr.io/railwayapp/railpack-runtime-base:latest",
"caches": {
"apt": {
"directory": "/var/cache/apt",
@@ -10,10 +10,6 @@
"apt-lists": {
"directory": "/var/lib/apt/lists",
"type": "locked"
},
"mise": {
"directory": "/mise/cache",
"type": "shared"
}
},
"secrets": [
@@ -56,15 +52,8 @@
"apt",
"apt-lists"
],
"cmd": "sh -c 'apt-get update \u0026\u0026 apt-get install -y ca-certificates curl git'",
"customName": "install apt packages: ca-certificates curl git"
},
{
"caches": [
"mise"
],
"cmd": "sh -c 'curl -fsSL https://mise.run | sh'",
"customName": "install mise"
"cmd": "sh -c 'apt-get update \u0026\u0026 apt-get install -y curl'",
"customName": "install apt packages: curl"
},
{
"customName": "create mise config",
@@ -72,16 +61,10 @@
"path": "/etc/mise/config.toml"
},
{
"caches": [
"mise"
],
"cmd": "sh -c 'mise trust -a \u0026\u0026 mise install'",
"customName": "install mise packages: go, node, python"
}
],
"dependsOn": [
"packages:apt:config"
],
"name": "packages:mise",
"outputs": [
"/mise/shims",
@@ -90,6 +73,7 @@
"/etc/mise/config.toml",
"/root/.local/state/mise"
],
"startingImage": "ghcr.io/railwayapp/railpack-builder-base:latest",
"useSecrets": false
},
{
+1 -1
View File
@@ -17,7 +17,7 @@ import (
)
const (
DefaultBaseImage = "debian:stable-slim"
DefaultBaseImage = "ghcr.io/railwayapp/railpack-runtime-base:latest"
)
type BuildStepOptions struct {
+2
View File
@@ -1,5 +1,7 @@
FROM debian:bookworm-slim
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
ca-certificates \
curl \