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

is it possible to change uid of yoctouser? #105

Open
mfide opened this issue Jun 6, 2024 · 0 comments
Open

is it possible to change uid of yoctouser? #105

mfide opened this issue Jun 6, 2024 · 0 comments

Comments

@mfide
Copy link

mfide commented Jun 6, 2024

I use following docker-compose.yml and it works fine on my debian12 system because by chance /home/mf/development folder in the host system owned by user mf and mf has UID:1000 which matches with yoctouser's UID in the container, therefore it has read/write access to the folder /home/yoctouser/development inside container.

services:
  yocto_builder:
    image: crops/yocto:ubuntu-22.04-base
    user: yoctouser
    container_name: yocto-builder
    hostname: yocto-builder
    command: ["sleep","infinity"]
    volumes:
      - /home/mf/development:/home/yoctouser/development
      - /home/mf/.ssh:/home/yoctouser/.ssh

But I have another system and my user name mfid with UID:1007 there. In this case, with the same docker compose file, I get Permission denied error inside container's development folder if I attempt to create a new file because yoctouser created in the container has UID:1000 which doesnt match with mfid's.

What is the suggested way to solve this problem?

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant