cue fmt
Signed-off-by: Sam Alba <sam.alba@gmail.com>
This commit is contained in:
parent
7009d01835
commit
a4167dc3f4
@ -20,7 +20,9 @@ import (
|
|||||||
stackName: string @dagger(input)
|
stackName: string @dagger(input)
|
||||||
|
|
||||||
// Stack parameters
|
// Stack parameters
|
||||||
parameters: [string]: _ @dagger(input)
|
parameters: {
|
||||||
|
...
|
||||||
|
}
|
||||||
|
|
||||||
// Behavior when failure to create/update the Stack
|
// Behavior when failure to create/update the Stack
|
||||||
onFailure: *"DO_NOTHING" | "ROLLBACK" | "DELETE" @dagger(input)
|
onFailure: *"DO_NOTHING" | "ROLLBACK" | "DELETE" @dagger(input)
|
||||||
@ -44,7 +46,9 @@ import (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
outputs: [string]: string @dagger(output)
|
outputs: {
|
||||||
|
[string]: string @dagger(output)
|
||||||
|
}
|
||||||
|
|
||||||
outputs: #up: [
|
outputs: #up: [
|
||||||
op.#Load & {
|
op.#Load & {
|
||||||
|
@ -17,7 +17,9 @@ import (
|
|||||||
taskArn: string @dagger(input)
|
taskArn: string @dagger(input)
|
||||||
|
|
||||||
// Environment variables of the task
|
// Environment variables of the task
|
||||||
containerEnvironment: [string]: string @dagger(input)
|
containerEnvironment: {
|
||||||
|
[string]: string @dagger(input)
|
||||||
|
}
|
||||||
|
|
||||||
// Container name
|
// Container name
|
||||||
containerName: string @dagger(input)
|
containerName: string @dagger(input)
|
||||||
|
@ -19,7 +19,7 @@ import (
|
|||||||
// kubeconfig is the generated kube configuration file
|
// kubeconfig is the generated kube configuration file
|
||||||
kubeconfig: {
|
kubeconfig: {
|
||||||
// FIXME There is a problem with dagger.#Secret type
|
// FIXME There is a problem with dagger.#Secret type
|
||||||
string @dagger(output)
|
string
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
op.#Load & {
|
op.#Load & {
|
||||||
@ -62,5 +62,5 @@ import (
|
|||||||
format: "string"
|
format: "string"
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}
|
} @dagger(output)
|
||||||
}
|
}
|
||||||
|
@ -46,7 +46,7 @@ import (
|
|||||||
// Build a Docker image from the provided Dockerfile contents
|
// Build a Docker image from the provided Dockerfile contents
|
||||||
// FIXME: incorporate into #Build
|
// FIXME: incorporate into #Build
|
||||||
#ImageFromDockerfile: {
|
#ImageFromDockerfile: {
|
||||||
dockerfile: string @dagger(input)
|
dockerfile: string @dagger(input)
|
||||||
context: dagger.#Artifact @dagger(input)
|
context: dagger.#Artifact @dagger(input)
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
|
@ -7,8 +7,8 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
#Create: {
|
#Create: {
|
||||||
filename: !="" @dagger(input)
|
filename: !="" @dagger(input)
|
||||||
permissions: int | *0o644 @dagger(input)
|
permissions: int | *0o644 @dagger(input)
|
||||||
contents: string | bytes @dagger(input)
|
contents: string | bytes @dagger(input)
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
@ -17,9 +17,9 @@ import (
|
|||||||
}
|
}
|
||||||
|
|
||||||
#Append: {
|
#Append: {
|
||||||
filename: !="" @dagger(input)
|
filename: !="" @dagger(input)
|
||||||
permissions: int | *0o644 @dagger(input)
|
permissions: int | *0o644 @dagger(input)
|
||||||
contents: string | bytes @dagger(input)
|
contents: string | bytes @dagger(input)
|
||||||
from: dagger.#Artifact @dagger(input)
|
from: dagger.#Artifact @dagger(input)
|
||||||
|
|
||||||
orig: (#read & {path: filename, "from": from}).data @dagger(output)
|
orig: (#read & {path: filename, "from": from}).data @dagger(output)
|
||||||
@ -30,27 +30,27 @@ import (
|
|||||||
}
|
}
|
||||||
|
|
||||||
#Read: {
|
#Read: {
|
||||||
filename: !="" @dagger(input)
|
filename: !="" @dagger(input)
|
||||||
from: dagger.#Artifact @dagger(input)
|
from: dagger.#Artifact @dagger(input)
|
||||||
contents: (#read & {path: filename, "from": from}).data @dagger(output)
|
contents: (#read & {path: filename, "from": from}).data @dagger(output)
|
||||||
}
|
}
|
||||||
|
|
||||||
#read: {
|
#read: {
|
||||||
path: !="" @dagger(input)
|
path: !="" @dagger(input)
|
||||||
from: dagger.#Artifact @dagger(input)
|
from: dagger.#Artifact @dagger(input)
|
||||||
data: {
|
data: {
|
||||||
string @dagger(output)
|
string
|
||||||
#up: [
|
#up: [
|
||||||
op.#Load & {"from": from},
|
op.#Load & {"from": from},
|
||||||
op.#Export & {source: path},
|
op.#Export & {source: path},
|
||||||
]
|
]
|
||||||
}
|
} @dagger(output)
|
||||||
}
|
}
|
||||||
|
|
||||||
#Glob: {
|
#Glob: {
|
||||||
glob: !="" @dagger(input)
|
glob: !="" @dagger(input)
|
||||||
filenames: [...string] @dagger(input)
|
filenames: [...string] @dagger(input)
|
||||||
from: dagger.#Artifact @dagger(input)
|
from: dagger.#Artifact @dagger(input)
|
||||||
files: (_#glob & {"glob": glob, "from": from}).data @dagger(output)
|
files: (_#glob & {"glob": glob, "from": from}).data @dagger(output)
|
||||||
// trim suffix because ls always ends with newline
|
// trim suffix because ls always ends with newline
|
||||||
filenames: strings.Split(strings.TrimSuffix(files, "\n"), "\n") @dagger(output)
|
filenames: strings.Split(strings.TrimSuffix(files, "\n"), "\n") @dagger(output)
|
||||||
|
@ -13,7 +13,7 @@ import (
|
|||||||
// GCR credentials
|
// GCR credentials
|
||||||
username: "oauth2accesstoken"
|
username: "oauth2accesstoken"
|
||||||
secret: {
|
secret: {
|
||||||
string @dagger(output)
|
string
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
op.#Load & {
|
op.#Load & {
|
||||||
@ -40,5 +40,5 @@ import (
|
|||||||
source: "/token.txt"
|
source: "/token.txt"
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}
|
} @dagger(output)
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,7 @@ import (
|
|||||||
// kubeconfig is the generated kube configuration file
|
// kubeconfig is the generated kube configuration file
|
||||||
kubeconfig: {
|
kubeconfig: {
|
||||||
// FIXME There is a problem with dagger.#Secret type
|
// FIXME There is a problem with dagger.#Secret type
|
||||||
string @dagger(output)
|
string
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
op.#Load & {
|
op.#Load & {
|
||||||
@ -54,7 +54,7 @@ import (
|
|||||||
format: "string"
|
format: "string"
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}
|
} @dagger(output)
|
||||||
}
|
}
|
||||||
|
|
||||||
#Code: #"""
|
#Code: #"""
|
||||||
|
@ -7,8 +7,8 @@ import (
|
|||||||
// A git repository
|
// A git repository
|
||||||
#Repository: {
|
#Repository: {
|
||||||
|
|
||||||
remote: string @dagger(input)
|
remote: string @dagger(input)
|
||||||
ref: string @dagger(input)
|
ref: string @dagger(input)
|
||||||
subdir: string | *"" @dagger(input)
|
subdir: string | *"" @dagger(input)
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
|
@ -47,7 +47,9 @@ import (
|
|||||||
source: dagger.#Artifact @dagger(input)
|
source: dagger.#Artifact @dagger(input)
|
||||||
|
|
||||||
// Environment variables
|
// Environment variables
|
||||||
env: [string]: string @dagger(input)
|
env: {
|
||||||
|
[string]: string @dagger(input)
|
||||||
|
}
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
op.#FetchContainer & {
|
op.#FetchContainer & {
|
||||||
@ -93,7 +95,9 @@ import (
|
|||||||
// Specify the targeted binary name
|
// Specify the targeted binary name
|
||||||
output: string @dagger(output)
|
output: string @dagger(output)
|
||||||
|
|
||||||
env: [string]: string @dagger(input)
|
env: {
|
||||||
|
[string]: string @dagger(input)
|
||||||
|
}
|
||||||
|
|
||||||
#up: [
|
#up: [
|
||||||
op.#Copy & {
|
op.#Copy & {
|
||||||
|
@ -16,7 +16,9 @@ import (
|
|||||||
source: dagger.#Artifact @dagger(input)
|
source: dagger.#Artifact @dagger(input)
|
||||||
|
|
||||||
// Environment variables
|
// Environment variables
|
||||||
env: [string]: string @dagger(input)
|
env: {
|
||||||
|
[string]: string @dagger(input)
|
||||||
|
}
|
||||||
|
|
||||||
// Write the contents of `environment` to this file,
|
// Write the contents of `environment` to this file,
|
||||||
// in the "envfile" format.
|
// in the "envfile" format.
|
||||||
|
@ -36,25 +36,25 @@ import (
|
|||||||
// Website url
|
// Website url
|
||||||
url: {
|
url: {
|
||||||
os.#File & {
|
os.#File & {
|
||||||
from: ctr
|
from: ctr
|
||||||
path: "/netlify/url"
|
path: "/netlify/url"
|
||||||
}
|
}
|
||||||
}.read.data @dagger(output)
|
}.read.data @dagger(output)
|
||||||
|
|
||||||
// Unique Deploy URL
|
// Unique Deploy URL
|
||||||
deployUrl: {
|
deployUrl: {
|
||||||
os.#File & {
|
os.#File & {
|
||||||
from: ctr
|
from: ctr
|
||||||
path: "/netlify/deployUrl"
|
path: "/netlify/deployUrl"
|
||||||
}
|
}
|
||||||
}.read.data @dagger(output)
|
}.read.data @dagger(output)
|
||||||
|
|
||||||
// Logs URL for this deployment
|
// Logs URL for this deployment
|
||||||
logsUrl: {
|
logsUrl: {
|
||||||
os.#File & {
|
os.#File & {
|
||||||
from: ctr
|
from: ctr
|
||||||
path: "/netlify/logsUrl"
|
path: "/netlify/logsUrl"
|
||||||
}
|
}
|
||||||
}.read.data @dagger(output)
|
}.read.data @dagger(output)
|
||||||
|
|
||||||
ctr: os.#Container & {
|
ctr: os.#Container & {
|
||||||
|
@ -12,9 +12,13 @@ import (
|
|||||||
|
|
||||||
source: dagger.#Artifact @dagger(input)
|
source: dagger.#Artifact @dagger(input)
|
||||||
|
|
||||||
tfvars?: [string]: _ @dagger(input)
|
tfvars?: {
|
||||||
|
...
|
||||||
|
}
|
||||||
|
|
||||||
env: [string]: string @dagger(input)
|
env: {
|
||||||
|
[string]: string @dagger(input)
|
||||||
|
}
|
||||||
|
|
||||||
state: #up: [
|
state: #up: [
|
||||||
op.#FetchContainer & {
|
op.#FetchContainer & {
|
||||||
|
Reference in New Issue
Block a user