-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Kaniko returns chown: unknown user/group during FluentD container build #2163
Comments
This is the same issue as #1456. I looked into fluent/fluentd:latest image and it doesn't create the user fluent: Output from /etc/passwd and /etc/group $ cat /etc/passwd
root:x:0:0:root:/root:/bin/ash
bin:x:1:1:bin:/bin:/sbin/nologin
daemon:x:2:2:daemon:/sbin:/sbin/nologin
adm:x:3:4:adm:/var/adm:/sbin/nologin
lp:x:4:7:lp:/var/spool/lpd:/sbin/nologin
sync:x:5:0:sync:/sbin:/bin/sync
shutdown:x:6:0:shutdown:/sbin:/sbin/shutdown
halt:x:7:0:halt:/sbin:/sbin/halt
mail:x:8:12:mail:/var/spool/mail:/sbin/nologin
news:x:9:13:news:/usr/lib/news:/sbin/nologin
uucp:x:10:14:uucp:/var/spool/uucppublic:/sbin/nologin
operator:x:11:0:operator:/root:/bin/sh
man:x:13:15:man:/usr/man:/sbin/nologin
postmaster:x:14:12:postmaster:/var/spool/mail:/sbin/nologin
cron:x:16:16:cron:/var/spool/cron:/sbin/nologin
ftp:x:21:21::/var/lib/ftp:/sbin/nologin
sshd:x:22:22:sshd:/dev/null:/sbin/nologin
at:x:25:25:at:/var/spool/cron/atjobs:/sbin/nologin
squid:x:31:31:Squid:/var/cache/squid:/sbin/nologin
xfs:x:33:33:X Font Server:/etc/X11/fs:/sbin/nologin
games:x:35:35:games:/usr/games:/sbin/nologin
postgres:x:70:70::/var/lib/postgresql:/bin/sh
cyrus:x:85:12::/usr/cyrus:/sbin/nologin
vpopmail:x:89:89::/var/vpopmail:/sbin/nologin
ntp:x:123:123:NTP:/var/empty:/sbin/nologin
smmsp:x:209:209:smmsp:/var/spool/mqueue:/sbin/nologin
guest:x:405:100:guest:/dev/null:/sbin/nologin
nobody:x:65534:65534:nobody:/:/sbin/nologin
$ cat /etc/group
root:x:0:root
bin:x:1:root,bin,daemon
daemon:x:2:root,bin,daemon
sys:x:3:root,bin,adm
adm:x:4:root,adm,daemon
tty:x:5:
disk:x:6:root,adm
lp:x:7:lp
mem:x:8:
kmem:x:9:
wheel:x:10:root
floppy:x:11:root
mail:x:12:mail
news:x:13:news
uucp:x:14:uucp
man:x:15:man
cron:x:16:cron
console:x:17:
audio:x:18:
cdrom:x:19:
dialout:x:20:root
ftp:x:21:
sshd:x:22:
input:x:23:
at:x:25:at
tape:x:26:root
video:x:27:root
netdev:x:28:
readproc:x:30:
squid:x:31:squid
xfs:x:33:xfs
kvm:x:34:kvm
games:x:35:
shadow:x:42:
postgres:x:70:
cdrw:x:80:
usb:x:85:
vpopmail:x:89:
users:x:100:games
ntp:x:123:
nofiles:x:200:
smmsp:x:209:smmsp
locate:x:245:
abuild:x:300:
utmp:x:406:
ping:x:999:
nogroup:x:65533:
nobody:x:65534: This should be fixed once #2106 is merged. |
Hi @hown3d ! fluent/fluentd:latest image is very old, this tag was last updated 4 years ago, don't know the reason: I'm using version v1.14-1 (Docker tag is v1.14-1) and user fluent is ok inside the container:
Here is the base image from which I'm starting the customization: |
Issue solved, there was a problem with the GitLab pipeline that isn't passing the correct value to the --build-arg that sets the tag on FluentD image inside dockerfile. So by default fluentd was using the tag "latest" that was last updated 4 years ago and has not the user fluent inside. Passing the correct build arg with tag v1.14-1 for Fluentd solved the issue. |
Actual behavior
Kaniko returns "chown: unknown user/group fluent:fluent" during FluentD container build with the following command in Dockerfile:
Expected behavior
Container build is expected to complete successfully without errors, like in Docker environment.
To Reproduce
Steps to reproduce the behavior:
Just try to build the container with the following command or with the GitLab pipeline attached in the "Additional information" section. Variable values are specified in the GitLab pipeline.
Additional Information
User and group exists in FluentD original image. Also if I try to run the build pipeline with a Docker in Docker executable no error is raised.
Dockerfile
Context
Dockerfile is built in a GitLab Pipeline with the following script:
Kaniko Image (fully qualified with digest)
Using docker image sha256:e1e8f684a8d2023df1c21f06f2a66f7ec7ef965e6d092c7efe00ca6d592b2e6b for gcr.io/kaniko-project/executor:debug with digest gcr.io/kaniko-project/executor@sha256:3bc3f3a05f803cac29164ce12617a7be64931748c944f6c419565f500b65e8db ...
Triage Notes for the Maintainers
--cache
flagThe text was updated successfully, but these errors were encountered: