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

error: accumulating resources #19

Open
OverwhelmedStudent opened this issue Feb 7, 2022 · 21 comments · Fixed by #21
Open

error: accumulating resources #19

OverwhelmedStudent opened this issue Feb 7, 2022 · 21 comments · Fixed by #21
Labels
bug Something isn't working

Comments

@OverwhelmedStudent
Copy link

I went through the steps to deploy Jitsi on my microk8s cluster with kustomize and recieve following error:

error: accumulating resources: accumulation err='accumulating resources from 'https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize': yaml: line 218: mapping values are not allowed in this context': evalsymlink failure on '/tmp/kustomize-2873540753/tree/main/doc/kustomize' : lstat /tmp/kustomize-2873540753/tree: no such file or directory

What have I done wrong?

The plan is to run jitsi on a internal server and access the Service with the IP, without exposing anything to the internet, so a https certificate by letsencrypt is not required or relevant for us.

I enabled the Ingress microk8s addon and created the .yaml files like this:

010-deployment.yaml

apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    k8s-app: jitsi
  name: jitsi
  namespace: jitsi	   
spec:
  template:
    metadata:
      labels:
        k8s-app: jitsi
    spec:
      containers:
        - name: web
          env:
            - name: PUBLIC_URL
              value: "http://192.168.1.70"

        - name: prosody
          env:
            - name: PUBLIC_URL
              value: "http://192.168.1.70"

041-ingress.yaml

---
###################################################
# Ingress
###################################################
kind: Ingress
apiVersion: networking.k8s.io/v1
metadata:
  name: jitsi
  namespace: jitsi
  annotations:
    cert-manager.io/cluster-issuer: "letsencrypt-prod"
spec:
  tls:
  - hosts:
    - 192.168.1.70
    secretName: tls-jitsi
  rules:
  - host: 192.168.1.70
    http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          service:
            name: web
            port:
              number: 80

kustomization.yaml

namespace: jitsi
bases:
- https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize

resources:
- 041-ingress.yaml

patchesStrategicMerge:
- 010-deployment.yaml

Thank you for your help!

@OverwhelmedStudent
Copy link
Author

I attempted a fresh microk8s installation on my local computer and ended up with the same Error, mentioning line 220.

Here are all commands i executed:
Installing Microk8s and dashboard:
sudo snap install microk8s --classic
sudo ufw allow in on cni0 && sudo ufw allow out on cni0
sudo ufw default allow routed
sudo microk8s enable dns dashboard storage
sudo microk8s status
sudo microk8s kubectl get all --all-namespaces
token=$(microk8s kubectl -n kube-system get secret | grep default-token | cut -d " " -f1)
sudo microk8s microk8s kubectl -n kube-system describe secret $token

Attempting installation with kustomize:
mkdir my-jitsi
cd my-jitsi
vim kustomization.yaml
vim 010-deployment.yaml
-> I took the ingress file out
-> I set the PUBLIC_URL to my IP

sudo microk8s kubectl create namespace jitsi
sudo microk8s kubectl create secret generic jitsi-config -n jitsi --from-literal=JICOFO_COMPONENT_SECRET=start --from-literal=JICOFO_AUTH_PASSWORD=start --from-literal=JVB_AUTH_PASSWORD=start
sudo microk8s kubectl apply -k ./my-jitsi

@rsoika
Copy link
Collaborator

rsoika commented Feb 8, 2022

Oh! Now I see that there is a typo in the docu.

The deployment file is 030-deployment.yaml and not '010-.....'

I think this causes the problem. Just rename your 010-deployment.yaml into 030-deployment.yaml This should do the trick.

I will update the documentation. Please let me know if this works for you.

@rsoika rsoika added the bug Something isn't working label Feb 8, 2022
rsoika added a commit that referenced this issue Feb 8, 2022
@OverwhelmedStudent
Copy link
Author

I updated the file name and kustomization.yaml
Sadly the issue remains.

error: accumulating resources: accumulation err='accumulating resources from 'https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize': yaml: line 225: mapping values are not allowed in this context': evalsymlink failure on '/tmp/kustomize-1066009744/tree/main/doc/kustomize' : lstat /tmp/kustomize-1066009744/tree: no such file or directory

@rsoika
Copy link
Collaborator

rsoika commented Feb 9, 2022

