Skip to content

Commit

Permalink
Merge pull request #32 from hercules-ci/update
Browse files Browse the repository at this point in the history
Update
  • Loading branch information
Kranzes authored Feb 26, 2023
2 parents bc3cf1c + f16a69f commit be1ea32
Show file tree
Hide file tree
Showing 8 changed files with 189 additions and 303 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
result
result-*
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ machines in a network or cloud.
* [Continuous build](http://hydra.nixos.org/jobset/nixops/master#tabs-jobs)
* [Source code](https://github.com/NixOS/nixops)
* [Issue Tracker](https://github.com/NixOS/nixops/issues)
* [Mailing list / Google group](https://groups.google.com/forum/#!forum/nixops-users)
* [IRC - #nixos on freenode.net](irc://irc.freenode.net/#nixos)

## Quick Start

Expand Down
7 changes: 7 additions & 0 deletions env.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{ pkgs ? import <nixpkgs> {} }:
let
overrides = import ./overrides.nix { inherit pkgs; };
in pkgs.poetry2nix.mkPoetryEnv {
projectDir = ./.;
overrides = pkgs.poetry2nix.overrides.withDefaults overrides;
}
5 changes: 4 additions & 1 deletion nixops_virtd/backends/libvirtd.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,10 @@ def read_file(stream, nbytes, f):

def _get_qemu_executable(self):
domaincaps_xml = self.conn.getDomainCapabilities(
emulatorbin=None, arch="x86_64", machine=None, virttype="kvm",
emulatorbin=None,
arch="x86_64",
machine=None,
virttype="kvm",
)
domaincaps = ElementTree.fromstring(domaincaps_xml)
return domaincaps.find("./path").text.strip()
Expand Down
4 changes: 4 additions & 0 deletions overrides.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@ self: super: {
propagatedBuildInputs = [ pkgs.libvirt ];
});

pathspec = super.pathspec.overridePythonAttrs({ nativeBuildInputs ? [], ... }: {
nativeBuildInputs = nativeBuildInputs ++ [ self.flit-core ];
});

}
454 changes: 165 additions & 289 deletions poetry.lock

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ authors = ["Amine Chikhaoui <[email protected]>"]
include = [ "nixops_libvirtd/nix/*.nix" ]

[tool.poetry.dependencies]
python = "^3.7"
python = "^3.10"
nixops = {git = "https://github.com/NixOS/nixops.git"}
libvirt-python = "^8.0"
libvirt-python = "^9.0"

[tool.poetry.plugins."nixops"]
virtd = "nixops_virtd.plugin"

[tool.poetry.dev-dependencies]
nose = "^1.3.7"
mypy = "^0.770"
black = "^19.10b0"
mypy = "^0.961"
black = "^22.6.0"
flake8 = "^3.8.2"

[build-system]
Expand Down
10 changes: 3 additions & 7 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
{ pkgs ? import <nixpkgs> {} }:
let
overrides = import ./overrides.nix { inherit pkgs; };
in pkgs.mkShell {

pkgs.mkShell {
buildInputs = [
(pkgs.poetry2nix.mkPoetryEnv {
projectDir = ./.;
overrides = pkgs.poetry2nix.overrides.withDefaults overrides;
})
(import ./env.nix { inherit pkgs; })
pkgs.poetry
pkgs.pkgconfig
pkgs.libvirt
Expand Down

0 comments on commit be1ea32

Please sign in to comment.