docs/static/reference/php/Dagger/ModuleSource.html
class ModuleSource extends AbstractObject implements IdAble
The source needed to load and run a module, along with any metadata about the source such as versions/urls/etc.
| | $lastQuery | | from AbstractObject |
__construct(AbstractClient $client, QueryBuilderChain $queryBuilderChain)
No description
from AbstractObject
null|array|string|int|float|bool
queryLeaf(QueryBuilder $leafQueryBuilder, string $leafKey)
No description
from AbstractObject
asModule()
Load the source as a module. If this is a local source, the parent directory must have been provided during module source creation
string
asString()
A human readable ref string representation of this module source.
The blueprint referenced by the module source.
string
cloneRef()
The ref to clone the root of the git repo from. Only valid for git sources.
string
commit()
The resolved commit of the git repo this source points to.
array
The clients generated for the module.
bool
Whether an existing dagger.json for the module was found.
The full directory loaded for the module source, including the source code as a subdirectory.
array
The dependencies of the module source.
string
digest()
A content-hash of the module source. Module sources with the same digest will output the same generated context and convert into the same module instance.
directory(string $path)
The directory containing the module configuration and source code (source code may be in a subdir).
string
The engine version of the module.
The generated files and directories made on top of the module source's context directory, returned as a Changeset.
The generated files and directories made on top of the module source's context directory.
string
The URL to access the web view of the repository (e.g., GitHub, GitLab, Bitbucket).
string
htmlURL()
The URL to the source's git repo in a web browser. Only valid for git sources.
id()
A unique identifier for this ModuleSource.
The introspection schema JSON file for this module source.
ModuleSourceKind
kind()
The kind of module source (currently local, git or dir).
string
The full absolute path to the context directory on the caller's host filesystem that this module source is loaded from. Only valid for local module sources.
string
The name of the module, including any setting via the withName API.
string
The original name of the module as read from the module's dagger.json (or set for the first time with the withName API).
string
The original subpath used when instantiating this module source, relative to the context directory.
string
pin()
The pinned version of this module source.
string
The import path corresponding to the root of the git repo this source points to. Only valid for git sources.
sdk()
The SDK configuration of the module.
string
The path, relative to the context directory, that contains the module's dagger.json.
string
The path to the directory containing the module's source code, relative to the context directory.
sync()
Forces evaluation of the module source, including any loading into the engine and associated validation.
array
The toolchains referenced by the module source.
User-defined defaults read from local .env files
string
version()
The specified version of the git repo this source points to.
withBlueprint(ModuleSource $blueprint)
Set a blueprint for the module source.
withClient(string $generator, string $outputDir)
Update the module source with a new client to generate.
withDependencies(array $dependencies)
Append the provided dependencies to the module source's dependency list.
withEngineVersion(string $version)
Upgrade the engine version of the module to the given value.
withExperimentalFeatures(array $features)
Enable the experimental features for the module source.
withIncludes(array $patterns)
Update the module source with additional include patterns for files+directories from its context that are required for building it
withName(string $name)
Update the module source with a new name.
withSDK(string $source)
Update the module source with a new SDK.
withSourceSubpath(string $path)
Update the module source with a new source subpath.
withToolchains(array $toolchains)
Add toolchains to the module source.
Update the blueprint module to the latest version.
withUpdateDependencies(array $dependencies)
Update one or more module dependencies.
withUpdateToolchains(array $toolchains)
Update one or more toolchains.
withUpdatedClients(array $clients)
Update one or more clients.
Remove the current blueprint from the module source.
withoutClient(string $path)
Remove a client from the module source.
withoutDependencies(array $dependencies)
Remove the provided dependencies from the module source's dependency list.
withoutExperimentalFeatures(array $features)
Disable experimental features for the module source.
withoutToolchains(array $toolchains)
Remove the provided toolchains from the module source.
__construct(AbstractClient $client, QueryBuilderChain $queryBuilderChain) No description
| AbstractClient | $client | | | QueryBuilderChain | $queryBuilderChain | |
protected null|array|string|int|float|bool queryLeaf(QueryBuilder $leafQueryBuilder, string $leafKey)No description
| QueryBuilder | $leafQueryBuilder | | | string | $leafKey | |
| null|array|string|int|float|bool | |
Module asModule()Load the source as a module. If this is a local source, the parent directory must have been provided during module source creation
| Module | |
string asString()A human readable ref string representation of this module source.
| string | |
ModuleSource blueprint()The blueprint referenced by the module source.
| ModuleSource | |
string cloneRef()The ref to clone the root of the git repo from. Only valid for git sources.
| string | |
string commit()The resolved commit of the git repo this source points to.
| string | |
array configClients()The clients generated for the module.
| array | |
bool configExists()Whether an existing dagger.json for the module was found.
| bool | |
Directory contextDirectory()The full directory loaded for the module source, including the source code as a subdirectory.
| Directory | |
array dependencies()The dependencies of the module source.
| array | |
string digest()A content-hash of the module source. Module sources with the same digest will output the same generated context and convert into the same module instance.
| string | |
Directory directory(string $path)The directory containing the module configuration and source code (source code may be in a subdir).
| string | $path | |
| Directory | |
string engineVersion()The engine version of the module.
| string | |
Changeset generatedContextChangeset()The generated files and directories made on top of the module source's context directory, returned as a Changeset.
| Changeset | |
Directory generatedContextDirectory()The generated files and directories made on top of the module source's context directory.
| Directory | |
string htmlRepoURL()The URL to access the web view of the repository (e.g., GitHub, GitLab, Bitbucket).
| string | |
string htmlURL()The URL to the source's git repo in a web browser. Only valid for git sources.
| string | |
AbstractId id()A unique identifier for this ModuleSource.
| AbstractId | |
File introspectionSchemaJSON()The introspection schema JSON file for this module source.
This file represents the schema visible to the module's source code, including all core types and those from the dependencies.
Note: this is in the context of a module, so some core types may be hidden.
| File | |
ModuleSourceKind kind()The kind of module source (currently local, git or dir).
| ModuleSourceKind | |
string localContextDirectoryPath()The full absolute path to the context directory on the caller's host filesystem that this module source is loaded from. Only valid for local module sources.
| string | |
string moduleName()The name of the module, including any setting via the withName API.
| string | |
string moduleOriginalName()The original name of the module as read from the module's dagger.json (or set for the first time with the withName API).
| string | |
string originalSubpath()The original subpath used when instantiating this module source, relative to the context directory.
| string | |
string pin()The pinned version of this module source.
| string | |
string repoRootPath()The import path corresponding to the root of the git repo this source points to. Only valid for git sources.
| string | |
SDKConfig sdk()The SDK configuration of the module.
| SDKConfig | |
string sourceRootSubpath()The path, relative to the context directory, that contains the module's dagger.json.
| string | |
string sourceSubpath()The path to the directory containing the module's source code, relative to the context directory.
| string | |
ModuleSourceId sync()Forces evaluation of the module source, including any loading into the engine and associated validation.
| ModuleSourceId | |
array toolchains()The toolchains referenced by the module source.
| array | |
EnvFile userDefaults()User-defined defaults read from local .env files
| EnvFile | |
string version()The specified version of the git repo this source points to.
| string | |
ModuleSource withBlueprint(ModuleSource $blueprint)Set a blueprint for the module source.
| ModuleSource | $blueprint | |
| ModuleSource | |
ModuleSource withClient(string $generator, string $outputDir)Update the module source with a new client to generate.
| string | $generator | | | string | $outputDir | |
| ModuleSource | |
ModuleSource withDependencies(array $dependencies)Append the provided dependencies to the module source's dependency list.
| array | $dependencies | |
| ModuleSource | |
ModuleSource withEngineVersion(string $version)Upgrade the engine version of the module to the given value.
| string | $version | |
| ModuleSource | |
ModuleSource withExperimentalFeatures(array $features)Enable the experimental features for the module source.
| array | $features | |
| ModuleSource | |
ModuleSource withIncludes(array $patterns)Update the module source with additional include patterns for files+directories from its context that are required for building it
| array | $patterns | |
| ModuleSource | |
ModuleSource withName(string $name)Update the module source with a new name.
| string | $name | |
| ModuleSource | |
ModuleSource withSDK(string $source)Update the module source with a new SDK.
| string | $source | |
| ModuleSource | |
ModuleSource withSourceSubpath(string $path)Update the module source with a new source subpath.
| string | $path | |
| ModuleSource | |
ModuleSource withToolchains(array $toolchains)Add toolchains to the module source.
| array | $toolchains | |
| ModuleSource | |
ModuleSource withUpdateBlueprint()Update the blueprint module to the latest version.
| ModuleSource | |
ModuleSource withUpdateDependencies(array $dependencies)Update one or more module dependencies.
| array | $dependencies | |
| ModuleSource | |
ModuleSource withUpdateToolchains(array $toolchains)Update one or more toolchains.
| array | $toolchains | |
| ModuleSource | |
ModuleSource withUpdatedClients(array $clients)Update one or more clients.
| array | $clients | |
| ModuleSource | |
ModuleSource withoutBlueprint()Remove the current blueprint from the module source.
| ModuleSource | |
ModuleSource withoutClient(string $path)Remove a client from the module source.
| string | $path | |
| ModuleSource | |
ModuleSource withoutDependencies(array $dependencies)Remove the provided dependencies from the module source's dependency list.
| array | $dependencies | |
| ModuleSource | |
ModuleSource withoutExperimentalFeatures(array $features)Disable experimental features for the module source.
| array | $features | |
| ModuleSource | |
ModuleSource withoutToolchains(array $toolchains)Remove the provided toolchains from the module source.
| array | $toolchains | |
| ModuleSource | |
Generated by Doctum, a API Documentation generator and fork of Sami.