-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Quickstart Docs #440
Merged
jeremyrickard
merged 10 commits into
Azure:main
from
adamperlin:adamperlin/update-quickstart-docs
Nov 27, 2024
Merged
Changes from 7 commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
4d55233
Add initial quickstart content to building from source docs to create…
adamperlin a8a72ea
Add more quickstart docs, add minimal docs for container-only builds
adamperlin 30e49e1
Rename container-only-builds and some wording updates
adamperlin 96817b1
Fix invalid title syntax
adamperlin af091f9
Update sidebars
adamperlin 34997a5
Fix broken link
adamperlin 859d4fe
Update website/docs/quickstart.md
adamperlin 665a78a
Update website/docs/container-only-builds.md
adamperlin 75a6416
Update website/docs/quickstart.md
adamperlin c3088f6
Address review feedback
adamperlin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Container-only builds | ||
--- | ||
|
||
# Container-only builds | ||
adamperlin marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
It is possible to use Dalec when you wish to build a minimal image from scratch or based on one of Dalec's supported distros (see [Targets](targets.md) for a list of these) with only certain packages installed. To do this, simply define a Dalec spec with only runtime dependencies specified. The resulting image will contain only the specified packages and their dependencies. | ||
|
||
```yaml | ||
name: my-minimal-image | ||
version: 0.1.0 | ||
description: A minimal distroless image with only curl and shell access | ||
revision: 1 | ||
|
||
dependencies: | ||
runtime: | ||
curl: | ||
bash: | ||
|
||
image: | ||
entrypoint: /bin/bash | ||
|
||
``` | ||
|
||
Then, to build: | ||
`docker build -f my-minimal-image.yml --target=mariner2 -t my-minimal-image:0.1.0 .` | ||
adamperlin marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
This will produce a minimal image from `scratch` with only curl and bash installed. | ||
adamperlin marked this conversation as resolved.
Show resolved
Hide resolved
|
||
How does this work? Dalec will create a [Virtual Package](virtual-packages.md) which has only the specified runtime dependencies and install this in the target base image. This is where the `--target=mariner2` flag comes in. Even though the resulting image is from scratch, it will have the specified packages installed from mariner2 repos. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is a bit long for the sidebar, maybe just "Overview"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adamperlin did you push your changes, i am still seeing the same?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are now pushed!