Added nixos-gen-seccure-keys and modified nixos-checkout to store /etc/nixos/version.nix with string representing checkout version.
svn path=/nixos/trunk/; revision=10936
This commit is contained in:
parent
6d07b2a545
commit
4b31843e64
@ -31,6 +31,11 @@ in
|
||||
src = ./nixos-rebuild.sh;
|
||||
};
|
||||
|
||||
nixosGenSeccureKeys = makeProg {
|
||||
name = "nixos-gen-seccure-keys";
|
||||
src = ./nixos-gen-seccure-keys.sh;
|
||||
};
|
||||
|
||||
nixosCheckout = makeProg {
|
||||
name = "nixos-checkout";
|
||||
src = ./nixos-checkout.sh;
|
||||
|
@ -57,3 +57,7 @@ svn co https://svn.cs.uu.nl:12443/repos/trace/services/trunk services
|
||||
# Add a few required symlink.
|
||||
ln -sfn ../services nixos${CHECKOUT_SUFFIX}/services
|
||||
ln -sfn ../nixpkgs${CHECKOUT_SUFFIX}/pkgs nixos${CHECKOUT_SUFFIX}/pkgs
|
||||
|
||||
REVISION=$(svn info nixpkgs${CHECKOUT_SUFFIX} | egrep '^Revision: ');
|
||||
REVISION=${REVISION#Revision: };
|
||||
echo "\"$REVISION\"" > version.nix
|
||||
|
13
installer/nixos-gen-seccure-keys.sh
Normal file
13
installer/nixos-gen-seccure-keys.sh
Normal file
@ -0,0 +1,13 @@
|
||||
#! @shell@ -e
|
||||
|
||||
mkdir -p /var/elliptic-keys
|
||||
chmod 0755 /var/elliptic-keys
|
||||
cd /var/elliptic-keys
|
||||
touch private
|
||||
chmod 0700 private
|
||||
dd if=/dev/urandom bs=128 count=1 of=private
|
||||
chmod 0500 private
|
||||
public=$(seccure-key -F private 2>&1)
|
||||
echo ${public#*The public key is: } > public
|
||||
chmod 0555 public
|
||||
|
Loading…
Reference in New Issue
Block a user