Commit Graph

18 Commits

Author SHA1 Message Date
Derek 85a9c8b669
[sdk] add optional display name and tag fields to project templates ()
<!--- 
Thanks so much for your contribution! If this is your first time
contributing, please ensure that you have read the
[CONTRIBUTING](https://github.com/pulumi/pulumi/blob/master/CONTRIBUTING.md)
documentation.
-->

# Description
Add support for two new fields to a project template block:
* `DisplayName` which is used to store a user friendly template name
* `Tags` which is used to store additional template metadata that is
author-defined (e.g. team, environment, etc.)

This information will be used in the near-term within the console but
longer term could also be used within the CLI.

## Checklist

- [x] I have run `make tidy` to update any new dependencies
- [x] I have run `make lint` to verify my code passes the lint check
- [x] I have formatted my code using `gofumpt`

<!--- Please provide details if the checkbox below is to be left
unchecked. -->
- [ ] I have added tests that prove my fix is effective or that my
feature works

Since this change only adds optional fields I didn't think tests would
be worthwhile. I can add tests if it's thought they would be valuable.
<!--- 
User-facing changes require a CHANGELOG entry.
-->
- [x] I have run `make changelog` and committed the
`changelog/pending/<file>` documenting my change
<!--
If the change(s) in this PR is a modification of an existing call to the
Pulumi Cloud,
then the service should honor older versions of the CLI where this
change would not exist.
You must then bump the API version in
/pkg/backend/httpstate/client/api.go, as well as add
it to the service.
-->
- [ ] Yes, there are changes in this PR that warrants bumping the Pulumi
Cloud API version
<!-- @Pulumi employees: If yes, you must submit corresponding changes in
the service repo. -->
2023-11-18 19:04:13 +00:00
Kyle Dixler a81ad8a2a4
fix : pulumi panics when Pulumi.yaml has a provider with an empty/unspecified `path` key 2023-01-18 10:33:39 -08:00
Zaid Ajaj 88558b271b typing made optional in hierarchical config and relaxed stack config validation 2022-10-30 23:42:39 +01:00
Fraser Waters ea609d546f Add 'secret' to config
Also separate the validation and merging of project-to-stack values, to
allow us to apply in values even if they're secure and we don't have an
available decrypter. We can't validate that they're all correct, but it
means at least `config get` can do a best effort retrival for config
values.
2022-10-24 09:22:24 +01:00
Zaid Ajaj 58de26d7d8 Don't know why the change in the project schema was reverted but here is it: allow config to be string for validation 2022-10-13 20:09:32 +02:00
Zaid Ajaj fb113471c6 No need to rewrite project when validating project schema and refactor test to assert full stackConfigDir error message 2022-10-13 19:52:09 +02:00
Zaid Ajaj 0498be116b Rewrite config to stackConfigDir when provided as string 2022-09-24 14:32:11 +02:00
Zaid Ajaj 969e0e662c project.json should validate short-hand config syntax before rewriting input project 2022-09-24 14:01:35 +02:00
Zaid Ajaj 78ecb2b8fc Merge branch 'master' into minimal-config 2022-09-24 13:50:44 +02:00
Justin Van Patten 23fe012714 Fix regression validating project files with `refresh: always` set
We recently started validating the `Pulumi.yaml` file against its schema, leading to the following error when the `refresh: always` option is specified:

```
error: could not load current project: 1 error occurred:
	* #/options/refresh: expected boolean, but got string
```

The problem is the feature is expecting a string value of `"always"` but the schema for the project file is incorrectly specified as `boolean`.

This change fixes the schema, which avoids the error. A separate change will fix the documentation at https://www.pulumi.com/docs/reference/pulumi-yaml/#options-options
2022-09-22 11:51:54 -07:00
Zaid Ajaj f659376763 Add description to the config type declaration 2022-09-20 23:33:03 +02:00
Zaid Ajaj 6c6b5cec7e Initial work on project-level config (MVP) 2022-09-20 20:13:45 +02:00
Fraser Waters 735314d51a Handle nulls 2022-09-16 16:38:14 +01:00
Fraser Waters e08aafe4d2 Add quickstart and important 2022-09-03 09:06:46 +01:00
Fraser Waters c72d5c0317 Fix template config 2022-09-02 23:28:30 +01:00
Fraser Waters 5ee8937dbb config isn't required 2022-09-02 22:33:28 +01:00
Fraser Waters 80ae4f49f7 Fix backend schema 2022-09-02 19:38:22 +01:00
Fraser Waters 5ff65320e2 Use project schema to validate projects we load 2022-09-02 10:09:24 +01:00