diff --git a/.github/workflows/cachix-push.yaml b/.github/workflows/cachix-push.yaml new file mode 100644 index 00000000000..fe8c4266a69 --- /dev/null +++ b/.github/workflows/cachix-push.yaml @@ -0,0 +1,38 @@ +name: "Cachix Push" + +on: + workflow_run: + workflows: ["CI"] + branches: [master] + types: + - completed + +jobs: + cachix-push: + name: Cachix Push + runs-on: [self-hosted, nixos] + permissions: + contents: write + # if: ${{ github.event.workflow_run.conclusion == 'success' }} + steps: + + - name: 📥 Checkout repository + uses: actions/checkout@v4 + with: + repository: cardano-scaling/hydra + ref: release + # Also ensure we have all history with all tags + fetch-depth: 0 + + - name: ❄ Prepare nix + uses: cachix/install-nix-action@V27 + with: + extra_nix_config: | + accept-flake-config = true + log-lines = 1000 + + - name: Push Cachix + id: cachix-push + uses: actions/github-script@v7 + with: + script: nix run .#cachix-push diff --git a/.github/workflows/ci-nix.yaml b/.github/workflows/ci-nix.yaml index 4d2d3c46adb..72c5e1f208e 100644 --- a/.github/workflows/ci-nix.yaml +++ b/.github/workflows/ci-nix.yaml @@ -22,15 +22,15 @@ permissions: jobs: build-test: name: "Build & test" - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] strategy: matrix: include: - package: plutus-cbor - package: plutus-merkle-tree - package: hydra-plutus - - package: hydra-tui - package: hydra-node + - package: hydra-tui - package: hydra-tx - package: hydra-cluster steps: @@ -44,12 +44,6 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: ❓ Test if: ${{ matrix.package != 'hydra-tui' }} run: | @@ -60,11 +54,6 @@ jobs: - name: ❓ Test (TUI) id: test_tui if: ${{ matrix.package == 'hydra-tui' }} - # https://giters.com/gfx/example-github-actions-with-tty - # The default shell does not allocate a TTY which breaks some tests - shell: 'script -q -e -c "bash {0}"' - env: - TERM: "xterm" run: | cd ${{ matrix.package }} nix build .#${{ matrix.package }}-tests @@ -91,7 +80,7 @@ jobs: publish-test-results: name: Publish test results needs: [build-test] - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Download test results uses: actions/download-artifact@v4 @@ -106,7 +95,7 @@ jobs: haddock: name: "Build haddock using nix" - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Checkout repository uses: actions/checkout@v4 @@ -118,27 +107,19 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: 📚 Documentation (Haddock) run: | nix build .#haddocks - mkdir -p haddocks - cp -aL result/* haddocks/ - name: 💾 Upload haddock artifact uses: actions/upload-artifact@v4 with: name: haddocks - path: haddocks + path: result benchmarks: name: "Benchmarks" - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] strategy: matrix: include: @@ -165,12 +146,6 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: 📈 Benchmark run: | mkdir -p benchmarks @@ -198,7 +173,7 @@ jobs: if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository # TODO: this is actually only requires the tx-cost benchmark results needs: [benchmarks] - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Download generated documentation uses: actions/download-artifact@v4 @@ -232,7 +207,7 @@ jobs: nix-flake-check: name: "nix flake check" - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Checkout repository uses: actions/checkout@v4 @@ -244,12 +219,6 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: ❄ Nix Flake Check run: | nix flake check -L @@ -257,7 +226,7 @@ jobs: build-specification: name: "Build specification using nix" - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Checkout repository uses: actions/checkout@v4 @@ -269,12 +238,6 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: ❄ Build specification PDF run: | nix build .#spec && cp result/*.pdf . @@ -289,7 +252,7 @@ jobs: documentation: name: Documentation needs: [haddock,benchmarks,build-test,build-specification] - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Checkout repository uses: actions/checkout@v4 diff --git a/.github/workflows/formatting.yaml b/.github/workflows/formatting.yaml index 9fe8aeec4f3..68090b5dd86 100644 --- a/.github/workflows/formatting.yaml +++ b/.github/workflows/formatting.yaml @@ -6,7 +6,7 @@ on: jobs: formatting: name: Check code formatting - runs-on: ubuntu-latest + runs-on: [self-hosted, nixos] steps: - name: 📥 Checkout repository uses: actions/checkout@v4 @@ -18,12 +18,6 @@ jobs: accept-flake-config = true log-lines = 1000 - - name: ❄ Cachix cache of nix derivations - uses: cachix/cachix-action@v15 - with: - name: cardano-scaling - authToken: '${{ secrets.CACHIX_CARDANO_SCALING_AUTH_TOKEN }}' - - name: 📐 Check code formatting run: | nix build .#checks.x86_64-linux.treefmt diff --git a/README.md b/README.md index f448c1ff38d..4c8cd30be97 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,6 @@ #
Hydra :dragon_face:
+Implementation of the Hydra scalability protocols.
diff --git a/flake.lock b/flake.lock index c916cc0f820..59936a15ed5 100644 --- a/flake.lock +++ b/flake.lock @@ -232,6 +232,48 @@ "type": "github" } }, + "cachix": { + "inputs": { + "devenv": "devenv", + "flake-compat": "flake-compat", + "hnix-store-core": "hnix-store-core", + "nixpkgs": "nixpkgs_2" + }, + "locked": { + "lastModified": 1679144949, + "narHash": "sha256-xhLCsAkz5c+XIqQ4eGY9bSp3zBgCDCaHXZ2HLk8vqmE=", + "owner": "cachix", + "repo": "cachix", + "rev": "c8f0d787939c93cc686c2604f7d024e631e4a00d", + "type": "github" + }, + "original": { + "owner": "cachix", + "ref": "v1.3.3", + "repo": "cachix", + "type": "github" + } + }, + "cachix-push": { + "inputs": { + "cachix": "cachix", + "devour-flake": "devour-flake" + }, + "locked": { + "lastModified": 1723482511, + "narHash": "sha256-sD2tDDa2dndpESE4QBcF1x/m6dtLod+4kxP5hppv/l4=", + "owner": "juspay", + "repo": "cachix-push", + "rev": "c8e142cbe5a1e4ebe21bcbc8e8359efd73d18174", + "type": "github" + }, + "original": { + "owner": "juspay", + "repo": "cachix-push", + "rev": "c8e142cbe5a1e4ebe21bcbc8e8359efd73d18174", + "type": "github" + } + }, "call-flake": { "locked": { "lastModified": 1687380775, @@ -249,7 +291,7 @@ }, "cardano-automation": { "inputs": { - "flake-utils": "flake-utils", + "flake-utils": "flake-utils_2", "haskellNix": [ "cardano-node", "haskellNix" @@ -276,7 +318,7 @@ }, "cardano-mainnet-mirror": { "inputs": { - "nixpkgs": "nixpkgs_4" + "nixpkgs": "nixpkgs_6" }, "locked": { "lastModified": 1642701714, @@ -301,7 +343,7 @@ "customConfig": "customConfig", "em": "em", "empty-flake": "empty-flake", - "flake-compat": "flake-compat_2", + "flake-compat": "flake-compat_3", "hackageNix": "hackageNix", "haskellNix": "haskellNix", "hostNixpkgs": [ @@ -402,6 +444,47 @@ "type": "github" } }, + "devenv": { + "inputs": { + "flake-compat": [ + "cachix-push", + "cachix", + "flake-compat" + ], + "nix": "nix", + "nixpkgs": "nixpkgs", + "pre-commit-hooks": "pre-commit-hooks" + }, + "locked": { + "lastModified": 1678184100, + "narHash": "sha256-6R0LmBiS2E6CApdqqFpY2IBXDAg2RQ2JHBkJOLMxXsY=", + "owner": "cachix", + "repo": "devenv", + "rev": "b9e0ace80abd0ca5631ab5df7d6562ba9d8af50c", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "devenv", + "type": "github" + } + }, + "devour-flake": { + "flake": false, + "locked": { + "lastModified": 1682445319, + "narHash": "sha256-TTWt0MNxCjW6Rc0z8Li0X3O7wdAj1tr7tnPHxERb0p0=", + "owner": "srid", + "repo": "devour-flake", + "rev": "6cd32c62c4d7ef76f6e8534ae578a395af6cafce", + "type": "github" + }, + "original": { + "owner": "srid", + "repo": "devour-flake", + "type": "github" + } + }, "devshell": { "inputs": { "flake-utils": [ @@ -529,6 +612,22 @@ } }, "flake-compat": { + "flake": false, + "locked": { + "lastModified": 1673956053, + "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_2": { "flake": false, "locked": { "lastModified": 1650374568, @@ -544,7 +643,7 @@ "type": "github" } }, - "flake-compat_2": { + "flake-compat_3": { "flake": false, "locked": { "lastModified": 1647532380, @@ -561,7 +660,7 @@ "type": "github" } }, - "flake-compat_3": { + "flake-compat_4": { "flake": false, "locked": { "lastModified": 1672831974, @@ -578,7 +677,7 @@ "type": "github" } }, - "flake-compat_4": { + "flake-compat_5": { "flake": false, "locked": { "lastModified": 1672831974, @@ -665,6 +764,21 @@ } }, "flake-utils_2": { + "locked": { + "lastModified": 1667395993, + "narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flake-utils_3": { "locked": { "lastModified": 1653893745, "narHash": "sha256-0jntwV3Z8//YwuOjzhV2sgJJPt+HY6KhU7VZUL0fKZQ=", @@ -679,7 +793,7 @@ "type": "github" } }, - "flake-utils_3": { + "flake-utils_4": { "locked": { "lastModified": 1659877975, "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", @@ -694,7 +808,7 @@ "type": "github" } }, - "flake-utils_4": { + "flake-utils_5": { "locked": { "lastModified": 1653893745, "narHash": "sha256-0jntwV3Z8//YwuOjzhV2sgJJPt+HY6KhU7VZUL0fKZQ=", @@ -709,7 +823,7 @@ "type": "github" } }, - "flake-utils_5": { + "flake-utils_6": { "inputs": { "systems": "systems" }, @@ -727,7 +841,7 @@ "type": "github" } }, - "flake-utils_6": { + "flake-utils_7": { "locked": { "lastModified": 1644229661, "narHash": "sha256-1YdnJAsNy69bpcjuoKdOYQX0YxZBiCYZo4Twxerqv7k=", @@ -829,9 +943,33 @@ "url": "https://gitlab.haskell.org/ghc/ghc" } }, + "gitignore": { + "inputs": { + "nixpkgs": [ + "cachix-push", + "cachix", + "devenv", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1660459072, + "narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "a20de23b925fd8264fd7fad6454652e142fd7f73", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, "gomod2nix": { "inputs": { - "nixpkgs": "nixpkgs", + "nixpkgs": "nixpkgs_3", "utils": "utils" }, "locked": { @@ -887,7 +1025,7 @@ "cabal-34": "cabal-34", "cabal-36": "cabal-36", "cardano-shell": "cardano-shell", - "flake-compat": "flake-compat_3", + "flake-compat": "flake-compat_4", "ghc-8.6.5-iohk": "ghc-8.6.5-iohk", "ghc910X": "ghc910X", "ghc911": "ghc911", @@ -943,7 +1081,7 @@ "cabal-34": "cabal-34_2", "cabal-36": "cabal-36_2", "cardano-shell": "cardano-shell_2", - "flake-compat": "flake-compat_4", + "flake-compat": "flake-compat_5", "ghc-8.6.5-iohk": "ghc-8.6.5-iohk_2", "hackage": "hackage", "hls-1.10": "hls-1.10_2", @@ -1350,6 +1488,23 @@ "type": "github" } }, + "hnix-store-core": { + "flake": false, + "locked": { + "lastModified": 1672658037, + "narHash": "sha256-UOe+dY1dhCvdEKjPF1gNpfc4cNhZSKSbvu4yG+XVqbg=", + "owner": "haskell-nix", + "repo": "hnix-store", + "rev": "81700e6e7c53bbd7c6b2c4913b9481e5827af92f", + "type": "github" + }, + "original": { + "owner": "haskell-nix", + "ref": "core-0.6.1.0", + "repo": "hnix-store", + "type": "github" + } + }, "hpc-coveralls": { "flake": false, "locked": { @@ -1384,7 +1539,7 @@ }, "hydra": { "inputs": { - "nix": "nix", + "nix": "nix_2", "nixpkgs": [ "cardano-node", "haskellNix", @@ -1410,7 +1565,7 @@ "inputs": { "flake-parts": "flake-parts_2", "formal-ledger": "formal-ledger", - "nixpkgs": "nixpkgs_9" + "nixpkgs": "nixpkgs_11" }, "locked": { "lastModified": 1725260503, @@ -1428,7 +1583,7 @@ }, "hydra_2": { "inputs": { - "nix": "nix_2", + "nix": "nix_3", "nixpkgs": [ "haskellNix", "hydra", @@ -1474,7 +1629,7 @@ "iohk-nix": { "inputs": { "blst": "blst_2", - "nixpkgs": "nixpkgs_10", + "nixpkgs": "nixpkgs_12", "secp256k1": "secp256k1_2", "sodium": "sodium_2" }, @@ -1567,7 +1722,7 @@ }, "lint-utils": { "inputs": { - "flake-utils": "flake-utils_6", + "flake-utils": "flake-utils_7", "nixpkgs": [ "haskellNix", "nixpkgs" @@ -1619,6 +1774,22 @@ "type": "github" } }, + "lowdown-src_3": { + "flake": false, + "locked": { + "lastModified": 1633514407, + "narHash": "sha256-Dw32tiMjdK9t3ETl5fzGrutQTzh2rufgZV4A/BbxuD4=", + "owner": "kristapsdz", + "repo": "lowdown", + "rev": "d2c2b44ff6c27b936ec27358a2653caaef8f73b8", + "type": "github" + }, + "original": { + "owner": "kristapsdz", + "repo": "lowdown", + "type": "github" + } + }, "mdbook-kroki-preprocessor": { "flake": false, "locked": { @@ -1639,7 +1810,7 @@ "inputs": { "crane": "crane", "flake-parts": "flake-parts_3", - "nixpkgs": "nixpkgs_11", + "nixpkgs": "nixpkgs_13", "treefmt-nix": "treefmt-nix" }, "locked": { @@ -1659,7 +1830,7 @@ }, "n2c": { "inputs": { - "flake-utils": "flake-utils_4", + "flake-utils": "flake-utils_5", "nixpkgs": [ "cardano-node", "cardano-automation", @@ -1685,27 +1856,32 @@ "nix": { "inputs": { "lowdown-src": "lowdown-src", - "nixpkgs": "nixpkgs_5", + "nixpkgs": [ + "cachix-push", + "cachix", + "devenv", + "nixpkgs" + ], "nixpkgs-regression": "nixpkgs-regression" }, "locked": { - "lastModified": 1661606874, - "narHash": "sha256-9+rpYzI+SmxJn+EbYxjGv68Ucp22bdFUSy/4LkHkkDQ=", - "owner": "NixOS", + "lastModified": 1676545802, + "narHash": "sha256-EK4rZ+Hd5hsvXnzSzk2ikhStJnD63odF7SzsQ8CuSPU=", + "owner": "domenkozar", "repo": "nix", - "rev": "11e45768b34fdafdcf019ddbd337afa16127ff0f", + "rev": "7c91803598ffbcfe4a55c44ac6d49b2cf07a527f", "type": "github" }, "original": { - "owner": "NixOS", - "ref": "2.11.0", + "owner": "domenkozar", + "ref": "relaxed-flakes", "repo": "nix", "type": "github" } }, "nix-nomad": { "inputs": { - "flake-compat": "flake-compat", + "flake-compat": "flake-compat_2", "flake-utils": [ "cardano-node", "cardano-automation", @@ -1743,7 +1919,7 @@ }, "nix-npm-buildpackage": { "inputs": { - "nixpkgs": "nixpkgs_12" + "nixpkgs": "nixpkgs_14" }, "locked": { "lastModified": 1686315622, @@ -1761,8 +1937,8 @@ }, "nix2container": { "inputs": { - "flake-utils": "flake-utils_2", - "nixpkgs": "nixpkgs_2" + "flake-utils": "flake-utils_3", + "nixpkgs": "nixpkgs_4" }, "locked": { "lastModified": 1658567952, @@ -1780,8 +1956,8 @@ }, "nix2container_2": { "inputs": { - "flake-utils": "flake-utils_5", - "nixpkgs": "nixpkgs_6" + "flake-utils": "flake-utils_6", + "nixpkgs": "nixpkgs_8" }, "locked": { "lastModified": 1712990762, @@ -1800,7 +1976,7 @@ "nix_2": { "inputs": { "lowdown-src": "lowdown-src_2", - "nixpkgs": "nixpkgs_8", + "nixpkgs": "nixpkgs_7", "nixpkgs-regression": "nixpkgs-regression_2" }, "locked": { @@ -1818,6 +1994,27 @@ "type": "github" } }, + "nix_3": { + "inputs": { + "lowdown-src": "lowdown-src_3", + "nixpkgs": "nixpkgs_10", + "nixpkgs-regression": "nixpkgs-regression_3" + }, + "locked": { + "lastModified": 1661606874, + "narHash": "sha256-9+rpYzI+SmxJn+EbYxjGv68Ucp22bdFUSy/4LkHkkDQ=", + "owner": "NixOS", + "repo": "nix", + "rev": "11e45768b34fdafdcf019ddbd337afa16127ff0f", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "2.11.0", + "repo": "nix", + "type": "github" + } + }, "nixago": { "inputs": { "flake-utils": [ @@ -1858,16 +2055,16 @@ }, "nixpkgs": { "locked": { - "lastModified": 1653581809, - "narHash": "sha256-Uvka0V5MTGbeOfWte25+tfRL3moECDh1VwokWSZUdoY=", + "lastModified": 1677534593, + "narHash": "sha256-PuZSAHeq4/9pP/uYH1FcagQ3nLm/DrDrvKi/xC9glvw=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "83658b28fe638a170a19b8933aa008b30640fbd1", + "rev": "3ad64d9e2d5bf80c877286102355b1625891ae9a", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-unstable", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } @@ -2164,6 +2361,38 @@ "type": "github" } }, + "nixpkgs-regression_3": { + "locked": { + "lastModified": 1643052045, + "narHash": "sha256-uGJ0VXIhWKGXxkeNnq4TvV3CIOkUJ3PAoLZ3HMzNVMw=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", + "type": "github" + } + }, + "nixpkgs-stable": { + "locked": { + "lastModified": 1673800717, + "narHash": "sha256-SFHraUqLSu5cC6IxTprex/nTsI81ZQAtDvlBvGDWfnA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "2f9fd351ec37f5d479556cd48be4ca340da59b8f", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-22.11", + "repo": "nixpkgs", + "type": "github" + } + }, "nixpkgs-unstable": { "locked": { "lastModified": 1694822471, @@ -2213,6 +2442,37 @@ } }, "nixpkgs_10": { + "locked": { + "lastModified": 1657693803, + "narHash": "sha256-G++2CJ9u0E7NNTAi9n5G8TdDmGJXcIjkJ3NF8cetQB8=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "365e1b3a859281cf11b94f87231adeabbdd878a2", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-22.05-small", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_11": { + "locked": { + "lastModified": 1718717814, + "narHash": "sha256-xB7AzKY4BP7yypo6g+sk1tnVK54sBIJMeEBB5CdbhT4=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "88af533d8ae8d1e7e4648decf7817ebff91abf56", + "type": "github" + }, + "original": { + "owner": "nixos", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_12": { "locked": { "lastModified": 1684171562, "narHash": "sha256-BMUWjVWAUdyMWKk0ATMC9H0Bv4qAV/TXwwPUvTiC5IQ=", @@ -2228,7 +2488,7 @@ "type": "github" } }, - "nixpkgs_11": { + "nixpkgs_13": { "locked": { "lastModified": 1721933792, "narHash": "sha256-zYVwABlQnxpbaHMfX6Wt9jhyQstFYwN2XjleOJV3VVg=", @@ -2244,7 +2504,7 @@ "type": "github" } }, - "nixpkgs_12": { + "nixpkgs_14": { "locked": { "lastModified": 1653917367, "narHash": "sha256-04MsJC0g9kE01nBuXThMppZK+yvCZECQnUaZKSU+HJo=", @@ -2259,6 +2519,38 @@ } }, "nixpkgs_2": { + "locked": { + "lastModified": 1678072060, + "narHash": "sha256-6a9Tbjhir5HxDx4uw0u6Z+LHUfYf7tsT9QxF9FN/32w=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "47c003416297e4d59a5e3e7a8b15cdbdf5110560", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-22.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { + "locked": { + "lastModified": 1653581809, + "narHash": "sha256-Uvka0V5MTGbeOfWte25+tfRL3moECDh1VwokWSZUdoY=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "83658b28fe638a170a19b8933aa008b30640fbd1", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_4": { "locked": { "lastModified": 1654807842, "narHash": "sha256-ADymZpr6LuTEBXcy6RtFHcUZdjKTBRTMYwu19WOx17E=", @@ -2273,7 +2565,7 @@ "type": "github" } }, - "nixpkgs_3": { + "nixpkgs_5": { "locked": { "lastModified": 1665087388, "narHash": "sha256-FZFPuW9NWHJteATOf79rZfwfRn5fE0wi9kRzvGfDHPA=", @@ -2289,7 +2581,7 @@ "type": "github" } }, - "nixpkgs_4": { + "nixpkgs_6": { "locked": { "lastModified": 1642336556, "narHash": "sha256-QSPPbFEwy0T0DrIuSzAACkaANPQaR1lZR/nHZGz9z04=", @@ -2303,7 +2595,7 @@ "type": "indirect" } }, - "nixpkgs_5": { + "nixpkgs_7": { "locked": { "lastModified": 1657693803, "narHash": "sha256-G++2CJ9u0E7NNTAi9n5G8TdDmGJXcIjkJ3NF8cetQB8=", @@ -2319,7 +2611,7 @@ "type": "github" } }, - "nixpkgs_6": { + "nixpkgs_8": { "locked": { "lastModified": 1712920918, "narHash": "sha256-1yxFvUcJfUphK9V91KufIQom7gCsztza0H4Rz2VCWUU=", @@ -2334,7 +2626,7 @@ "type": "github" } }, - "nixpkgs_7": { + "nixpkgs_9": { "locked": { "lastModified": 1708343346, "narHash": "sha256-qlzHvterVRzS8fS0ophQpkh0rqw0abijHEOAKm0HmV0=", @@ -2350,37 +2642,6 @@ "type": "github" } }, - "nixpkgs_8": { - "locked": { - "lastModified": 1657693803, - "narHash": "sha256-G++2CJ9u0E7NNTAi9n5G8TdDmGJXcIjkJ3NF8cetQB8=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "365e1b3a859281cf11b94f87231adeabbdd878a2", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-22.05-small", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_9": { - "locked": { - "lastModified": 1718717814, - "narHash": "sha256-xB7AzKY4BP7yypo6g+sk1tnVK54sBIJMeEBB5CdbhT4=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "88af533d8ae8d1e7e4648decf7817ebff91abf56", - "type": "github" - }, - "original": { - "owner": "nixos", - "repo": "nixpkgs", - "type": "github" - } - }, "nosys": { "locked": { "lastModified": 1668010795, @@ -2493,6 +2754,38 @@ "type": "github" } }, + "pre-commit-hooks": { + "inputs": { + "flake-compat": [ + "cachix-push", + "cachix", + "devenv", + "flake-compat" + ], + "flake-utils": "flake-utils", + "gitignore": "gitignore", + "nixpkgs": [ + "cachix-push", + "cachix", + "devenv", + "nixpkgs" + ], + "nixpkgs-stable": "nixpkgs-stable" + }, + "locked": { + "lastModified": 1677160285, + "narHash": "sha256-tBzpCjMP+P3Y3nKLYvdBkXBg3KvTMo3gvi8tLQaqXVY=", + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "rev": "2bd861ab81469428d9c823ef72c4bb08372dd2c4", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "type": "github" + } + }, "process-compose-flake": { "locked": { "lastModified": 1718031437, @@ -2511,6 +2804,7 @@ "root": { "inputs": { "CHaP": "CHaP", + "cachix-push": "cachix-push", "cardano-node": "cardano-node", "flake-parts": "flake-parts", "haskellNix": "haskellNix_2", @@ -2633,7 +2927,7 @@ "blank": "blank", "devshell": "devshell", "dmerge": "dmerge", - "flake-utils": "flake-utils_3", + "flake-utils": "flake-utils_4", "makes": [ "cardano-node", "cardano-automation", @@ -2651,7 +2945,7 @@ ], "n2c": "n2c", "nixago": "nixago", - "nixpkgs": "nixpkgs_3", + "nixpkgs": "nixpkgs_5", "yants": "yants" }, "locked": { @@ -2705,7 +2999,7 @@ "std", "blank" ], - "nixpkgs": "nixpkgs_7", + "nixpkgs": "nixpkgs_9", "paisano": "paisano", "paisano-tui": "paisano-tui", "terranix": [ diff --git a/flake.nix b/flake.nix index 67013a34b38..040945b8c6b 100644 --- a/flake.nix +++ b/flake.nix @@ -22,6 +22,7 @@ cardano-node.url = "github:intersectmbo/cardano-node/9.1.1"; mithril.url = "github:input-output-hk/mithril/2430.0"; nix-npm-buildpackage.url = "github:serokell/nix-npm-buildpackage"; + cachix-push.url = "github:juspay/cachix-push/c8e142cbe5a1e4ebe21bcbc8e8359efd73d18174"; }; outputs = @@ -36,6 +37,7 @@ flake-parts.lib.mkFlake { inherit inputs; } { imports = [ inputs.process-compose-flake.flakeModule + inputs.cachix-push.flakeModule ]; systems = [ "x86_64-linux" @@ -43,7 +45,7 @@ "aarch64-darwin" "aarch64-linux" ]; - perSystem = { pkgs, config, lib, system, ... }: + perSystem = { pkgs, config, lib, system, self', ... }: let compiler = "ghc966"; @@ -170,6 +172,10 @@ devShells = import ./nix/hydra/shell.nix { inherit inputs pkgs hsPkgs system compiler pkgsLatest; }; + + cachix-push = { + cacheName = "cardano-scaling"; + }; }; };