Then please take out the patchesStrategicMerge resoruce and test if this did work.
If yes, than something in your 030-deployment.yaml is incorrect.

@OverwhelmedStudent
Copy link
Author

The attempt with just the kustomization.yaml, without the resources and patchesStrategicMerge files did not work either, same error.

I appreciate your support!

Another idea is, the containerization of snap could cause issues accessing the tmp files.

@rsoika
Copy link
Collaborator

rsoika commented Feb 9, 2022

ok, then I am no longer convinced that microk8s fully support kustomize. The error messages are also not helpful.

@OverwhelmedStudent
Copy link
Author

Since I also do not know how to continue here, we have gone back to working with Kompose.

@Y0ngg4n
Copy link

Y0ngg4n commented Feb 10, 2022

Same issue here. I am on a bare metal cluster so i dont think it is because of microk8s.

@rsoika
Copy link
Collaborator

rsoika commented Feb 10, 2022

But kompose and kustomize are different concepts. I can't believe that you get the same error message. If so, it sounds to me that you have a different problem.

@Y0ngg4n
Copy link

Y0ngg4n commented Feb 10, 2022

@rsoika i get exactly the same error message

@TimNilimaa
Copy link

We get more or less the same issue,
% kubectl apply -k ./my-jitsi error: accumulating resources: accumulation err='accumulating resources from 'https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize': yaml: line 237: mapping values are not allowed in this context': evalsymlink failure on '/private/var/folders/q_/yfghdtd147xf71g9wf9fn66h0000gn/T/kustomize-954443534/tree/main/doc/kustomize' : lstat /private/var/folders/q_/yfghdtd147xf71g9wf9fn66h0000gn/T/kustomize-954443534/tree: no such file or directory

@rsoika
Copy link
Collaborator

rsoika commented Feb 15, 2022

Just to sort things out: if you remove the resources and patches in your kustzomiz file like the following one. Is it working?

namespace: jitsi
bases:
- https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize

#resources:
#- 041-ingress.yaml

#patchesStrategicMerge:
#- 030-deployment.yaml

@Y0ngg4n
Copy link

Y0ngg4n commented Feb 15, 2022

I have tried the helm install. Helm install is working.

@Buluc-Chabtan
Copy link

Buluc-Chabtan commented Feb 22, 2022

Still same issues when resources and patches are removed..

namespace: jitsi
bases:
- https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize

#resources:
#- 041-ingress.yaml

#patchesStrategicMerge:
#- 030-deployment.yaml

@rsoika
Copy link
Collaborator

rsoika commented Feb 23, 2022

Can someone narrow down the issue if this is related to the kubernetes environment/version? I am running in v1.21.6 and can not reproduce this kind of issue.

@Buluc-Chabtan
Copy link

Buluc-Chabtan commented Feb 23, 2022

I am running v1.22.4 in aks

@TimNilimaa
Copy link

TimNilimaa commented Feb 23, 2022 via email

@foobarbecue
Copy link
Contributor

same problem, k3s v1.22.7

@foobarbecue
Copy link
Contributor

foobarbecue commented Mar 6, 2022

Ok so the deal is that kustomize git urls are a complete mess and there's a whole chaos of issues and PRs about it, with this being the latest: kubernetes-sigs/kustomize#4454

What worked for me was removing https:// and /tree/main from the url, so you have:

namespace: jitsi
bases:
- github.com/jitsi-contrib/jitsi-kubernetes/doc/kustomize
...

I can go ahead and make a PR for this.

foobarbecue added a commit to foobarbecue/jitsi-kubernetes that referenced this issue Mar 6, 2022
@rsoika
Copy link
Collaborator

rsoika commented Mar 6, 2022

Yes you are totally right! There is in deed a wrong URL in the docu and I have overseen this all the time during this discussion.

@rsoika rsoika closed this as completed in #21 Mar 6, 2022
@rsoika rsoika reopened this Mar 6, 2022
@rsoika
Copy link
Collaborator

rsoika commented Mar 6, 2022

Please give us some feedback if this solves your problem.

Solution:

replace in your kustomization.yaml file the line

- https://github.com/jitsi-contrib/jitsi-kubernetes/tree/main/doc/kustomize

with

- github.com/jitsi-contrib/jitsi-kubernetes/doc/kustomize

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants