Commit Graph

20418 Commits

Author SHA1 Message Date
Mahmood Ali 8beded00b8 ui: Pin ui node version 2020-11-12 08:25:50 -05:00
Michael Lange 9c01bf7530
Merge pull request #9332 from hashicorp/b-ui/flaky-das-filter-tests
UI: Add missing feature fixture that was introduced while DAS filtering was being implemented
2020-11-11 17:04:47 -08:00
Michael Lange 9de4351eae Add missing feature fixture that was introduced while this feature was being developed 2020-11-11 16:43:47 -08:00
Seth Hoenig 0d7942f985
Merge pull request #9330 from hashicorp/b-connect-registration-bad-tags
consul: prevent re-registration churn by correctly comparing connect sidecar tags
2020-11-11 18:22:51 -06:00
Seth Hoenig b19bc6be2b consul: prevent re-registration churn by correctly comparing sidecar tags
Previously, connect sidecars would be re-registered with consul every cycle
of Nomad's reconciliation loop around Consul service registrations. This is
because part of the comparison used `reflect.DeepEqual` on []string objects,
which returns false when one object is `[]string{}` and the other is `[]string{}(nil)`.

Unforunately, this was always the case, and every Connect sidecar service
would be re-registered on every iteration, which happens every 30 seconds.
2020-11-11 18:01:17 -06:00
Mahmood Ali d92d413ffd
Merge pull request #8291 from shishir-a412ed/cpusets
Add cpuset_cpus to docker driver.
2020-11-11 17:13:27 -05:00
Michael Lange 4b32265867
Merge pull request #9294 from hashicorp/f-ui/das-filter-toggle
UI: Add DAS summary table filtering
2020-11-11 14:04:25 -08:00
Chris Baker 611502dd5f
Merge pull request #9327 from hashicorp/b-fix-rec-cli
recs cli: fixed bad composition
2020-11-11 15:54:14 -06:00
Nick Ethier 5e1634eda1
structs: canonicalize allocatedtaskresources to populate shared ports (#9309) 2020-11-11 16:21:47 -05:00
Mahmood Ali a89da9982d
raw_exec: don't use cgroups when no_cgroup is set (#9328)
When raw_exec is configured with [`no_cgroups`](https://www.nomadproject.io/docs/drivers/raw_exec#no_cgroups), raw_exec shouldn't attempt to create a cgroup.

Prior to this change, we accidentally always required freezer cgroup to do stats PID tracking. We already have the proper fallback in place for metrics, so only need to ensure that we don't create a cgroup for the task.

Fixes https://github.com/hashicorp/nomad/issues/8565
2020-11-11 16:20:34 -05:00
Chris Baker bc82312eb4 recs cli: fixed bad composition 2020-11-11 20:52:57 +00:00
Shishir Mahajan 572c398187 Fix review comments. 2020-11-11 12:30:00 -08:00
Shishir Mahajan 9192100d4e Fix circleci. 2020-11-11 12:30:00 -08:00
Shishir Mahajan c30fea5cd3 Add cpuset_cpus to docker driver. 2020-11-11 12:30:00 -08:00
Chris Baker f1d53584bc
Merge pull request #9325 from hashicorp/docs-changelog-9311
changelog addition and fixes
2020-11-11 14:02:00 -06:00
Chris Baker d41d7dcad2 added changelog entry for 9311 and re-ordered changelog entries to respect secondary short-to-long ordering 2020-11-11 19:59:10 +00:00
Chris Baker 48b1674335
Merge pull request #9311 from jeromegn/allow-empty-devices
Don't ignore nil devices in plugin fingerprint
2020-11-11 13:54:03 -06:00
Tim Gross 60874ebe25
csi: Postrun hook should not change mode (#9323)
The unpublish workflow requires that we know the mode (RW vs RO) if we want to
unpublish the node. Update the hook and the Unpublish RPC so that we mark the
claim for release in a new state but leave the mode alone. This fixes a bug
where RO claims were failing node unpublish.

The core job GC doesn't know the mode, but we don't need it for that workflow,
so add a mode specifically for GC; the volumewatcher uses this as a sentinel
to check whether claims (with their specific RW vs RO modes) need to be claimed.
2020-11-11 13:06:30 -05:00
Chris Baker fbe3670b74
Merge pull request #9317 from hashicorp/f-recommendations-cli-autocomplete
recommendations CLI: autocomplete support
2020-11-11 12:04:23 -06:00
Chris Baker 26469093cd
Merge pull request #9312 from hashicorp/b-9227-scaling-policy-filtering
use both job and type query on scaling policy list endpoint
2020-11-11 12:04:06 -06:00
Tim Gross 0ef0b17b82
docker: disallow volume mounts from host by default (#9321)
The default behavior for `docker.volumes.enabled` is intended to be `false`,
but the HCL schema defaults to `true` if the value is unset. Set the default
literal value to `true`.

Additionally, Docker driver mounts of type "volume" (but not "bind") are not
being properly sandboxed with that setting. Disable Docker mounts with type
"volume" entirely whenever the `docker.volumes.enabled` flag is set to
false. Note this is unrelated to the `volume_mount` feature, which is
constrained to preconfigured host volumes or whatever is mounted by a CSI
plugin.

This changeset includes updates to unit tests that should have been failing
under the documented behavior but were not.
2020-11-11 10:03:46 -05:00
Chris Baker 4fc913eb8c
Merge branch 'master' into b-9227-scaling-policy-filtering 2020-11-11 07:50:01 -06:00
Drew Bailey 9a1fc720c8
enables audit log on full-cluster (#9315) 2020-11-11 08:33:01 -05:00
Drew Bailey 11a0dc87ed
changelog for enterprise bug (#9320) 2020-11-11 08:32:16 -05:00
Chris Baker d297083d6b changelog 2020-11-11 11:57:04 +00:00
Chris Baker 2deb77dcf5 cli: updated recommendation commands and test to remove duplication of autocompletion code 2020-11-11 11:39:26 +00:00
Chris Baker e3c0ea654d auto-complete for recommendations CLI, plus OSS components of recommendations prefix search 2020-11-11 11:13:43 +00:00
Mahmood Ali cb35c2583e
Merge pull request #9310 from hashicorp/f-warn-against-hcl2
Custom message when job file is HCL2 incompatible
2020-11-10 21:06:10 -05:00
Chris Baker 53aa5e75c9 fix #9227: use both job and type query on scaling policy list endpoint 2020-11-10 23:26:35 +00:00
Jerome Gravel-Niquet d1f1dbd203
Don't ignore nil devices in plugin fingerprint
Even if a plugin sends back an empty `[]*device.DeviceGroup`, it's transformed to `nil` during the RPC. Our custom device plugin is returning empty `FingerprintResponse.Devices` very often. Our temporary fix is to send a dummy `*DeviceGroup` if the slice is empty. This has the effect of never triggering the "first fingerprint" and therefore timing out after 50s.

In turn, this made our node exceed its hearbeat grace period when restarting it, revoking all vault tokens for its allocations, causing a restart of all our allocations because the token couldn't be renewed.

Removing the logic for `f.Devices == nil` does not appear to affect the functionality of the function.
2020-11-10 16:04:22 -05:00
Mahmood Ali f61d284fe6 Custom message when job file is HCL2 incompatible
Use a custom message when the job file is a valid HCL1 but no longer
valid under HCL 2 syntax.
2020-11-10 14:56:20 -05:00
Buck Doyle ba5e6983bb Move page object component to reflect page order 2020-11-10 13:42:15 -06:00
Buck Doyle e5089dec44 Remove unnecessary uses of createList 2020-11-10 13:38:27 -06:00
Michael Schurter 49c92433af
Merge pull request #9305 from hashicorp/go-1.15.4
go: update from 1.15.1 to 1.15.4
2020-11-10 10:34:43 -08:00
Mahmood Ali 2d4634bcc3
Merge pull request #9304 from hashicorp/b-legacy-executors-are-executors
Legacy executors are executors after all
2020-11-10 12:54:03 -05:00
Mahmood Ali cac55f8991 update changelog
[ci skip]
2020-11-10 12:50:34 -05:00
Kris Hicks 9d03cf4c5f
protos: Update .proto files not to use Go package name (#9301)
Previously, it was required that you `go get github.com/hashicorp/nomad` to be
able to build protos, as the protoc invocation added an include directive that
pointed to `$GOPATH/src`, which is how dependent protos were discovered. As
Nomad now uses Go modules, it won't necessarily be cloned to `$GOPATH`.
(Additionally, if you _had_ go-gotten Nomad at some point, protoc compilation
would have possibly used the _wrong_ protos, as those wouldn't necessarily be
the most up-to-date ones.)

This change modifies the proto files and the `protoc` invocation to handle
discovering dependent protos via protoc plugin modifier statements that are
specific to the protoc plugin being used.

In this change, `make proto` was run to recompile the protos, which results in
changes only to the gzipped `FileDescriptorProto`.
2020-11-10 08:42:35 -08:00
Michael Schurter 1a4fe89866 docs: add go upgrade to changelog 2020-11-10 08:38:05 -08:00
Michael Schurter 447ec6389e go: update from 1.15.1 to 1.15.4
1.15.5 is due in a couple days but we may release before then.
2020-11-10 08:35:25 -08:00
Buck Doyle 508adbf0ac Remove unused action
This is a remnant of another approach I tried when rerouting
/optimize when the filter excluded all summaries.
2020-11-10 10:07:48 -06:00
Buck Doyle 3ef7f9f89e Add redirect to parent when filter excludes all 2020-11-10 09:38:46 -06:00
Mahmood Ali ac185b41e2 Legacy executors are executors after all
This fixes a bug where pre-0.9 executors fail to recover after an
upgrade.

The bug is that legacyExecutorWrappers didn't get updated with
ExecStreaming function, and thus failed to implement the Executor
function. Sadly, this meant that all recovery attempts fail, as the
runtime check in
b312aacbc9/drivers/shared/executor/utils.go (L103-L110)
.
2020-11-10 10:20:07 -05:00
Ryan Oaks a6ad204878 Remove Netlify config 2020-11-10 09:57:14 -05:00
Seth Hoenig 7427da2a41
Merge pull request #9299 from hashicorp/b-detect-unloaded-kmod
client/fingerprint: detect unloaded dynamic bridge kernel module
2020-11-10 08:24:28 -06:00
Mahmood Ali 69849a42a5
Merge pull request #9298 from hashicorp/f-hcl2-localsvars
HCL2: Variables and Locals
2020-11-09 16:44:37 -05:00
Mahmood Ali 61650167bf use a constructor to initialize job config 2020-11-09 16:27:22 -05:00
Mahmood Ali 2e5ce5aa96 clarify test 2020-11-09 16:24:22 -05:00
Mahmood Ali a155423ba3 clarify variable references 2020-11-09 16:23:09 -05:00
Buck Doyle 7ed1f4dda8 Fix proceed to use filtered summaries 2020-11-09 15:00:58 -06:00
Luiz Aoqui f82abfb0fc
Merge pull request #9300 from hashicorp/changelog-for-job-scale-bug
add CHANGELOG entry for #9296
2020-11-09 15:49:05 -05:00