-
-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
nixos/ec2: don't populate nonexistent metadata files #218482
Conversation
4184e34
to
7e4e6e8
Compare
tested on an EC2 instance:
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/1890 |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/1932 |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/1933 |
Hmm was going to play around with nixos on ec2 today but am running into this issue. Will wait for the merge and try again :) Thank you! |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
Description of changes
Relevant issue: #212614
curl http://169.254.169.254/1.0/user-data
returns an HTML 404 response page. This gets written to/etc/ec2-metadata/user-data
by thefetch-ec2-metadata.service
, and eventually picked up byamazon-init.service
. This service overwrites/etc/nixos/configuration.nix
with this 404 page.adding
--fail
to the curl call will prevent files from being created in/etc/ec2-metadata
if the response is not 200.Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)