1
0
mirror of https://github.com/rancher/norman.git synced 2025-08-28 03:40:50 +00:00
Commit Graph

735 Commits

Author SHA1 Message Date
Darren Shepherd
4feb41eafa
Merge pull request #403 from takmatsu/fix-lock
Fix doSchema lock issue
2022-01-07 13:39:12 -07:00
Darren Shepherd
3a0171d001
Merge pull request #408 from niusmallnan/force-delete-26
Fix DeleteOption encoding errors for norman api
2022-01-07 13:37:26 -07:00
niusmallnan
47a7b0a1a1 Fix DeleteOption encoding errors for norman api 2021-12-29 13:30:35 +08:00
Sergey Nasovich
abe1797642
Merge pull request #407 from thedadams/stop-ignoring-id-fields 2021-12-01 10:48:50 -05:00
Donnie Adams
eb95d28e82 Stop ignoring id fields for sub-schemas
When generating types, any field with name "id" was being skipped. The intention
here was to skip the "id" field of the embedded types.Resource struct. A type
will have an embedded types.Resource struct when the hasGet function returns
true. Therefore, this hasGet function is also used to skip the id fields as
desired.
2021-11-29 16:19:56 -07:00
Kinara Shah
33e9117898
Merge pull request #406 from annablender/k3s-embedded-etcd
[2.6] Start k3s with embedded etcd
2021-11-03 08:38:32 -07:00
Anna Blendermann
c9509471e5 Start k3s with embedded etcd 2021-11-02 16:20:08 -04:00
Caleb Bron
85ac7aa15a
Merge pull request #402 from paynejacob/fix/list-perf
[2.5.11] Added typer to store
2021-10-29 08:24:48 -07:00
Jacob Payne
b32c167679
added typer to store 2021-10-25 08:50:05 -07:00
MATSUMOTO TAKEAKI
e5b9459adb Fix doSchema lock issue 2021-09-22 14:14:50 +09:00
Dan Ramich
afd06f533c
Merge pull request #401 from snasovich/k8s-1.22-support
Updated to use v1 API for CustomResourceDefinition
2021-07-09 08:53:27 -06:00
Sergey Nasovich
599fa929ab Updated CRDs to v1 API 2021-06-21 16:08:58 -04:00
Darren Shepherd
59b3523c31
Merge pull request #400 from cmurphy/nullablecomplex
Use norman:"pointer" for nullable fields
2021-06-08 13:25:17 -07:00
Colleen Murphy
6e4b2bab93 Add norman field attribute "pointer"
Add a new field attribute "pointer" to indicate that the generated
client code for the field must be a pointer. This allows clients to
differentiate between sending nil/leaving the value unset and sending an
empty map or slice.

This change also removes the `nullablestring` norman type introduced in
30f8d18 since schemas that need a pointer to a string can now use this
field attribute. There are no libraries currently using this feature so
it should be safe to remove.

Example usage:

```
Labels map[string]string `json:"labels" norman:"pointer"`
```

Resulting API schema:

```
"labels": {
  "create": true,
  "nullable": true,
  "pointer": true,
  "type": "map[string]",
  "update": true
}
```

Generated client code:

