stdlib: move core definitions to engine package
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
This commit is contained in:
11
stdlib/dagger/engine/fs.cue
Normal file
11
stdlib/dagger/engine/fs.cue
Normal file
@@ -0,0 +1,11 @@
|
||||
package engine
|
||||
|
||||
// A reference to a filesystem tree.
|
||||
// For example:
|
||||
// - The root filesystem of a container
|
||||
// - A source code repository
|
||||
// - A directory containing binary artifacts
|
||||
// Rule of thumb: if it fits in a tar archive, it fits in a #FS.
|
||||
#FS: {
|
||||
_fs: id: string
|
||||
}
|
41
stdlib/dagger/engine/plan.cue
Normal file
41
stdlib/dagger/engine/plan.cue
Normal file
@@ -0,0 +1,41 @@
|
||||
package engine
|
||||
|
||||
// A deployment plan executed by `dagger up`
|
||||
#Plan: {
|
||||
context: #Context
|
||||
actions: [string]: _
|
||||
}
|
||||
|
||||
// FIXME: Platform spec here
|
||||
#Platform: string
|
||||
|
||||
#Context: {
|
||||
// Platform to target
|
||||
platform?: #Platform
|
||||
|
||||
// Import directories
|
||||
imports: [string]: {
|
||||
_type: "Import"
|
||||
|
||||
path: string
|
||||
include?: [...string]
|
||||
exclude?: [...string]
|
||||
fs: #FS
|
||||
}
|
||||
|
||||
// Securely load external secrets
|
||||
secrets: [string]: {
|
||||
// Secrets can be securely mounted into action containers as a file
|
||||
contents: #Secret
|
||||
|
||||
{
|
||||
_type: "SecretFile"
|
||||
// Read secret from a file
|
||||
path: string
|
||||
} | {
|
||||
_type: "SecretEnv"
|
||||
// Read secret from an environment variable ON THE CLIENT MACHINE
|
||||
envvar: string
|
||||
}
|
||||
}
|
||||
}
|
11
stdlib/dagger/engine/secret.cue
Normal file
11
stdlib/dagger/engine/secret.cue
Normal file
@@ -0,0 +1,11 @@
|
||||
package engine
|
||||
|
||||
// A reference to an external secret, for example:
|
||||
// - A password
|
||||
// - A SSH private key
|
||||
// - An API token
|
||||
// Secrets are never merged in the Cue tree. They can only be used
|
||||
// by a special filesystem mount designed to minimize leak risk.
|
||||
#Secret: {
|
||||
_secret: id: string
|
||||
}
|
9
stdlib/dagger/engine/service.cue
Normal file
9
stdlib/dagger/engine/service.cue
Normal file
@@ -0,0 +1,9 @@
|
||||
package engine
|
||||
|
||||
// A reference to a network service endpoint, for example:
|
||||
// - A TCP or UDP port
|
||||
// - A unix or npipe socket
|
||||
// - An HTTPS endpoint
|
||||
#Service: {
|
||||
_service: id: string
|
||||
}
|
Reference in New Issue
Block a user