You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _implementors/features.md
+34
Original file line number
Diff line number
Diff line change
@@ -82,6 +82,40 @@ If a Feature provides a given command with the [object syntax](/implementors/jso
82
82
83
83
> **Note**: These properties are stored within [image metadata](/implementors/spec/#merge-logic).
84
84
85
+
#### Writing scripts to known container path
86
+
87
+
It may be helpful for a Feature to write scripts to a known, persistent path within the container (i.e. for later use in a given lifecycle hook).
88
+
89
+
Take for instance the `git-lfs` Feature, which [writes a script](https://github.com/devcontainers/features/blob/4fca96b5e8a4bfc93679098cb19d73c65ce571eb/src/git-lfs/install.sh#L190-L216) to `/usr/local/share/pull-git-lfs-artifacts.sh` during installation.
This script is then executed during the [`postCreateCommand` lifecycle hook](https://github.com/devcontainers/features/blob/4fca96b5e8a4bfc93679098cb19d73c65ce571eb/src/git-lfs/devcontainer-feature.json#L23).
### <ahref="#options-property"name="options-property"class="anchor"> The `options` property </a>
86
120
87
121
The options property contains a map of option IDs and their related configuration settings. The ID becomes the name of the environment variable in all caps. See [option resolution](#option-resolution) for more details. For example:
0 commit comments