Name: jekyll
Namespace: development
Priority: 0
Node: <none>
Labels: run=jekyll
Annotations: <none>
Status: Pending
IP:
IPs: <none>
Init Containers:
copy-jekyll-site:
Image: kodekloud/jekyll
Port: <none>
Host Port: <none>
Command:
jekyll
new
/site
Environment: <none>
Mounts:
/site from site (rw)
/var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-8h4pt (ro)
Containers:
jekyll:
Image: kodekloud/jekyll-serve
Port: <none>
Host Port: <none>
Environment: <none>
Mounts:
/site from site (rw)
/var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-8h4pt (ro)
Conditions:
Type Status
PodScheduled False
Volumes:
site:
Type: PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
ClaimName: jekyll-site
ReadOnly: false
kube-api-access-8h4pt:
Type: Projected (a volume that contains injected data from multiple sources)
TokenExpirationSeconds: 3607
ConfigMapName: kube-root-ca.crt
ConfigMapOptional: <nil>
DownwardAPI: true
QoS Class: BestEffort
Node-Selectors: <none>
Tolerations: node.kubernetes.io/not-ready:NoExecute op=Exists for 300s
node.kubernetes.io/unreachable:NoExecute op=Exists for 300s
Events: <none>
Is there something i’m missing? Everything else validates as correct. I spend 30 minutes getting everything else set up and then 30 minutes failing to troubleshoot this issue.
Really strange, but for anyone else encountering this issue - it resolved itself after some time. My guess is that the pending pod just took a while until it finally started up?
Just ran your YAML through the challenge. It is fine.
Note that the init container may take up to 90 seconds to do its job before the main container starts.
You should wait till the main container is fully running before pressing the check button
kubectl get po -n development
NAME READY STATUS RESTARTS AGE
jekyll 1/1 Running 0 3m55s
Error is related to ruby in init container image due to which the pod is not initializing although all the settings are correct in pod yaml.
/usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:91:in `block in materialize’: Could not find public_suffix-4.0.7 in any of the sources (Bundler::GemNotFound)
I have just tested that scenario and it is fine. Please post the YAML for your jekyll pod so that we may check it. Please remember to paste yaml within a code block to preserve indentation (use </> button in post editor)
Hi! I just arrived to this post after getting the same error. These are the logs on the container:
kubectl logs jekyll -n development copy-jekyll-site
/usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:91:in `block in materialize': Could not find public_suffix-4.0.7 in any of the sources (Bundler::GemNotFound)
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:85:in `map!'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:85:in `materialize'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:170:in `specs'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:237:in `specs_for'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:226:in `requested_specs'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:108:in `block in definition_method'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:20:in `setup'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler.rb:107:in `setup'
from /usr/local/bundle/gems/jekyll-3.8.5/lib/jekyll/plugin_manager.rb:50:in `require_from_bundler'
from /usr/local/bundle/gems/jekyll-3.8.5/exe/jekyll:11:in `<top (required)>'
from /usr/local/bundle/bin/jekyll:23:in `load'
from /usr/local/bundle/bin/jekyll:23:in `<main>'
I tried it several times, even restarting the environment.
I will be just skipping this part since I understand it is not an error on the problem proposed.
/usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:91:in `block in materialize': Could not find public_suffix-4.0.7 in any of the sources (Bundler::GemNotFound)
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:85:in `map!'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/spec_set.rb:85:in `materialize'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:170:in `specs'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:237:in `specs_for'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/definition.rb:226:in `requested_specs'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:108:in `block in definition_method'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:20:in `setup'
from /usr/local/lib/ruby/site_ruby/2.5.0/bundler.rb:107:in `setup'
from /usr/local/bundle/gems/jekyll-3.8.5/lib/jekyll/plugin_manager.rb:50:in `require_from_bundler'
from /usr/local/bundle/gems/jekyll-3.8.5/exe/jekyll:11:in `<top (required)>'
from /usr/local/bundle/bin/jekyll:23:in `load'
from /usr/local/bundle/bin/jekyll:23:in `<main>'
Hi,
After 4 times trying to finish this challenge and always failing on the above bug, I found out that the pvc binding is always failing for me (even if it is shown green) when the storageClassName is not set to local-storage.
This information is missing above and on the GitHub repository.
I ran into the same issue today. I tried to delete the pvc and pod and use the solution files from GitHub but then the pv got deleted. Frustrating. Thank you for looking into this, these challenges are great to practise on!
Merci for testing.
I tried the lab twice more (once I accidentally got the pvc incorrect and couldn’t delete the pv so got stuck again). The third time was the charm because by then I could do it flawlessly. It seems to work unless you have to try multiple times because, you know, you’re still learning…
Maybe it happens when you delete and recreate the pod and run the command twice?
Anyway, for others trying this out, it’s probably best to stop trying and just reset the environment once you mess up the pvc or you see that ruby error.