portainer/portainer · error
Invalid stack file content
Error message
Invalid stack file content
What it means
Error "Invalid stack file content" thrown in portainer/portainer.
Source
Thrown at api/http/handler/stacks/create_kubernetes_stack.go:104
type kubernetesManifestURLDeploymentPayload struct {
StackName string
Namespace string
ComposeFormat bool
ManifestURL string
}
func createStackPayloadFromK8sUrlPayload(name, namespace, manifestUrl string, composeFormat bool) stackbuilders.StackPayload {
return stackbuilders.StackPayload{
StackName: name,
Namespace: namespace,
ManifestURL: manifestUrl,
}
}
func (payload *kubernetesStringDeploymentPayload) Validate(r *http.Request) error {
if len(payload.StackFileContent) == 0 {
return errors.New("Invalid stack file content")
}
return nil
}
func (payload *kubernetesGitDeploymentPayload) Validate(r *http.Request) error {
if payload.SourceID == 0 {
if len(payload.RepositoryURL) == 0 || !validate.IsURL(payload.RepositoryURL) {
return errors.New("Invalid repository URL. Must correspond to a valid URL format")
}
if payload.RepositoryAuthentication && len(payload.RepositoryPassword) == 0 {
return errors.New("Invalid repository credentials. Password must be specified when authentication is enabled")
}
}
if len(payload.ManifestFile) == 0 {
return errors.New("Invalid manifest file in repository")
}View on GitHub (pinned to 17e74456ff)
When it happens
Trigger: Thrown at api/http/handler/stacks/create_kubernetes_stack.go:104 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of portainer/portainer@17e74456ff (2026-08-26).
Data as JSON: /api/errors/9b099cd10dbf5d0a.
Report an issue: GitHub.