Skip to content

Instantly share code, notes, and snippets.

@worldofpeace
Created October 3, 2019 17:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save worldofpeace/831e661a474d88924e7493073ca3b119 to your computer and use it in GitHub Desktop.
Save worldofpeace/831e661a474d88924e7493073ca3b119 to your computer and use it in GitHub Desktop.
{ config, lib, pkgs, ... }:
{
imports = [
<nixpkgs/nixos>/virtualisation/qemu-vm.nix
];
virtualisation.qemu.networkingOptions = [
"-netdev user,id=user.0\${QEMU_NET_OPTS:+,$QEMU_NET_OPTS},hostfwd=tcp::8088-:80,hostfwd=tcp::2222-:22"
];
}
@worldofpeace
Copy link
Author

I believe the command you can use is

ssh -p 2222 root@localhost

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment