Merge pull request #23 from the-nix-way/pulumi-template

Add Pulumi template
This commit is contained in:
Luc Perkins 2023-07-14 08:43:38 -07:00 committed by GitHub
commit cf33f63acc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 97 additions and 2 deletions

View file

@ -49,6 +49,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/) |
@ -194,6 +195,16 @@ The sections below list what each template includes. In all cases, you're free t
- The [Buf CLI][buf] 1.23.1
- [protoc][protobuf] 3.21.12
### [`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] (purs) 0.15.9
@ -282,6 +293,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
@ -316,7 +328,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

View file

@ -161,6 +161,11 @@
description = "Protobuf development environment";
};
pulumi = {
path = ./pulumi;
description = "Pulumi development environment";
};
purescript = {
path = ./purescript;
description = "Purescript development environment";

1
pulumi/.envrc Normal file
View file

@ -0,0 +1 @@
use flake

27
pulumi/flake.lock Normal file
View file

@ -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
}

49
pulumi/flake.nix Normal file
View file

@ -0,0 +1,49 @@
{
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 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
];
};
});
};
}