Remove random generation tag because it's not needed anymore.
Signed-off-by: Tom Chauveau <tom.chauveau@epitech.eu>
This commit is contained in:
parent
70b2a9e58a
commit
9109052638
@ -452,7 +452,6 @@ Let's see how to deploy an image locally and push it to the local cluster
|
||||
|
||||
`kube/todoapp.cue` faces these changes:
|
||||
|
||||
- `suffix`, a random string for a unique tag name
|
||||
- `repository`, source code of the app to build. It needs to have a Dockerfile
|
||||
- `registry`, URI of the registry to push to
|
||||
- `image`, build of the image
|
||||
@ -466,24 +465,18 @@ import (
|
||||
"encoding/yaml"
|
||||
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
"alpha.dagger.io/kubernetes/kustomize"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// Registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-kind-\(suffix.out)"
|
||||
tag: "test-kind"
|
||||
|
||||
// input: kubernetes objects directory to deploy to
|
||||
// set with `dagger input dir manifest ./k8s -e kube`
|
||||
@ -568,7 +561,6 @@ gcrCreds: gcr.#Credentials & {
|
||||
|
||||
`kube/todoapp.cue`, on the other hand, faces these changes:
|
||||
|
||||
- `suffix`, a random string for a unique tag name
|
||||
- `repository`, source code of the app to build. It needs to have a Dockerfile
|
||||
- `registry`, URI of the registry to push to
|
||||
- `image`, build of the image
|
||||
@ -582,24 +574,18 @@ import (
|
||||
"encoding/yaml"
|
||||
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
"alpha.dagger.io/kubernetes/kustomize"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// GCR registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-gcr-\(suffix.out)"
|
||||
tag: "test-gcr"
|
||||
|
||||
// source of Kube config file.
|
||||
// set with `dagger input dir manifest ./k8s -e kube`
|
||||
@ -687,7 +673,6 @@ ecrCreds: ecr.#Credentials & {
|
||||
|
||||
`kube/todoapp.cue`, on the other hand, faces these changes:
|
||||
|
||||
- `suffix`, a random string for a unique tag name
|
||||
- `repository`, source code of the app to build. It needs to have a Dockerfile
|
||||
- `registry`, URI of the registry to push to
|
||||
- `image`, build of the image
|
||||
@ -701,24 +686,18 @@ import (
|
||||
"encoding/yaml"
|
||||
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
"alpha.dagger.io/kubernetes/kustomize"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// ECR registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-ecr-\(suffix.out)"
|
||||
tag: "test-ecr"
|
||||
|
||||
// source of Kube config file.
|
||||
// set with `dagger input dir manifest ./k8s -e kube`
|
||||
@ -819,15 +798,13 @@ dagger input dir repository . -e kube
|
||||
|
||||
```shell
|
||||
dagger up -e kube
|
||||
# 4:09AM INF suffix.out | computing
|
||||
# 4:09AM INF manifest | computing
|
||||
# 4:09AM INF repository | computing
|
||||
# ...
|
||||
# 4:09AM INF todoApp.kubeSrc | #37 0.858 service/todoapp-service created
|
||||
# 4:09AM INF todoApp.kubeSrc | #37 0.879 deployment.apps/todoapp created
|
||||
# Output Value Description
|
||||
# suffix.out "azkestizysbx" generated random string
|
||||
# todoApp.remoteImage.ref "localhost:5000/kind:test-kind-azkestizysbx@sha256:cb8d92518b876a3fe15a23f7c071290dfbad50283ad976f3f5b93e9f20cefee6" Image ref
|
||||
# todoApp.remoteImage.ref "localhost:5000/kind:test-kind@sha256:cb8d92518b876a3fe15a23f7c071290dfbad50283ad976f3f5b93e9f20cefee6" Image ref
|
||||
# todoApp.remoteImage.digest "sha256:cb8d92518b876a3fe15a23f7c071290dfbad50283ad976f3f5b93e9f20cefee6" Image digest
|
||||
```
|
||||
|
||||
@ -1011,23 +988,17 @@ package main
|
||||
|
||||
import (
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// Registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-kind-\(suffix.out)"
|
||||
tag: "test-kind"
|
||||
|
||||
// Todoapp deployment pipeline
|
||||
todoApp: {
|
||||
@ -1064,23 +1035,17 @@ package main
|
||||
|
||||
import (
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// GCR registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-gcr-\(suffix.out)"
|
||||
tag: "test-gcr"
|
||||
|
||||
// Todoapp deployment pipeline
|
||||
todoApp: {
|
||||
@ -1117,23 +1082,17 @@ package main
|
||||
|
||||
import (
|
||||
"alpha.dagger.io/dagger"
|
||||
"alpha.dagger.io/random"
|
||||
"alpha.dagger.io/docker"
|
||||
"alpha.dagger.io/kubernetes"
|
||||
)
|
||||
|
||||
// Randrom string for tag
|
||||
suffix: random.#String & {
|
||||
seed: ""
|
||||
}
|
||||
|
||||
// input: source code repository, must contain a Dockerfile
|
||||
// set with `dagger input dir repository . -e kube`
|
||||
repository: dagger.#Artifact & dagger.#Input
|
||||
|
||||
// ECR registry to push images to
|
||||
registry: string & dagger.#Input
|
||||
tag: "test-ecr-\(suffix.out)"
|
||||
tag: "test-ecr"
|
||||
|
||||
// Todoapp deployment pipeline
|
||||
todoApp: {
|
||||
@ -1178,15 +1137,13 @@ dagger input unset manifest -e kube
|
||||
|
||||
```shell
|
||||
dagger up -e kube
|
||||
# 4:09AM INF suffix.out | computing
|
||||
# 4:09AM INF manifest | computing
|
||||
# 4:09AM INF repository | computing
|
||||
# ...
|
||||
# 4:09AM INF todoApp.kubeSrc | #37 0.858 service/todoapp-service created
|
||||
# 4:09AM INF todoApp.kubeSrc | #37 0.879 deployment.apps/todoapp created
|
||||
# Output Value Description
|
||||
# suffix.out "abdkektizesxb" generated random string
|
||||
# todoApp.remoteImage.ref "localhost:5000/kind:test-kind-abdkektizesxb@sha256:cb8d91518b076a3fe15a33f7c171290dfbad50283ad976f3f5b93e9f33cefag7" Image ref
|
||||
# todoApp.remoteImage.ref "localhost:5000/kind:test-kind@sha256:cb8d91518b076a3fe15a33f7c171290dfbad50283ad976f3f5b93e9f33cefag7" Image ref
|
||||
# todoApp.remoteImage.digest "sha256:cb8d91518b076a3fe15a33f7c171290dfbad50283ad976f3f5b93e9f33cefag7" Image digest
|
||||
```
|
||||
|
||||
|
Reference in New Issue
Block a user