From f373b9220a68e821c608dd706be7e23bb9c339c7 Mon Sep 17 00:00:00 2001 From: Dmitry Kolesnikov Date: Thu, 26 Feb 2026 19:26:57 +0200 Subject: [PATCH 1/3] (fea) build lambda from Dockerfile --- container.go | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/container.go b/container.go index 11a13b4..d6d5c66 100644 --- a/container.go +++ b/container.go @@ -43,10 +43,16 @@ type ContainerGoProps struct { // Toolchain configuration for building Go Lambda function Toolchain *Toolchain + // Path to Dockerfile relative to the module, + // if not specified, the default Dockerfile will be generated + Dockerfile string + // Static files included into container, the path is relative to module + // Only added to container if Dockerfile is not specified, otherwise it's caller responsibility to add them into container within Dockerfile StaticAssets []string // Linux Alpine Packages (apk) to be installed within the container + // Only added to container if Dockerfile is not specified, otherwise it's caller responsibility to add them into container within Dockerfile Packages []string } @@ -115,7 +121,15 @@ func NewContainerGo(scope constructs.Construct, id *string, spec *ContainerGoPro panic(fmt.Errorf("unable to build %s/%s", spec.SourceCodeModule, spec.SourceCodeLambda)) } - docker := fmt.Sprintf(` + if spec.Dockerfile != "" { + source := filepath.Join(rootSourceCode(spec.SourceCodeModule), spec.Dockerfile) + target := filepath.Join(path, "Dockerfile") + log.Printf("==> copy %s\n", spec.Dockerfile) + if err := copy(source, target); err != nil { + panic(err) + } + } else { + docker := fmt.Sprintf(` FROM %s %s %s @@ -124,9 +138,10 @@ ADD bootstrap /bin/bootstrap CMD ["/bin/bootstrap"] `, dockerBaseImage(spec), dockerPackages(spec), dockerAssets(path, spec)) - err := os.WriteFile(filepath.Join(path, "Dockerfile"), []byte(docker), 0664) - if err != nil { - panic(err) + err := os.WriteFile(filepath.Join(path, "Dockerfile"), []byte(docker), 0664) + if err != nil { + panic(err) + } } props.Code = awslambda.DockerImageCode_FromImageAsset( From 3a6d5d79b31a5c88b6e80565b3f2860ea37a4d68 Mon Sep 17 00:00:00 2001 From: Dmitry Kolesnikov Date: Thu, 26 Feb 2026 19:38:55 +0200 Subject: [PATCH 2/3] (fix) update the doc --- container.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/container.go b/container.go index d6d5c66..867c3f7 100644 --- a/container.go +++ b/container.go @@ -44,7 +44,11 @@ type ContainerGoProps struct { Toolchain *Toolchain // Path to Dockerfile relative to the module, - // if not specified, the default Dockerfile will be generated + // if not specified, the default Dockerfile will be generated. + // + // The file must contain: + // ADD bootstrap /bin/bootstrap + // CMD ["/bin/bootstrap"] Dockerfile string // Static files included into container, the path is relative to module From 2f5511e219fe902a511c297b904e34b5f1721e3d Mon Sep 17 00:00:00 2001 From: Dmitry Kolesnikov Date: Thu, 26 Feb 2026 19:40:58 +0200 Subject: [PATCH 3/3] (fix) tune logo --- doc/scud-logo-v2.svg | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/doc/scud-logo-v2.svg b/doc/scud-logo-v2.svg index 27ebf95..a363899 100644 --- a/doc/scud-logo-v2.svg +++ b/doc/scud-logo-v2.svg @@ -8,7 +8,7 @@ version="1.1" id="svg1" xml:space="preserve" - inkscape:version="1.4.2 (ebf0e940, 2025-05-08)" + inkscape:version="1.4.3 (0d15f75, 2025-12-25)" sodipodi:docname="scud-logo-v2.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" @@ -23,13 +23,13 @@ inkscape:pagecheckerboard="0" inkscape:deskcolor="#d1d1d1" inkscape:document-units="mm" - inkscape:zoom="1.399126" - inkscape:cx="195.12181" - inkscape:cy="124.72072" + inkscape:zoom="5.6248215" + inkscape:cx="168.00533" + inkscape:cy="150.84923" inkscape:window-width="1216" inkscape:window-height="708" inkscape:window-x="0" - inkscape:window-y="38" + inkscape:window-y="34" inkscape:window-maximized="0" inkscape:current-layer="layer1" /> + sodipodi:nodetypes="cssscssscsccsssscsssssssssscsssssssssssssssscsscsssssscsssscsccssscssssssssscscssssssssssssssssscssssssssssscsssssss" />