forked from fediversity/fediversity
		
	closes #93. note that this includes classes: - `nixos` - `nixosTest` - `nixops4Resource` - `nixops4Deployment` .. and my (made-up, as per the [docs](https://ryantm.github.io/nixpkgs/module-system/module-system/#module-system-lib-evalModules-param-class)): - `nix-unit` - `package` .. while i did not manage to cover: - service tests, given `pkgs.nixosTest` seemed to not actually like `_class = "nixosTest"` (?!) ... nor #93's mentioned destructured arguments for that matter, as per Fediversity/Fediversity#93 (comment) - let me know if that is still desired as well. Reviewed-on: Fediversity/Fediversity#398 Reviewed-by: Valentin Gagarin <valentin.gagarin@tweag.io> Co-authored-by: Kiara Grouwstra <kiara@procolix.eu> Co-committed-by: Kiara Grouwstra <kiara@procolix.eu>
		
			
				
	
	
		
			36 lines
		
	
	
	
		
			787 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
	
		
			787 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
{
 | 
						|
  modulesPath,
 | 
						|
  pkgs,
 | 
						|
  ...
 | 
						|
}:
 | 
						|
 | 
						|
{
 | 
						|
  _class = "nixos";
 | 
						|
 | 
						|
  imports = [ (modulesPath + "/virtualisation/qemu-vm.nix") ];
 | 
						|
 | 
						|
  fediversity = {
 | 
						|
    domain = "localhost";
 | 
						|
    peertube = {
 | 
						|
      enable = true;
 | 
						|
      secretsFile = pkgs.writeText "secret" "574e093907d1157ac0f8e760a6deb1035402003af5763135bae9cbd6abe32b24";
 | 
						|
      s3AccessKeyFile = pkgs.writeText "s3AccessKey" "GK1f9feea9960f6f95ff404c9b";
 | 
						|
      s3SecretKeyFile = pkgs.writeText "s3SecretKey" "7295c4201966a02c2c3d25b5cea4a5ff782966a2415e3a196f91924631191395";
 | 
						|
    };
 | 
						|
  };
 | 
						|
 | 
						|
  services.peertube = {
 | 
						|
    settings = {
 | 
						|
      listen.hostname = "0.0.0.0";
 | 
						|
      instance.name = "PeerTube Test VM";
 | 
						|
    };
 | 
						|
  };
 | 
						|
 | 
						|
  virtualisation.forwardPorts = [
 | 
						|
    {
 | 
						|
      from = "host";
 | 
						|
      host.port = 9000;
 | 
						|
      guest.port = 9000;
 | 
						|
    }
 | 
						|
  ];
 | 
						|
}
 |