Skip to content

Commit

Permalink
Merge branch 'rewrite_backend_rust' into module-refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
Centeno448 committed Aug 16, 2024
2 parents 0b1180f + 9c097e0 commit c4f83b3
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 50 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ jobs:
- name: Install devenv.sh
run: nix profile install tarball+https://install.devenv.sh/latest
shell: sh
- run: devenv ci
- run: devenv test
- name: Deploy staging
if: github.event_name == 'push' && github.ref == 'refs/heads/main' && matrix.os == 'ubuntu-latest'
env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
run: devenv shell deploy-${{ inputs.env || 'staging' }}
run: devenv shell deploy-${{ inputs.env || 'staging' }}
76 changes: 30 additions & 46 deletions devenv.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"devenv": {
"locked": {
"dir": "src/modules",
"lastModified": 1697058441,
"narHash": "sha256-gjtW+nkM9suMsjyid63HPmt6WZQEvuVqA5cOAf4lLM0=",
"lastModified": 1723487333,
"owner": "cachix",
"repo": "devenv",
"rev": "55294461a62d90c8626feca22f52b0d3d0e18e39",
"rev": "b285601679c7686f623791ad93a8e0debc322633",
"treeHash": "724e2581d01b2775202a61459cc6e63abbf56063",
"type": "github"
},
"original": {
Expand Down Expand Up @@ -42,11 +42,11 @@
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1673956053,
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
"lastModified": 1696426674,
"owner": "edolstra",
"repo": "flake-compat",
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"treeHash": "2addb7b71a20a25ea74feeaf5c2f6a6b30898ecb",
"type": "github"
},
"original": {
Expand All @@ -56,30 +56,15 @@
}
},
"flake-utils": {
"locked": {
"lastModified": 1653893745,
"narHash": "sha256-0jntwV3Z8//YwuOjzhV2sgJJPt+HY6KhU7VZUL0fKZQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "1ed9fb1935d260de5fe1c2f7ee0ebaae17ed2fa1",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_2": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1685518550,
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
"lastModified": 1710146030,
"owner": "numtide",
"repo": "flake-utils",
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"treeHash": "bd263f021e345cb4a39d80c126ab650bebc3c10c",
"type": "github"
},
"original": {
Expand All @@ -96,11 +81,11 @@
]
},
"locked": {
"lastModified": 1660459072,
"narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=",
"lastModified": 1709087332,
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "a20de23b925fd8264fd7fad6454652e142fd7f73",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"treeHash": "ca14199cabdfe1a06a7b1654c76ed49100a689f9",
"type": "github"
},
"original": {
Expand All @@ -112,10 +97,10 @@
"mk-shell-bin": {
"locked": {
"lastModified": 1677004959,
"narHash": "sha256-/uEkr1UkJrh11vD02aqufCxtbF5YnhRTIKlx5kyvf+I=",
"owner": "rrbutani",
"repo": "nix-mk-shell-bin",
"rev": "ff5d8bd4d68a347be5042e2f16caee391cd75887",
"treeHash": "496327dabdc787353a29987f492dd4939151baad",
"type": "github"
},
"original": {
Expand All @@ -132,11 +117,11 @@
]
},
"locked": {
"lastModified": 1688922987,
"narHash": "sha256-RnQwrCD5anqWfyDAVbfFIeU+Ha6cwt5QcIwIkaGRzQw=",
"lastModified": 1720642556,
"owner": "nlewo",
"repo": "nix2container",
"rev": "ab381a7d714ebf96a83882264245dbd34f0a7ec8",
"rev": "3853e5caf9ad24103b13aa6e0e8bcebb47649fe4",
"treeHash": "a9c2f1d3f52f288515ca0fb11f9aed970fd869b6",
"type": "github"
},
"original": {
Expand All @@ -147,11 +132,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1697456312,
"narHash": "sha256-roiSnrqb5r+ehnKCauPLugoU8S36KgmWraHgRqVYndo=",
"lastModified": 1723362943,
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "ca012a02bf8327be9e488546faecae5e05d7d749",
"rev": "a58bc8ad779655e790115244571758e8de055e3d",
"treeHash": "be7a43ec1566a532b10631546c9dbe99fc899276",
"type": "github"
},
"original": {
Expand All @@ -163,36 +148,35 @@
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1685801374,
"narHash": "sha256-otaSUoFEMM+LjBI1XL/xGB5ao6IwnZOXc47qhIgJe8U=",
"lastModified": 1723556749,
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c37ca420157f4abc31e26f436c1145f8951ff373",
"rev": "4a92571f9207810b559c9eac203d1f4d79830073",
"treeHash": "e3518a5882da387efc1f99184797844a9952ecd0",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-23.05",
"ref": "nixos-24.05",
"repo": "nixpkgs",
"type": "github"
}
},
"pre-commit-hooks": {
"inputs": {
"flake-compat": "flake-compat",
"flake-utils": "flake-utils_2",
"gitignore": "gitignore",
"nixpkgs": [
"nixpkgs"
],
"nixpkgs-stable": "nixpkgs-stable"
},
"locked": {
"lastModified": 1692274144,
"narHash": "sha256-BxTQuRUANQ81u8DJznQyPmRsg63t4Yc+0kcyq6OLz8s=",
"lastModified": 1723202784,
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "7e3517c03d46159fdbf8c0e5c97f82d5d4b0c8fa",
"rev": "c7012d0c18567c889b948781bc74a501e92275d1",
"treeHash": "0016d5d748d61d3bfaa69d3c02abff74740a46b7",
"type": "github"
},
"original": {
Expand All @@ -214,11 +198,11 @@
"rust-analyzer-src": {
"flake": false,
"locked": {
"lastModified": 1713628977,
"lastModified": 1723648323,
"owner": "rust-lang",
"repo": "rust-analyzer",
"rev": "55d9a533b309119c8acd13061581b43ae8840823",
"treeHash": "435e9c646978f38b8389e483b4d4fb15ba932cad",
"rev": "64a140527b383e3a2fe95908881624fc5374c60c",
"treeHash": "be4bc75a65ed2d344fd9f3b5cf00bcb48c54a2a5",
"type": "github"
},
"original": {
Expand All @@ -231,10 +215,10 @@
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"treeHash": "cce81f2a0f0743b2eb61bc2eb6c7adbe2f2c6beb",
"type": "github"
},
"original": {
Expand Down
11 changes: 9 additions & 2 deletions devenv.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,12 @@ in
packages = [
pkgs.postgresql
pkgs.gnused
pkgs.openssl
] ++ lib.optionals (!config.container.isBuilding) [
pkgs.flyctl
pkgs.cloudflared
pkgs.openapi-generator-cli
pkgs.nodePackages.pyright
pkgs.pyright
] ++ lib.optionals pkgs.stdenv.isDarwin [
pkgs.darwin.CF
pkgs.darwin.Security
Expand Down Expand Up @@ -97,13 +98,19 @@ in
export PATH="${config.devenv.root}/node_modules/.bin:$PATH"
'';

enterTest = ''
pushd backend-rs
cargo build
popd
'';

scripts.fetch-openapi-templates.exec =
let
openApiSrc = pkgs.fetchFromGitHub {
owner = "OpenAPITools";
repo = "openapi-generator";
rev = "v${pkgs.openapi-generator-cli.version}";
hash = "sha256-nAc/iU31ccNoZAQdrdAnBtNPBTgCStDpiqrC1DC4d6E=";
hash = "sha256-J3ukIIH4k6VsCF+FqUEaLcEeVrQcSfFeJrmAO8buhGw=";
};
in
''
Expand Down

0 comments on commit c4f83b3

Please sign in to comment.