diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 919f2c44..ec8ffb3f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,14 +1,18 @@ repos: - repo: https://github.com/gitleaks/gitleaks - rev: v8.16.3 + rev: v8.21.2 hooks: - id: gitleaks - repo: https://github.com/golangci/golangci-lint - rev: v1.52.2 + rev: v1.62.0 hooks: - id: golangci-lint - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.4.0 + rev: v5.0.0 hooks: - id: end-of-file-fixer - id: trailing-whitespace +- repo: https://github.com/crate-ci/typos + rev: v1.27.3 + hooks: + - id: typos diff --git a/_typos.toml b/_typos.toml new file mode 100644 index 00000000..3ef10474 --- /dev/null +++ b/_typos.toml @@ -0,0 +1,2 @@ +[default.extend-words] +ba = "ba" \ No newline at end of file diff --git a/cmd/test2json2gha/main.go b/cmd/test2json2gha/main.go index b4679535..696f7ad8 100644 --- a/cmd/test2json2gha/main.go +++ b/cmd/test2json2gha/main.go @@ -113,7 +113,7 @@ func do(in io.Reader, out io.Writer, modName string) (bool, error) { } if te.Test == "" { - // Don't bother processing events that aren't specfically for a test + // Don't bother processing events that aren't specifically for a test // Go adds extra events in for package level info that we don't need. continue } diff --git a/docs/spec.schema.json b/docs/spec.schema.json index 6604bb61..182cb727 100644 --- a/docs/spec.schema.json +++ b/docs/spec.schema.json @@ -262,7 +262,7 @@ }, "additionalProperties": false, "type": "object", - "description": "CheckOutput is used to specify the exepcted output of a check, such as stdout/stderr or a file." + "description": "CheckOutput is used to specify the expected output of a check, such as stdout/stderr or a file." }, "Command": { "properties": { @@ -497,7 +497,7 @@ "type": "string" }, "type": "array", - "description": "Version is a list of version constraints for the package.\nThe format of these strings is depenendent on the package manager of the target system.\nExamples:\n [\"\u003e=1.0.0\", \"\u003c2.0.0\"]" + "description": "Version is a list of version constraints for the package.\nThe format of these strings is dependent on the package manager of the target system.\nExamples:\n [\"\u003e=1.0.0\", \"\u003c2.0.0\"]" }, "arch": { "items": { @@ -776,11 +776,11 @@ "properties": { "file": { "$ref": "#/$defs/SourceInlineFile", - "description": "File is the inline file to generate.\nFile is treated as a literal single file.\n[SourceIsDir] will return false when this is set.\nThis is mutally exclusive with [Dir]" + "description": "File is the inline file to generate.\nFile is treated as a literal single file.\n[SourceIsDir] will return false when this is set.\nThis is mutually exclusive with [Dir]" }, "dir": { "$ref": "#/$defs/SourceInlineDir", - "description": "Dir creates a directory with the given files and directories.\n[SourceIsDir] will return true when this is set.\nThis is mutally exclusive with [File]" + "description": "Dir creates a directory with the given files and directories.\n[SourceIsDir] will return true when this is set.\nThis is mutually exclusive with [File]" } }, "additionalProperties": false, @@ -984,7 +984,7 @@ "$ref": "#/$defs/TestSpec" }, "type": "array", - "description": "Tests are the list of tests to run for the package that should work regardless of target OS\nEach item in this list is run with a separate rootfs and cannot interact with other tests.\nEach [TestSpec] is run with a separate rootfs, asyncronously from other [TestSpec]." + "description": "Tests are the list of tests to run for the package that should work regardless of target OS\nEach item in this list is run with a separate rootfs and cannot interact with other tests.\nEach [TestSpec] is run with a separate rootfs, asynchronously from other [TestSpec]." } }, "additionalProperties": false, diff --git a/frontend/deb/debroot.go b/frontend/deb/debroot.go index 48399886..c8e555a0 100644 --- a/frontend/deb/debroot.go +++ b/frontend/deb/debroot.go @@ -30,7 +30,7 @@ var patchHeader []byte var debianInstall []byte // This creates a directory in the debian root directory for each patch, and copies the patch files into it. -// The format for each patch dir matches what would normaly be under `debian/patches`, just that this is a separate dir for every source we are patching +// The format for each patch dir matches what would normally be under `debian/patches`, just that this is a separate dir for every source we are patching // This is purely for documenting in the source package how patches are applied in a more readable way than the big merged patch file. func sourcePatchesDir(sOpt dalec.SourceOpts, base llb.State, dir, name string, spec *dalec.Spec, opts ...llb.ConstraintsOpt) ([]llb.State, error) { patchesPath := filepath.Join(dir, name) diff --git a/frontend/deb/template_rules.go b/frontend/deb/template_rules.go index 88a9ed15..4a901d0a 100644 --- a/frontend/deb/template_rules.go +++ b/frontend/deb/template_rules.go @@ -136,7 +136,7 @@ func (w *rulesWrapper) OverrideSystemd() (fmt.Stringer, error) { // custom postinst/postrm script. // // We also only need to do this once per basename, so we don't need to - // itterate over every unit. + // iterate over every unit. // Get the first key which we'll use to check if the unit is enabled. // Either all units are enabled or not enabled OR we need to do custom enable diff --git a/frontend/gateway.go b/frontend/gateway.go index 0a929dff..862afb67 100644 --- a/frontend/gateway.go +++ b/frontend/gateway.go @@ -228,14 +228,14 @@ func Warn(ctx context.Context, client gwclient.Client, st llb.State, msg string) def, err := st.Marshal(ctx) if err != nil { - bklog.G(ctx).WithError(err).WithField("warn", msg).Warn("Error marshalling state for outputing warning message") + bklog.G(ctx).WithError(err).WithField("warn", msg).Warn("Error marshalling state for outputting warning message") } var dgst digest.Digest if def != nil { dgst, err = def.Head() if err != nil { - bklog.G(ctx).WithError(err).WithField("warn", msg).Warn("Could not get state digest for outputing warning message") + bklog.G(ctx).WithError(err).WithField("warn", msg).Warn("Could not get state digest for outputting warning message") } } diff --git a/frontend/jammy/handle_container.go b/frontend/jammy/handle_container.go index 69cf4dc7..0b6ef251 100644 --- a/frontend/jammy/handle_container.go +++ b/frontend/jammy/handle_container.go @@ -162,7 +162,7 @@ func buildImageRootfs(worker llb.State, spec *dalec.Spec, sOpt dalec.SourceOpts, tmp := llb.Scratch().File(llb.Mkfile("tmp", 0o644, nil)) // Warning: HACK here // The base ubuntu image has this `excludes` config file which prevents - // installation of a lot of thigns, including doc files. + // installation of a lot of things, including doc files. // This is mounting over that file with an empty file so that our test suite // passes (as it is looking at these files). llb.AddMount("/etc/dpkg/dpkg.cfg.d/excludes", tmp, llb.SourcePath("tmp")).SetRunOption(cfg) diff --git a/frontend/mux.go b/frontend/mux.go index a84d9d25..c329921f 100644 --- a/frontend/mux.go +++ b/frontend/mux.go @@ -203,7 +203,7 @@ func (m *BuildMux) loadSpec(ctx context.Context, client gwclient.Client) (*dalec return nil, err } - // Note: this is not suitable for passing to builds since it does ot have platform information + // Note: this is not suitable for passing to builds since it does not have platform information spec, err := LoadSpec(ctx, dc, nil) if err != nil { return nil, err @@ -220,7 +220,7 @@ func maybeSetDalecTargetKey(client gwclient.Client, key string) gwclient.Client return client } - // optimization to help prevent uneccessary grpc requests + // optimization to help prevent unnecessary grpc requests // The gateway client will make a grpc request to get the build opts from the gateway. // This just caches those opts locally. // If the client is already a clientWithCustomOpts, then the opts are already cached. @@ -239,7 +239,7 @@ func (m *BuildMux) list(ctx context.Context, client gwclient.Client, target stri if target == "" { check = maps.Keys(m.handlers) } else { - // Use the target as a filter so the response only incldues routes that are underneath the target + // Use the target as a filter so the response only includes routes that are underneath the target check = append(check, target) } @@ -309,7 +309,7 @@ func (m *BuildMux) lookupTarget(ctx context.Context, target string) (matchedPatt // cases for `t` are as follows: // 1. may have an exact match in the handlers (ideal) // 2. No matching handler and `target == ""` and there is a default handler set (assume default handler) - // 3. may have a prefix match in the handlers, e.g. hander for `foo`, `target == "foo/bar"` (assume nested route) + // 3. may have a prefix match in the handlers, e.g. handler for `foo`, `target == "foo/bar"` (assume nested route) // 4. No match in the handlers (error) h, ok := m.handlers[target] if ok { diff --git a/frontend/mux_test.go b/frontend/mux_test.go index ad3174c8..5e96b4c0 100644 --- a/frontend/mux_test.go +++ b/frontend/mux_test.go @@ -50,7 +50,7 @@ func TestBuildMux(t *testing.T) { t.Errorf("expected real handler call count to be %d, got %d", expectedRealcount, count) } - // create a subrouter namespaced under the "real" hanlder. + // create a subrouter namespaced under the "real" handler. // This should handle routes for real/subroute/*. var subRouter BuildMux subRouteACount, subrouteAH := newCallback() diff --git a/frontend/windows/handle_container.go b/frontend/windows/handle_container.go index 4e936877..a0505410 100644 --- a/frontend/windows/handle_container.go +++ b/frontend/windows/handle_container.go @@ -25,7 +25,7 @@ var ( defaultPlatform = ocispecs.Platform{ OS: outputKey, // NOTE: Windows is (currently) only supported on amd64. - // Making this use runtime.GOARCH so that builds are more explicitly and not suprising. + // Making this use runtime.GOARCH so that builds are more explicitly and not surprising. // If/when Windows is supported on another platform (ie arm64) this will work as expected. // Until then, if someone really wants to build an amd64 image from arm64 they'll need to set the platform explicitly in the build request. Architecture: runtime.GOARCH, diff --git a/frontend/windows/handle_zip.go b/frontend/windows/handle_zip.go index cc95b05a..fdb2fb9b 100644 --- a/frontend/windows/handle_zip.go +++ b/frontend/windows/handle_zip.go @@ -107,7 +107,7 @@ func withSourcesMounted(dst string, states map[string]llb.State, sources map[str for _, k := range sorted { state := states[k] - // In cases where we have a generated soruce (e.g. gomods) we don't have a [dalec.Source] in the `sources` map. + // In cases where we have a generated source (e.g. gomods) we don't have a [dalec.Source] in the `sources` map. // So we need to check for this. src, ok := sources[k] diff --git a/load_test.go b/load_test.go index 901d69f5..3753e22f 100644 --- a/load_test.go +++ b/load_test.go @@ -252,7 +252,7 @@ func TestSourceValidation(t *testing.T) { }, }, { - title: "cmd souce mount dest must not be /", + title: "cmd source mount dest must not be /", expectErr: true, src: Source{ Path: "/foo", diff --git a/source.go b/source.go index 770f1e73..effc7ac0 100644 --- a/source.go +++ b/source.go @@ -282,7 +282,7 @@ func generateSourceFromImage(st llb.State, cmd *Command, sOpts SourceOpts, subPa } if subPath == "" { - // TODO: We should log a warning here since extracing an entire image while also running a command is + // TODO: We should log a warning here since extracting an entire image while also running a command is // probably not what the user really wanted to do here. // The buildkit client provides functionality to do this we just need to wire it in. subPath = "/" @@ -487,7 +487,7 @@ func (s Source) Doc(name string) (io.Reader, error) { fmt.Fprintln(b, " Remote:", ref.Remote) fmt.Fprintln(b, " Ref:", git.Commit) if s.Path != "" { - fmt.Fprintln(b, " Extraced path:", s.Path) + fmt.Fprintln(b, " Extracted path:", s.Path) } case s.DockerImage != nil: img := s.DockerImage @@ -495,13 +495,13 @@ func (s Source) Doc(name string) (io.Reader, error) { fmt.Fprintln(b, "Generated from a docker image:") fmt.Fprintln(b, " Image:", img.Ref) if s.Path != "" { - fmt.Fprintln(b, " Extraced path:", s.Path) + fmt.Fprintln(b, " Extracted path:", s.Path) } } else { fmt.Fprintln(b, "Generated from running a command(s) in a docker image:") fmt.Fprintln(b, " Image:", img.Ref) if s.Path != "" { - fmt.Fprintln(b, " Extraced path:", s.Path) + fmt.Fprintln(b, " Extracted path:", s.Path) } if len(img.Cmd.Env) > 0 { fmt.Fprintln(b, " With the following environment variables set for all commands:") @@ -580,7 +580,7 @@ func patchSource(worker, sourceState llb.State, sourceToState map[string]llb.Sta } // PatchSources returns a new map containing the patched LLB state for each source in the source map. -// Sources that are not patched are also included in the result for convienence. +// Sources that are not patched are also included in the result for convenience. // `sourceToState` must be a complete map from source name -> llb state for each source in the dalec spec. // `worker` must be an LLB state with a `patch` binary present. func PatchSources(worker llb.State, spec *Spec, sourceToState map[string]llb.State, opts ...llb.ConstraintsOpt) map[string]llb.State { diff --git a/spec.go b/spec.go index 7d8e9f4c..5d4a9ae1 100644 --- a/spec.go +++ b/spec.go @@ -95,7 +95,7 @@ type Spec struct { // Tests are the list of tests to run for the package that should work regardless of target OS // Each item in this list is run with a separate rootfs and cannot interact with other tests. - // Each [TestSpec] is run with a separate rootfs, asyncronously from other [TestSpec]. + // Each [TestSpec] is run with a separate rootfs, asynchronously from other [TestSpec]. Tests []*TestSpec `yaml:"tests,omitempty" json:"tests,omitempty"` } @@ -243,11 +243,11 @@ type SourceInline struct { // File is the inline file to generate. // File is treated as a literal single file. // [SourceIsDir] will return false when this is set. - // This is mutally exclusive with [Dir] + // This is mutually exclusive with [Dir] File *SourceInlineFile `yaml:"file,omitempty" json:"file,omitempty"` // Dir creates a directory with the given files and directories. // [SourceIsDir] will return true when this is set. - // This is mutally exclusive with [File] + // This is mutually exclusive with [File] Dir *SourceInlineDir `yaml:"dir,omitempty" json:"dir,omitempty"` } @@ -299,7 +299,7 @@ type Source struct { // Generators are used to generate additional sources from this source. // As an example the `godmod` generator can be used to generate a go module cache from a go source. // How a genator operates is dependent on the actual generator. - // Geneators may also cauuse modifications to the build environment. + // Generators may also cauuse modifications to the build environment. // // Currently only one generator is supported: "gomod" Generate []*SourceGenerator `yaml:"generate,omitempty" json:"generate,omitempty"` @@ -322,7 +322,7 @@ type SourceGenerator struct { // PackageConstraints is used to specify complex constraints for a package dependency. type PackageConstraints struct { // Version is a list of version constraints for the package. - // The format of these strings is depenendent on the package manager of the target system. + // The format of these strings is dependent on the package manager of the target system. // Examples: // [">=1.0.0", "<2.0.0"] Version []string `yaml:"version,omitempty" json:"version,omitempty"` @@ -489,7 +489,7 @@ type TestStep struct { Stdin string `yaml:"stdin,omitempty" json:"stdin,omitempty"` } -// CheckOutput is used to specify the exepcted output of a check, such as stdout/stderr or a file. +// CheckOutput is used to specify the expected output of a check, such as stdout/stderr or a file. // All non-empty fields will be checked. type CheckOutput struct { // Equals is the exact string to compare the output to. diff --git a/test/azlinux_test.go b/test/azlinux_test.go index f2fb20db..92bef001 100644 --- a/test/azlinux_test.go +++ b/test/azlinux_test.go @@ -117,7 +117,7 @@ type workerConfig struct { // the output [llb.StateOption] should install the repo into the worker image. CreateRepo func(llb.State) llb.StateOption // ContextName is the name of the worker context that the build target will use - // to see if a custom worker is proivded in a context + // to see if a custom worker is provided in a context ContextName string Constraints constraintsSymbols @@ -141,8 +141,8 @@ type targetConfig struct { // Target is the build target for creating the worker image. Worker string - // FormatDepEqual, when set, alters the provided depenedency version to match - // what is neccessary for the target distro to set a dependency for an equals + // FormatDepEqual, when set, alters the provided dependency version to match + // what is necessary for the target distro to set a dependency for an equals // operator. FormatDepEqual func(ver, rev string) string } @@ -482,7 +482,7 @@ echo "$BAR" > bar.txt }, }) - // update the spec in the solve reuqest + // update the spec in the solve request withSpec(ctx, t, &spec)(&newSolveRequestConfig{req: &sr}) if _, err := gwc.Solve(ctx, sr); err == nil { diff --git a/test/fs_test.go b/test/fs_test.go index a777506b..f4254aea 100644 --- a/test/fs_test.go +++ b/test/fs_test.go @@ -261,7 +261,7 @@ func TestStateWrapper_Walk(t *testing.T) { func TestStateWrapper_ReadPartial(t *testing.T) { contents := []byte(` This is a - multline + multiline file `) st := llb.Scratch().File(llb.Mkfile("/foo", 0644, contents)) diff --git a/test/main_test.go b/test/main_test.go index 0ba864ae..fe7298d2 100644 --- a/test/main_test.go +++ b/test/main_test.go @@ -76,15 +76,15 @@ func TestMain(m *testing.M) { go func() { <-ctx.Done() - // The context was cancelled due to interupt + // The context was cancelled due to interrupt // This _should_ trigger builds to cancel naturally and exit the program, // but in some cases it may not (due to timing, bugs in buildkit, uninteruptable operations, etc.). // Cancel our signal handler so the normal handler takes over from here. - // This allows subsequent interupts to use the default behavior (exit the program) + // This allows subsequent interrupts to use the default behavior (exit the program) done() <-time.After(30 * time.Second) - fmt.Fprintln(os.Stderr, "Timeout waiting for builds to cancel after interupt") + fmt.Fprintln(os.Stderr, "Timeout waiting for builds to cancel after interrupt") os.Exit(int(syscall.SIGINT)) }() diff --git a/test/source_test.go b/test/source_test.go index 99745d63..9f3afa43 100644 --- a/test/source_test.go +++ b/test/source_test.go @@ -219,7 +219,7 @@ func TestSourceHTTP(t *testing.T) { }) } -// Create a very simple fake module with a limited depdenency tree just to +// Create a very simple fake module with a limited dependency tree just to // keep the test as fast/reliable as possible. const gomodFixtureMain = `package main diff --git a/test/testenv/buildkit.go b/test/testenv/buildkit.go index 3be0d047..eccb3c1c 100644 --- a/test/testenv/buildkit.go +++ b/test/testenv/buildkit.go @@ -30,7 +30,7 @@ var ( // Buildkit treats the frontend ref (`#syntax=` or via the BUILDKIT_SYNTAX // var) as a docker image ref. // Buildkit will always check the remote registry for a new version of the image. -// As of buildkit v0.12 you can use named contexts to ovewrite the frontend ref +// As of buildkit v0.12 you can use named contexts to overwrite the frontend ref // with another type of ref. // This can be another docker-image, an oci-layout, or even a frontend "input" // (like feeding the output of a build into another build). @@ -67,7 +67,7 @@ func supportsFrontendAsInput(info *client.Info) bool { // withGHCache adds the necessary cache export and import options to the solve request in order to use the GitHub Actions cache. // It uses the test name as a scope for the cache. Each test will have its own scope. -// This means that caches are not shared between tests, but it also means that tests won't ovewrite each other's cache. +// This means that caches are not shared between tests, but it also means that tests won't overwrite each other's cache. // // Github Actions sets some specific environment variables that we'll look for to even determine if we should configure the cache or not. // diff --git a/test/testenv/buildx.go b/test/testenv/buildx.go index 8d038beb..c339a63d 100644 --- a/test/testenv/buildx.go +++ b/test/testenv/buildx.go @@ -42,7 +42,7 @@ func (b *BuildxEnv) WithBuilder(builder string) *BuildxEnv { return b } -// Load loads the output of the speecified [gwclient.BuildFunc] into the buildkit instance. +// Load loads the output of the specified [gwclient.BuildFunc] into the buildkit instance. func (b *BuildxEnv) Load(ctx context.Context, id string, f gwclient.BuildFunc) error { if b.refs == nil { b.refs = make(map[string]gwclient.BuildFunc) @@ -126,7 +126,7 @@ func (b *BuildxEnv) dialStdio(ctx context.Context) error { err := cmd.Wait() c1.Close() // pkgerrors.Wrap will return nil if err is nil, otherwise it will give - // us a wrapped error with the buffered stderr fromt he command. + // us a wrapped error with the buffered stderr from he command. w.CloseWithError(pkgerrors.Wrapf(err, "%s", errBuf)) }() @@ -221,7 +221,7 @@ type FrontendSpec struct { } // withResolveLocal tells buildkit to prefer local images when resolving image references. -// This prevents uneccessary API requests to registries. +// This prevents unnecessary API requests to registries. func withResolveLocal(so *client.SolveOpt) { if so.FrontendAttrs == nil { so.FrontendAttrs = make(map[string]string) diff --git a/website/docs/artifacts.md b/website/docs/artifacts.md index a7869a1b..555f005f 100644 --- a/website/docs/artifacts.md +++ b/website/docs/artifacts.md @@ -91,7 +91,7 @@ artifacts: Directories allows you to create new directories when installing the package. Two types of directory artifacts are supported: -1. *config*: This is a directory where configuration files typically go, e.g. /etc/my_package2. *State*: This is directory for persistant state, typically in `/var/lib` on Linux. +1. *config*: This is a directory where configuration files typically go, e.g. /etc/my_package2. *State*: This is directory for persistent state, typically in `/var/lib` on Linux. Unlike many other artifact types, this does not reference any file produced diff --git a/website/docs/build-source.md b/website/docs/build-source.md index eb2cc0b0..eb56d130 100644 --- a/website/docs/build-source.md +++ b/website/docs/build-source.md @@ -12,7 +12,7 @@ To do this, we'll need a few things: In this example, we'll build the `go-md2man` package and container from [`go-md2man`](https://github.com/cpuguy83/go-md2man) repo using `v2.0.3` tag in the repo. -First, let's start with the contructing a [Dalec spec](spec.md) file. +First, let's start with the constructing a [Dalec spec](spec.md) file. We define the metadata of the package in the spec. This includes the name, packager, vendor, license, website, and description of the package. diff --git a/website/docs/signing.md b/website/docs/signing.md index 704a980e..8e7756d2 100644 --- a/website/docs/signing.md +++ b/website/docs/signing.md @@ -49,7 +49,7 @@ For container targets, only the artifacts within the container get signed. This will send the artifacts (`.rpm`, `.deb`, or `.exe`) to the signing frontend as the build context. -Once a `signer` section has been aded to the spec, signing will be automatic. +Once a `signer` section has been added to the spec, signing will be automatic. In order to disable signing when building specs that have a `signer` section, use the build arg `DALEC_SKIP_SIGNING=1`. @@ -138,7 +138,7 @@ context(s). ### Build Arguments -Buid arguments are key/value pairs that can be supplied in the yaml spec which +Build arguments are key/value pairs that can be supplied in the yaml spec which will be forwarded to the signer. Taking the original example above we can add build by adding an `args` with @@ -158,7 +158,7 @@ targets: # Distro specific build requirements The values of these arguments can also be taken from the client using variable substitution like in other parts of the spec. -To use variable substituion, the args must be declared at the root of the spec: +To use variable substitution, the args must be declared at the root of the spec: ```yaml args: diff --git a/website/docs/sources.md b/website/docs/sources.md index 59101da4..5f8b16fc 100644 --- a/website/docs/sources.md +++ b/website/docs/sources.md @@ -130,7 +130,7 @@ sources: Note the empty brackets. This is an unfortunate syntax requirement to not have `context` considered as a nil value. -This is the equivelent of the following: +This is the equivalent of the following: ```yaml sources: @@ -243,7 +243,7 @@ Here's an example mounting an inline source, modifying it, and extracting the re ```yaml sources: someDockerImage: - path: /bar # Extract `/bar` fromt he result of running the command in the docker image below + path: /bar # Extract `/bar` from he result of running the command in the docker image below image: ref: docker.io/library/alpine:3.14 cmd: @@ -277,7 +277,7 @@ The default dockerfile path is `Dockerfile` just like a normal docker build. sources: someBuild: build: - source: # Specfy another source to use as the build context of this build operation + source: # Specify another source to use as the build context of this build operation git: url: https://github.com/Azure/dalec.git commit: v0.1.0 diff --git a/website/docs/spec.md b/website/docs/spec.md index c3a0094f..dd394eed 100644 --- a/website/docs/spec.md +++ b/website/docs/spec.md @@ -43,7 +43,7 @@ args: TARGETVARIANT: ``` -These arguments are set based on the default docker platform for the machine, *unless* the platform is overriden explicitly in the docker build with `--platform`. For example, upon invoking `docker build` on a Linux amd64 machine, we would have `TARGETOS=linux`, `TARGETARCH=amd64`, `TARGETPLATFORM=linux/amd64`. +These arguments are set based on the default docker platform for the machine, *unless* the platform is overridden explicitly in the docker build with `--platform`. For example, upon invoking `docker build` on a Linux amd64 machine, we would have `TARGETOS=linux`, `TARGETARCH=amd64`, `TARGETPLATFORM=linux/amd64`. :::note No default value should be included for these build args. These args are opt-in. If you haven't listed them in the args section as shown above, Dalec will **not** substitute values for them. diff --git a/website/docs/virtual-packages.md b/website/docs/virtual-packages.md index b72bb283..15bb8e7d 100644 --- a/website/docs/virtual-packages.md +++ b/website/docs/virtual-packages.md @@ -38,7 +38,7 @@ You could also pass the dalec spec file via stdin `docker build -t my-package-im See [docker's documentation](https://docs.docker.com/engine/reference/commandline/build/) for more details on how you can pass the spec file to docker. ::: -This will produce a container image named `my-package-image:1.0.0` that has the `my-package` virtual package installed along with its runtime dependencies. By default, the produced container image is a [`scratch`](https://hub.docker.com/_/scratch/) container image that only contains the package and its dependencies. You can customize the base image to use for the prooduced container. Below is an example that uses the Azure Linux `core` image as the base image which includes a shell and other tools. +This will produce a container image named `my-package-image:1.0.0` that has the `my-package` virtual package installed along with its runtime dependencies. By default, the produced container image is a [`scratch`](https://hub.docker.com/_/scratch/) container image that only contains the package and its dependencies. You can customize the base image to use for the produced container. Below is an example that uses the Azure Linux `core` image as the base image which includes a shell and other tools. ```yaml # syntax=ghcr.io/azure/dalec/frontend:latest