Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deployer failing for some marketplace apps #1623

Open
1 of 3 tasks
pipoe2h opened this issue Feb 2, 2022 · 1 comment
Open
1 of 3 tasks

Deployer failing for some marketplace apps #1623

pipoe2h opened this issue Feb 2, 2022 · 1 comment
Labels
kind/k8s Related to the Kubernetes application needs-triage This wasn't investigate by the repo's owners yet

Comments

@pipoe2h
Copy link

pipoe2h commented Feb 2, 2022

Category:

Kubernetes apps

Type:

  • Bug
  • Feature Request
  • Process

Marketplace applications such as Consul and Postgres get successfully deployed, but the deployer containers are terminating in a failed stage

Anthos bare metal: 1.9.4

  • Consul deployer log
+ validate_app_resource.py --manifests /data/resources.yaml
INFO Reading /data/resources.yaml
+ /bin/setassemblyphase.py --manifest /data/resources.yaml --status Pending
INFO Reading /data/resources.yaml
+ kubectl apply --namespace=consul --filename=/data/resources.yaml
Using /opt/kubectl/default/kubectl (server=1.21)
poddisruptionbudget.policy/consul-1-consul-server created
secret/consul-1-consul-gossip-key created
configmap/consul-1-consul-client-config created
configmap/consul-1-consul-server-config created
service/consul-1-consul-dns created
service/consul-1-consul-server created
service/consul-1-consul-ui created
daemonset.apps/consul-1-consul created
statefulset.apps/consul-1-consul-server created
error: error validating "/data/resources.yaml": error validating data: ValidationError(Application): unknown field "spec" in io.k8s.app.v1beta1.Application; if you choose to ignore these errors, turn validation off with --validate=false
+ handle_failure
+ code=1
+ [[ -z consul-1 ]]
+ [[ -z consul ]]
+ patch_assembly_phase.sh --status=Failed
+ for i in '"$@"'
+ case $i in
+ status=Failed
+ shift
+ [[ -z Failed ]]
+ [[ Failed =~ ^(Pending|Success|Failed)$ ]]
Marking deployment of application "consul-1" as "Failed".
+ [[ -z consul-1 ]]
+ [[ -z consul ]]
+ echo 'Marking deployment of application "consul-1" as "Failed".'
+ [[ Failed == \S\u\c\c\e\s\s ]]
+ kubectl patch applications.app.k8s.io/consul-1 --output=json --namespace=consul --type=merge --patch '{"spec": {"assemblyPhase": "Failed"}}'
Using /opt/kubectl/default/kubectl (server=1.21)
  • Consul pod status
$ kubectl get po -n consul
NAME                       READY   STATUS    RESTARTS   AGE
consul-1-consul-6zh9g      1/1     Running   0          7m12s
consul-1-consul-mphlf      1/1     Running   0          7m12s
consul-1-consul-server-0   1/1     Running   0          7m11s
consul-1-consul-server-1   1/1     Running   0          7m11s
consul-1-consul-server-2   1/1     Running   0          7m11s
consul-1-deployer-bk4k6    0/1     Error     0          7m19s
  • Postgres deployer log
+ validate_app_resource.py --manifests /data/resources.yaml
INFO Reading /data/resources.yaml
+ /bin/setassemblyphase.py --manifest /data/resources.yaml --status Pending
INFO Reading /data/resources.yaml
+ kubectl apply --namespace=postgres --filename=/data/resources.yaml
Using /opt/kubectl/default/kubectl (server=1.21)
secret/postgresql-1-secret created
secret/postgresql-1-tls created
configmap/postgresql-1-postgresql-config created
service/postgresql-1-postgresql-svc created
service/postgresql-1-postgres-exporter-svc created
statefulset.apps/postgresql-1-postgresql created
error: error validating "/data/resources.yaml": error validating data: ValidationError(Application): unknown field "spec" in io.k8s.app.v1beta1.Application; if you choose to ignore these errors, turn validation off with --validate=false
+ handle_failure
+ code=1
+ [[ -z postgresql-1 ]]
+ [[ -z postgres ]]
+ patch_assembly_phase.sh --status=Failed
+ for i in '"$@"'
+ case $i in
+ status=Failed
+ shift
+ [[ -z Failed ]]
+ [[ Failed =~ ^(Pending|Success|Failed)$ ]]
+ [[ -z postgresql-1 ]]
+ [[ -z postgres ]]
+ echo 'Marking deployment of application "postgresql-1" as "Failed".'
Marking deployment of application "postgresql-1" as "Failed".
+ [[ Failed == \S\u\c\c\e\s\s ]]
+ kubectl patch applications.app.k8s.io/postgresql-1 --output=json --namespace=postgres --type=merge --patch '{"spec": {"assemblyPhase": "Failed"}}'
Using /opt/kubectl/default/kubectl (server=1.21)
  • Postgres pod status
$ kubectl -n postgres get po
NAME                          READY   STATUS    RESTARTS   AGE
postgresql-1-deployer-tz24c   0/1     Error     0          54m
postgresql-1-postgresql-0     2/2     Running   0          54m
@pipoe2h pipoe2h added kind/k8s Related to the Kubernetes application needs-triage This wasn't investigate by the repo's owners yet labels Feb 2, 2022
@pPanda-beta
Copy link

Try installing the Application CRD manually.

kubectl apply -f https://raw.githubusercontent.com/kubernetes-sigs/application/master/deploy/kube-app-manager-aio.yaml

After that just repeat the deploy steps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/k8s Related to the Kubernetes application needs-triage This wasn't investigate by the repo's owners yet
Projects
None yet
Development

No branches or pull requests

2 participants