From 85faa13ec230c4e58b6dfbd6f98ca56a0ace2e6e Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Thu, 13 Jul 2023 15:38:06 -0700 Subject: [PATCH 1/3] Add Pulumi template --- .envrc | 2 +- flake.nix | 5 +++++ pulumi/.envrc | 1 + pulumi/flake.lock | 27 +++++++++++++++++++++++++++ pulumi/flake.nix | 25 +++++++++++++++++++++++++ 5 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 pulumi/.envrc create mode 100644 pulumi/flake.lock create mode 100644 pulumi/flake.nix diff --git a/.envrc b/.envrc index a5dbbcb..3550a30 100644 --- a/.envrc +++ b/.envrc @@ -1 +1 @@ -use flake . +use flake diff --git a/flake.nix b/flake.nix index 0dc45a1..b020b16 100644 --- a/flake.nix +++ b/flake.nix @@ -110,6 +110,11 @@ description = "Protobuf development environment"; }; + pulumi = { + path = ./pulumi; + description = "Pulumi development environment"; + }; + purescript = { path = ./purescript; description = "Purescript development environment"; diff --git a/pulumi/.envrc b/pulumi/.envrc new file mode 100644 index 0000000..3550a30 --- /dev/null +++ b/pulumi/.envrc @@ -0,0 +1 @@ +use flake diff --git a/pulumi/flake.lock b/pulumi/flake.lock new file mode 100644 index 0000000..0f56f8b --- /dev/null +++ b/pulumi/flake.lock @@ -0,0 +1,27 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/pulumi/flake.nix b/pulumi/flake.nix new file mode 100644 index 0000000..f414307 --- /dev/null +++ b/pulumi/flake.nix @@ -0,0 +1,25 @@ +{ + description = "A Nix-flake-based Pulumi development environment"; + + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; + + outputs = { self, nixpkgs }: + let + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); + in + { + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ + pulumi-bin + python311 + kubectl + jq + ]; + }; + }); + }; +} From 56f9dbc255c2f7c4dc2f933aeb6b3cac7049aa90 Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Thu, 13 Jul 2023 15:45:24 -0700 Subject: [PATCH 2/3] Support current SDKs --- pulumi/flake.nix | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/pulumi/flake.nix b/pulumi/flake.nix index f414307..68c4c26 100644 --- a/pulumi/flake.nix +++ b/pulumi/flake.nix @@ -14,9 +14,33 @@ devShells = forEachSupportedSystem ({ pkgs }: { default = pkgs.mkShell { packages = with pkgs; [ + # Pulumi plus: + # pulumi-watch + # pulumi-analyzer-* utilities + # pulumi-language-* utilities + # pulumi-resource-* utilities pulumi-bin + + # Python SDK python311 + + # Go SDK + go_1_20 + + # Node.js SDK + nodejs + + # .NET SDK + dotnet-sdk_6 + + # Java SDK + jdk + maven + + # Kubernetes kubectl + + # Miscellaneous utilities jq ]; }; From ddb95bfb29978b0c33d927ddbdaa34a8ea21f32c Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Thu, 13 Jul 2023 15:53:11 -0700 Subject: [PATCH 3/3] Update README to include new template --- README.md | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 170f117..081d4a1 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ Once your preferred template has been initialized, you can use the provided shel | [Hashicorp] tools | [`hashi`](./hashi/) | | [Java] | [`java`](./java/) | | [Kotlin] | [`kotlin`](./kotlin/) | -| [LaTeX] | [`latex`](./latex/) | +| [LaTeX] | [`latex`](./latex/) | | [Nickel] | [`nickel`](./nickel/) | | [Nim] | [`nim`](./nim/) | | [Nix] | [`nix`](./nix/) | @@ -51,6 +51,7 @@ Once your preferred template has been initialized, you can use the provided shel | [Open Policy Agent][opa] | [`opa`](./opa) | | [PHP] | [`php`](./php/) | | [Protobuf] | [`protobuf`](./protobuf/) | +| [Pulumi] | [`pulumi`](./pulumi/) | | [Purescript] | [`purescript`](./purescript/) | | [Ruby] | [`ruby`](./ruby/) | | [Rust] | [`rust`](./rust/) | @@ -200,6 +201,16 @@ The sections below list what each template includes. In all cases, you're free t - The [Buf CLI][buf] 1.7.0 - [protoc][protobuf] 3.19.4 +### [`pulumi`](./pulumi/) + +- [Pulumi] 3.72.1 +- [Python] 3.11.4 +- [Go] 1.20.5 +- [Node.js][node] 18.16.1 +- [dotnet] sdk 6 +- [Java] 19.0.1 and [Maven] 3.9.2 +- [jq] 1.6 + ### [`purescript`](./purescript/) - [Purescript] @@ -294,6 +305,7 @@ All of the templates have only the root [flake](./flake.nix) as a flake input. T [haskell]: https://haskell.org [iex]: https://hexdocs.pm/iex/IEx.html [java]: https://java.com +[jq]: https://jqlang.github.io/jq [kotlin]: https://kotlinlang.org [latex]: https://www.latex-project.org/ [leiningen]: https://leiningen.org @@ -330,7 +342,8 @@ All of the templates have only the root [flake](./flake.nix) as a flake input. T [php]: https://php.net/ [pnpm]: https://pnpm.io [protobuf]: https://developers.google.com/protocol-buffers -[Purescript]: https://github.com/purescript/purescript +[pulumi]: https://pulumi.com/ +[purescript]: https://github.com/purescript/purescript [purescript-language-server]: https://github.com/nwolverson/purescript-language-server [purs-tidy]: https://github.com/natefaubion/purescript-tidy [python]: https://python.org