-
Notifications
You must be signed in to change notification settings - Fork 172
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
Writing json file using cloud-init makes user loose permissions #133
Comments
Tested again but to write the file to Now that I ssh into the user I get as expected:
(Also gets the nice colors of the instead of the all back/white when it is not working 🙌 ) If I check the tmp folder, the data is there, but owned by root, so I tried adding
to the yaml file when flashing the sdcard. This did not help and checking in the tmp folder:
It seems like the parameters under |
Having the same problem in hypriot 1.10 is there a solution to this or I'm missing something too? |
The order seems to be write_files before creating users. That‘s how cloud-init works. You can try to run commands - I don‘t know if these run after the other both steps. |
Hi!
I'm using Hypriot 1.9.0 and a custom could-init file to configure my RPi setup.
The yaml file looks as follows:
and after ssh:ing into the pi using the ssh key, I'm faced with the following:
I have tried to change the content in the yaml file to be in base64 encoding, in case some invalid characters was present, but it has the same result.
I believe the main problem is that the file that I am writing makes the user (client) not owner of its own home directory! I'm unable to create any files/folders and as can be seen in the
ls -lhsa
output, the file created (setup/data.json
) is owned by root!I don't really understand what I am doing wrong here. What is the correct way to write JSON files using hypriot 1.9.0 and cloud-init?
The text was updated successfully, but these errors were encountered: