Skaffold dev lists the files to watch then proceeds with deployment.
Skaffold dev actually throws a file name too long error, when listing the configmap file to watch, that includes the strategicPatchMerge config. Reducing the amount in the patch will allow it to work.
commonArtifactSets:
default-artifacts: &default-artifacts
- *AM
- *AMSTER
- *IDM
- *DS-CTS
- *DS-IDREPO
- *FORGEOPS-SECRETS
- *IG
- *LDIF-IMPORTER
build: &default-build
artifacts: *default-artifacts
tagPolicy:
sha256: {}
- name: small
build: *default-build
deploy:
kustomize:
path: ./kustomize/overlay/7.0/small
``` kustomize base
configMapGenerator:
```kustomize overlay patch
patchesStrategicMerge:
- |-
apiVersion: v1
kind: ConfigMap
metadata:
name: platform-config
data:
# Some optional settings
# Set the FQDN - includes the namespace prefix!
# FQDN: prod.pit-test.forgeops.com
# If you are using cert-manager and Let's Encrypt in your cluster and want real certs - set this
# CERT_ISSUER: letsencrypt-prod
AM_STORES_CTS_SERVERS: "ds-cts-0.ds-cts:1389,ds-cts-1.ds-cts:1389,ds-cts-2.ds-cts:1389"
AM_STORES_USER_SERVERS: "ds-idrepo-0.ds-idrepo:1389,ds-idrepo-1.ds-idrepo:1389,ds-idrepo-2.ds-idrepo:1389"
skaffold dev -p smalllog output with -v debug
```INFO[0000] starting gRPC server on port 50051
INFO[0000] starting gRPC HTTP server on port 50052
INFO[0000] Skaffold &{Version:v1.12.0 ConfigVersion:skaffold/v2beta5 GitVersion: GitCommit:e680a831292e1c7efc54e0c6d40544ae141e6354 GitTreeState:clean BuildDate:2020-06-26T02:56:04Z GoVersion:go1.14.4 Compiler:gc Platform:darwin/amd64}
DEBU[0000] config version "skaffold/v1" out of date: upgrading to latest "skaffold/v2beta5"
DEBU[0000] found config for context "gke_engineering-devops_us-east1-c_eng-shared"
INFO[0000] applying profile: small
DEBU[0000] overlaying profile on config for field Build
DEBU[0000] overlaying profile on config for field artifacts
DEBU[0000] overlaying profile on config for field insecureRegistries
DEBU[0000] overlaying profile on config for field tagPolicy
DEBU[0000] overlaying profile on config for field BuildType
INFO[0000] no values found in profile for field BuildType, using original config values
DEBU[0000] overlaying profile on config for field Test
DEBU[0000] overlaying profile on config for field Deploy
DEBU[0000] overlaying profile on config for field DeployType
DEBU[0000] overlaying profile on config for field helm
DEBU[0000] overlaying profile on config for field kubectl
DEBU[0000] overlaying profile on config for field kustomize
DEBU[0000] overlaying profile on config for field statusCheckDeadlineSeconds
DEBU[0000] overlaying profile on config for field kubeContext
DEBU[0000] overlaying profile on config for field PortForward
DEBU[0000] Defaulting build type to local build
DEBU[0000] validating yamltags of struct SkaffoldConfig
DEBU[0000] validating yamltags of struct Metadata
DEBU[0000] validating yamltags of struct Pipeline
DEBU[0000] validating yamltags of struct BuildConfig
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct Artifact
DEBU[0000] validating yamltags of struct ArtifactType
DEBU[0000] validating yamltags of struct DockerArtifact
DEBU[0000] validating yamltags of struct TagPolicy
DEBU[0000] validating yamltags of struct ShaTagger
DEBU[0000] validating yamltags of struct BuildType
DEBU[0000] validating yamltags of struct LocalBuild
DEBU[0000] validating yamltags of struct DeployConfig
DEBU[0000] validating yamltags of struct DeployType
DEBU[0000] validating yamltags of struct KustomizeDeploy
DEBU[0000] validating yamltags of struct KubectlFlags
INFO[0000] Using kubectl context: gke_engineering-devops_us-east1-c_eng-shared
DEBU[0000] Using builder: local
DEBU[0000] setting Docker user agent to skaffold-v1.12.0
DEBU[0000] push value not present, defaulting to true because localCluster is false
Listing files to watch...
skaffold run works fine, so this issue appears to be related to skaffold dev functionality and the way it constructs kustomize file watchers.
Ah, according to the docs, kustomization.yaml's patchesStrategicMerge must be a list of files:
Name | Type | Desc
-- | -- | --
patchesStrategicMerge | []string | Paths to files containing sparse Resource Config.
You can't inline text unfortunately.
Ok thanks, that explains why it thinks its a file name. Thanks for your help
inline texts are supported by Kustomize. Not by Skaffold. I'm going to work on a patch
@dgageot's sleuthing revealed that kustomize added support for inline patches in v3.2.0.
Thanks for the quick turn around!
Yes thanks for sorting this
Welcome!
Most helpful comment
inline texts are supported by Kustomize. Not by Skaffold. I'm going to work on a patch