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:
Michael Raskin 2008-03-03 23:31:48 +00:00
parent 6d07b2a545
commit 4b31843e64
3 changed files with 22 additions and 0 deletions

View File

@ -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;

View File

@ -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

View 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