```
Labels *map[string]string `json:"labels,omitempty" yaml:"labels,omitempty"`
```
2021-06-07 16:33:59 -07:00
Darren Shepherd
e48df26b54
Merge pull request #399 from StrongMonkey/log-to-file
Log k3s server logs to file
2021-05-13 13:47:52 -07:00
Daishan
986dd5b2e4 Log k3s server logs to file 2021-05-13 13:46:56 -07:00
Darren Shepherd
7b74a9f308
Merge pull request #396 from prachidamle/auth_header_fix
Adding impersonate-extra headers to request
2021-05-03 17:53:27 -07:00
Darren Shepherd
1d7f62d3a7
Merge pull request #398 from cmurphy/nullablestring
Add 'nullablestring' field type
2021-05-01 19:45:49 -07:00
Colleen Murphy
30f8d1802b Add 'nullablestring' field type
Currently, `*string` fields in Go structs are converted to `{type:
string, nullable: true}` in the API schema, which is right, but then
converted down to just `string` when converted to generated client
structs. Without this patch, there is no way to express that `*string`s
should stay as `*string`s when run through the generator, because the
'nullable' flag is ignored. Compare this to `*bool`s, which become
`boolean` in the schema and then correctly converted back to *bool in
the generator. This patch adds a backwards-compatible way to opt in to
converting `*string`s in the original struct to *strings in the
generated struct.
2021-05-01 16:24:23 -07:00
Darren Shepherd
8e6ffc77a8
Merge pull request #397 from ibuildthecloud/master
Set x-frame-options to sameorigin
2021-04-22 17:23:17 -07:00
Darren Shepherd
da77031944 Set x-frame-options to sameorigin 2021-04-22 17:08:42 -07:00
Prachi Damle
4f61211d52 Adding impersonate-extra headers 2021-03-15 16:48:29 -07:00
Dan Ramich
c7fd1e2414
Merge pull request #395 from StrongMonkey/self-link-3
Use lower name
2021-02-24 18:09:17 -07:00
Daishan
2ba9d8db33 Use lower name 2021-02-24 17:58:46 -07:00
Darren Shepherd
731b848250
Merge pull request #393 from StrongMonkey/self-link-2
Fix self link
2021-02-19 10:33:27 -08:00
Daishan
505eca07f2 Fix self link 2021-02-19 10:24:53 -07:00
Darren Shepherd
4b01fa8235
Merge pull request #392 from StrongMonkey/fix-self-link
Add self link mapper
2021-02-19 08:07:35 -08:00
Daishan
3a2e391048 Add self link mapper 2021-02-18 20:22:11 -07:00
Darren Shepherd
63e1cb58f0
Merge pull request #389 from ibuildthecloud/master
JSON encode schemas URL passed to html template
2021-02-08 16:17:10 -08:00
Darren Shepherd
c7ba5c4dcd JSON encode schemas URL passed to html template 2021-02-02 15:03:33 -07:00
Darren Shepherd
693d65aaff
Merge pull request #388 from ibuildthecloud/master
Fix local node name to "local-node"
2020-09-29 17:03:40 -07:00
Darren Shepherd
8339c491a8 Fix local node name to "local-node" 2020-09-29 16:44:12 -07:00
Caleb Bron
992a35eef4
Merge pull request #387 from cbron/k3s-coredns-on
Enable coredns in k3s
2020-09-08 13:24:16 -07:00
Caleb Bron
014f4fa394 Enable coredns in k3s
Without this the rancher run docker container
has no DNS server.
2020-09-07 09:37:10 -07:00
Darren Shepherd
6d29ecfde6
Merge pull request #386 from cbron/disable-k3s-agent
k3s disable agent removal
2020-09-02 12:10:10 -07:00
Caleb Bron
0814837e93 k3s disable agent removal 2020-08-31 08:27:30 -07:00
Darren Shepherd
ea785e633e
Merge pull request #385 from ibuildthecloud/master
Don't filter out nil objects
2020-08-26 21:27:22 -07:00
Darren Shepherd
8933f573f8 Don't filter out nil objects 2020-08-26 21:25:00 -07:00
Darren Shepherd
aae987b999
Merge pull request #384 from ibuildthecloud/master
Ensure namespaced scoped listers default to the correct namespace
2020-08-26 18:07:10 -07:00
Darren Shepherd
1f8e5372ca Ensure namespaced scoped listers default to the correct namespace 2020-08-26 17:44:45 -07:00
Darren Shepherd
e3b087c29e
Merge pull request #383 from ibuildthecloud/master
Ensure controller is scoped to namespace
2020-08-26 15:40:31 -07:00
Darren Shepherd
d8c3e21805 Ensure controller is scoped to namespace 2020-08-26 15:33:30 -07:00
Darren Shepherd
c5b2039c29
Merge pull request #381 from ibuildthecloud/master
Set creator field again from norman
2020-08-26 14:02:53 -07:00
Darren Shepherd
9a28dd616d Set creator field again from norman 2020-08-26 13:57:26 -07:00
Darren Shepherd
5fb9a7f204 Update vendor 2020-08-26 13:57:26 -07:00
Darren Shepherd
b715968cde
Merge pull request #382 from rmweir/empty-array-fix
Differentiate between empty and nil arrays
2020-08-20 15:53:44 -07:00
rmweir
5a269325d1 Differentiate between empty and nil arrays
Prior, empty array were converted to nil. In some cases the
difference between a nil and empty array are not arbitrary.
Now, empty arrays will be converted to empty interface arrays
and nil array will be converted to nil interface arrays.
2020-08-20 15:32:34 -07:00
Darren Shepherd
261460ee90
Merge pull request #380 from ibuildthecloud/master
Rename blacklist to skipNames
2020-08-20 10:20:41 -07:00
Darren Shepherd
eb176f062b Rename blacklist to skipNames 2020-08-20 10:17:32 -07:00
Darren Shepherd
a173b50371
Merge pull request #378 from ibuildthecloud/master
Increase timeouts for etcd
2020-08-08 00:01:19 -07:00