| Summary: | Pod Template works with one image, but not another | ||
|---|---|---|---|
| Product: | Community | Reporter: | Nobody - feel free to take it <nobody> |
| Component: | CI-Jenkins | Assignee: | CI Admin Inbox <ci.admin-inbox> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | frederic.gurr, webmaster |
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
|
Description
Nobody - feel free to take it
Here is what the Jenkins log says:
Error in provisioning; agent=KubernetesSlave name: xtext-ref-jdk-8-null-44-smclk-fnn7h, template=PodTemplate{, name='xtext-ref-jdk-8-null-44-smclk', namespace='xtext', label='xtext-ref-jdk-8-null-44', nodeUsageMode=EXCLUSIVE, annotations=[org.csanchez.jenkins.plugins.kubernetes.PodAnnotation@aab9c821]}. Container xtext-maven-jdk-8 exited with error 1. Logs: Can not write to /root/.m2/copy_reference_file.log. Wrong volume permissions? Carrying on ...
[[1;31mERROR[m] Could not create local repository at /?/.m2/repository -> [1m[Help 1]
So it seems like it's an issue with the image.
Thanks! Okay. It looks like I'm still using the default root user :-( I created a new user, using the same UID from the other (functioning) image, but I still don't get any agents: https://ci.eclipse.org/xtext/job/xtext-reference-projects/48/console Did the error message change at least? :-) New error (in the container log) is: bash: /home/default/.bashrc: Permission denied Okay, I've been trying to find out what the main difference is between my image and the one that works, and it turns out I don't seem to configure the uid stuff correctly. However, I decided against using this image altogether, because using the "official" eclipse-cbi image should be enough. And I thought, this should work out of the box, but it does not: https://ci.eclipse.org/xtext/job/xtext-reference-projects/54/console This bug seems to go stale, but I still don't know what I'm doing wrong. This build successfully spawned an agent: https://ci.eclipse.org/xtext/job/xtext-reference-projects/59/ It basically uses the same pod template as another job and executes the pipeline in docker.io/smoht/xtext-buildenv:0.7. xtext-buildenv:0.7 is based on `eclipsecbi/fedora-gtk3-mutter:29-gtk3.24` and does little more than install some tools and create a new user (uid 10002). This build does not spawn any agent: https://ci.eclipse.org/xtext/job/xtext-reference-projects/60/ The only difference here is that I switched the image spec to: `image: eclipsecbi/fedora-gtk3-mutter:31-gtk3.24` in the pod template. Why does this image (which I assume is somewhat 'official') fail, while our downstream image continues to work? Your container immediately terminates, since no command is run.
Please try to add "command: - cat" like
- name: xtext-ref-env
image: eclipsecbi/fedora-gtk3-mutter:31-gtk3.24
tty: true
command:
- cat
https://ci.eclipse.org/xtext/job/xtext-reference-projects/61/console Well, that did the trick. Our xtext-buildenv image does not add any command, but it does set the entrypoint to /bin/bash, while the entrypoint of the base image actually depends on receiving commands. This was very confusing to figure out. Might I suggest adding 'cat' as default command in the base images? Thanks for your help! |