refactor(gs/home): Move rebuild-mugwump script to all machines
Chupacabra doesn't even exist anymore, plus I want this installed on all home systems Change-Id: Id0e5c89797b1ad52b2a24d60ad3ab5e125f60266 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2696 Reviewed-by: glittershark <grfn@gws.fyi> Tested-by: BuildkiteCI
This commit is contained in:
		
							parent
							
								
									8e13b1303a
								
							
						
					
					
						commit
						c3f35caefa
					
				
					 2 changed files with 10 additions and 10 deletions
				
			
		| 
						 | 
				
			
			@ -44,6 +44,16 @@
 | 
			
		|||
    nix-prefetch-github
 | 
			
		||||
    nix-review
 | 
			
		||||
    cachix
 | 
			
		||||
    (writeShellScriptBin "rebuild-mugwump" ''
 | 
			
		||||
      set -eo pipefail
 | 
			
		||||
      cd ~/code/depot
 | 
			
		||||
      nix build -f . users.glittershark.system.system.mugwumpSystem -o /tmp/mugwump
 | 
			
		||||
      nix copy -f . users.glittershark.system.system.mugwumpSystem \
 | 
			
		||||
        --to ssh://mugwump
 | 
			
		||||
      system=$(readlink -ef /tmp/mugwump)
 | 
			
		||||
      ssh mugwump sudo nix-env -p /nix/var/nix/profiles/system --set $system
 | 
			
		||||
      ssh mugwump sudo $system/bin/switch-to-configuration switch
 | 
			
		||||
    '')
 | 
			
		||||
  ];
 | 
			
		||||
 | 
			
		||||
  programs.ssh = {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue