Commit Graph

1539 Commits

Author SHA1 Message Date
Drew Bailey 6f97cbfc93
changelog entry for on_update configuration settings (#10299)
* changelog entry for on_update configuration settings

* Update CHANGELOG.md

Co-authored-by: Tim Gross <tgross@hashicorp.com>

Co-authored-by: Tim Gross <tgross@hashicorp.com>
2021-04-05 11:04:03 -04:00
Drew Bailey 4f378b7f41
license changelog (#10298) 2021-04-05 10:57:20 -04:00
Chris Baker 436d46bd19
Merge branch 'main' into f-node-drain-api 2021-04-01 15:22:57 -05:00
Tim Gross 4d30e1ce1a changelog: add section for backports from 1.1.0 to 1.0.5
* Fixed order
* Added missing changlog entry for GH-10145
* Fixed misclassified entry for GH-10158
2021-03-30 15:53:17 -04:00
Seth Hoenig 03ed2a8035
Merge pull request #10243 from apollo13/issue10239
Automatically populate `CONSUL_HTTP_ADDR` for connect native tasks in host networking mode.
2021-03-30 09:00:17 -05:00
Dave May ba4da7efca
debug: Remove extra linefeed in monitor.log (#10252) 2021-03-29 09:22:27 -04:00
Florian Apolloner b9b71e7ac5 Automatically populate `CONSUL_HTTP_ADDR` for connect native tasks in host networking mode. Fixes #10239 2021-03-28 14:34:31 +02:00
Chris Baker 0c590476fd t push
changelog for #10202
2021-03-23 20:33:56 +00:00
Mahmood Ali 24d7395bfc
Update changelog with v0.12.11 (#10214) 2021-03-23 08:28:44 -04:00
Tim Gross fa25e048b2
CSI: unique volume per allocation
Add a `PerAlloc` field to volume requests that directs the scheduler to test
feasibility for volumes with a source ID that includes the allocation index
suffix (ex. `[0]`), rather than the exact source ID.

Read the `PerAlloc` field when making the volume claim at the client to
determine if the allocation index suffix (ex. `[0]`) should be added to the
volume source ID.
2021-03-18 15:35:11 -04:00
Tim Gross 9b2b580d1a
CSI: remove prefix matching from CSIVolumeByID and fix CLI prefix matching (#10158)
Callers of `CSIVolumeByID` are generally assuming they should receive a single
volume. This potentially results in feasibility checking being performed
against the wrong volume if a volume's ID is a prefix substring of other
volume (for example: "test" and "testing").

Removing the incorrect prefix matching from `CSIVolumeByID` breaks prefix
matching in the command line client. Add the required elements for prefix
matching to the commands and API.
2021-03-18 14:32:40 -04:00
davemay99 76bb4351a6 CHANGELOG: Add missing 0.12.10 version 2021-03-15 08:35:03 -04:00
Florian Apolloner a0873d5da4
docker: support configuring default log driver in plugin options 2021-03-12 16:04:33 -05:00
Tim Gross 0e3264aa4f scheduler/csi: fix early return when multiple volumes are requested
When multiple CSI volumes are requested, the feasibility check could return
early for read/write volumes with free claims, even if a later volume in the
request was not feasible for any other reason (including not existing at
all). This can result in random failure to fail feasibility checking,
depending on how the map of volumes was being ordered at runtime.

Remove the early return from the feasibility check. Add a test to verify that
missing volumes in the map will cause a failure; this test will not catch a
regression every test run because of the random map ordering, but any failure
will be caught over the course of several CI runs.
2021-03-10 15:18:36 -05:00
James Rasell e9d81ace7b
Merge pull request #10140 from hashicorp/b-gh-10070
agent: return req error if prometheus metrics are disabled.
2021-03-10 17:11:39 +01:00
Tim Gross 2f343370fb changelog: fix position of entry 2021-03-09 10:47:13 -05:00
James Rasell f68cf1dfef
changelog: add entry for #10140 2021-03-09 15:29:25 +01:00
Dave May e93b49a119
debug: update defaults to commonly used values 2021-03-09 08:31:38 -05:00
Michael Schurter 15e3d61e59 client: fix task name logging 2021-03-08 09:15:02 -08:00
Tim Gross d983d79ec2 docs: changelog entry for extra docker labels 2021-03-08 09:06:53 -05:00
Buck Doyle 523d868f4c
Fix rendering of DAS interstitial components (#10094)
With the Ember update, when the will-destroy action is called
to check the element height, its height is already zero. That
seems strange but I didn’t look into it any further, as
using did-insert to store the element lets us check its height
before any other actions when a processing button is pressed.
2021-03-01 09:46:22 -06:00
Andre Ilhicas 30c840e88e
consul/connect: enable setting local_bind_address in upstream 2021-02-26 11:47:00 +00:00
Dave May cd506cb887
Handle Consul API URL protocol mismatch (#10082) 2021-02-25 08:22:44 -05:00
Seth Hoenig 194dc9ff4a docs: add two community PRs to changelog 2021-02-24 10:21:34 -06:00
Tim Gross 800c46de96 post-1.0.4 release prep 2021-02-24 09:56:53 -05:00
Seth Hoenig 24a1238e48
Merge pull request #10080 from hashicorp/b-gw-updated
consul/connect: correctly detect when connect tasks not updated
2021-02-23 15:28:53 -06:00
Seth Hoenig 4f759f1cc8 consul/connect: correctly detect when connect tasks not updated
This PR fixes a bug where tasks with Connect services could be
triggered to destructively update (i.e. placed in a new alloc)
when no update should be necessary.

Fixes #10077
2021-02-23 15:12:49 -06:00
Tim Gross 3352801ba7 changelog: fix link for GH-9937 2021-02-23 16:04:14 -05:00
Michael Lange 3f7d1b72b8 CHANGELOG entries for some 1.0.4 UI bug fixes 2021-02-23 09:45:15 -08:00
Tim Gross b764f52ab9
deploymentwatcher: reset progress deadline on promotion (#10042)
In a deployment with two groups (ex. A and B), if group A's canary becomes
healthy before group B's, the deadline for the overall deployment will be set
to that of group A. When the deployment is promoted, if group A is done it
will not contribute to the next deadline cutoff. Group B's old deadline will
be used instead, which will be in the past and immediately trigger a
deployment progress failure. Reset the progress deadline when the job is
promotion to avoid this bug, and to better conform with implicit user
expectations around how the progress deadline should interact with promotions.
2021-02-22 16:44:03 -05:00
Seth Hoenig d557d6bf94 consul/connect: Fix bug where connect sidecar services would be unnecessarily re-registered
This PR fixes a bug where sidecar services would be re-registered into Consul every ~30
seconds, caused by the parent service having its tags field set and the sidecar_service
tags unset. Nomad would directly compare the tags between its copy of the sidecar service
definition and the tags of the sidecar service reported by Consul. This does not work,
because Consul will under-the-hood set the sidecar service tags to inherit the parent
service tags if the sidecar service tags are unset. The comparison then done by Nomad
would not match, if the parent sidecar tags are set.

Fixes #10025
2021-02-22 12:02:58 -06:00
Buck Doyle ee564ff1ca
changelog: add entries for 1.0.4 (#10048) 2021-02-18 11:58:38 -06:00
Tim Gross a527d5f897 changelog: missing changelog items for 1.0.4 2021-02-18 11:35:42 -05:00
Drew Bailey b09655a8e3
update changelog (#10034)
* update changelog

* fix changelog order
2021-02-16 12:50:08 -05:00
Nick Ethier fcc1f4c805
Merge pull request #9946 from hashicorp/b-9477
structs: namespace port validation by host_network
2021-02-11 12:53:28 -05:00
Seth Hoenig 7d6e81e9e4
Merge pull request #9990 from hashicorp/f-nsiso-task
drivers/exec+java: Add task configuration to restore previous PID/IPC isolation behavior
2021-02-09 13:29:14 -06:00
Seth Hoenig 6d30783679 docs: fix egregious changelog ordering 2021-02-09 12:33:03 -06:00
Seth Hoenig 45e0e70a50 consul/connect: enable custom sidecars to use expose checks
This PR enables jobs configured with a custom sidecar_task to make
use of the `service.expose` feature for creating checks on services
in the service mesh. Before we would check that sidecar_task had not
been set (indicating that something other than envoy may be in use,
which would not support envoy's expose feature). However Consul has
not added support for anything other than envoy and probably never
will, so having the restriction in place seems like an unnecessary
hindrance. If Consul ever does support something other than Envoy,
they will likely find a way to provide the expose feature anyway.

Fixes #9854
2021-02-09 10:49:37 -06:00
Seth Hoenig 8ee9835923 drivers/exec+java: Add task configuration to restore previous PID/IPC isolation behavior
This PR adds pid_mode and ipc_mode options to the exec and java task
driver config options. By default these will defer to the default_pid_mode
and default_ipc_mode agent plugin options created in #9969. Setting
these values to "host" mode disables isolation for the task. Doing so
is not recommended, but may be necessary to support legacy job configurations.

Closes #9970
2021-02-08 14:26:35 -06:00
Nick Ethier b0a49ff37a
Update CHANGELOG.md 2021-02-08 14:14:39 -05:00
Seth Hoenig 4bc6e5a215 drivers/exec+java: Add configuration to restore previous PID/IPC namespace behavior.
This PR adds default_pid_mode and default_ipc_mode options to the exec and java
task drivers. By default these will default to "private" mode, enabling PID and
IPC isolation for tasks. Setting them to "host" mode disables isolation. Doing
so is not recommended, but may be necessary to support legacy job configurations.

Closes #9969
2021-02-05 15:52:11 -06:00
Nick Ethier eacc4da499
Merge branch 'master' into b-9477 2021-02-05 11:58:13 -05:00
Tim Gross eb3dd17fb2 volumes: implement plan diff for volume requests
The details of host volume and CSI volume requests do not show up in `nomad
plan` outputs, although the updates are detected by the scheduler and result
in an update as expected.
2021-02-04 16:55:17 -05:00
Chris Baker 3c6a3ba63d
Merge pull request #9964 from hashicorp/f-9787-alloc-prefix-cli
add prefix-search and auto-completion for `scaling policy info` command
2021-02-04 10:00:57 -06:00
Chris Baker cbc1506478 changelog for 9964 2021-02-04 15:11:00 +00:00
Nick Ethier 05ea452d2c add changelog item 2021-02-02 23:00:03 -05:00
Nick Ethier 978107ba8d update CHANGELOG 2021-02-02 15:36:31 -05:00
Tim Gross b32cb563cd changelog: add issue link for quota enforcement change 2021-02-02 10:31:55 -05:00
Tim Gross 76d880bbda docs: add changelog entry for removing mbits from quotas 2021-02-02 10:10:44 -05:00
Chris Baker ce68ee164b Version 1.0.3
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQEcBAABAgAGBQJgEuOKAAoJEFGFLYc0j/xMxF8H/3TTU6Tu+Xm0YvcsDaYDphZ/
 X7KQBV0aFiuL5VkTw4PzKEsgryIy9/sqEPyxxyKRowAmos9qhiusjNAIfqdP4TF8
 tdZmTedkfWir9uPD+hyv/LXpwbQ2T8kTwS3xHTYvaOmaCxZr710FEn+imnMk1AUn
 Xs5itkd/CYGr0nBLm+I5GutWSDPmL7Uw8J5Z30fFyoaxoCPAbCWQQNk793SCRUc5
 f/uo18V2tFInmQ+3sAdnM4gPewyStK/a5VvzWavL9fVDtYK83wlqWSchTXY5jpVz
 zNEzt/rYhbBzakPQQKb5zieblh2iGI8aHWpD5w4WduqO2Sg6B/5lAeNZIlW0UJg=
 =2g3c
 -----END PGP SIGNATURE-----

Merge tag 'v1.0.3' into post-release-1.0.3

Version 1.0.3
2021-01-29 19:30:08 +00:00
Chris Baker 8806294cd9 updated changelog for release 2021-01-28 14:46:57 +00:00
Seth Hoenig 8b05efcf88 consul/connect: Add support for Connect terminating gateways
This PR implements Nomad built-in support for running Consul Connect
terminating gateways. Such a gateway can be used by services running
inside the service mesh to access "legacy" services running outside
the service mesh while still making use of Consul's service identity
based networking and ACL policies.

https://www.consul.io/docs/connect/gateways/terminating-gateway

These gateways are declared as part of a task group level service
definition within the connect stanza.

service {
  connect {
    gateway {
      proxy {
        // envoy proxy configuration
      }
      terminating {
        // terminating-gateway configuration entry
      }
    }
  }
}

Currently Envoy is the only supported gateway implementation in
Consul. The gateay task can be customized by configuring the
connect.sidecar_task block.

When the gateway.terminating field is set, Nomad will write/update
the Configuration Entry into Consul on job submission. Because CEs
are global in scope and there may be more than one Nomad cluster
communicating with Consul, there is an assumption that any terminating
gateway defined in Nomad for a particular service will be the same
among Nomad clusters.

Gateways require Consul 1.8.0+, checked by a node constraint.

Closes #9445
2021-01-25 10:36:04 -06:00
Tim Gross 45a45ebb3f changelog entry 2021-01-22 13:41:28 -05:00
Tim Gross 64449cddc1 implement alloc runner task restart hook
Most allocation hooks don't need to know when a single task within the
allocation is restarted. The check watcher for group services triggers the
alloc runner to restart all tasks, but the alloc runner's `Restart` method
doesn't trigger any of the alloc hooks, including the group service hook. The
result is that after the first time a check triggers a restart, we'll never
restart the tasks of an allocation again.

This commit adds a `RunnerTaskRestartHook` interface so that alloc runner
hooks can act if a task within the alloc is restarted. The only implementation
is in the group service hook, which will force a re-registration of the
alloc's services and fix check restarts.
2021-01-22 10:55:40 -05:00
Drew Bailey bae0c6cd20
changelog entry for 9768 (#9873) 2021-01-22 09:22:02 -05:00
Charlie Voiselle 4f4d6e6c37
Enable network namespaces for QEMU driver (#9861)
* Enable network namespaces for QEMU driver
* Add CHANGELOG entry
2021-01-21 14:05:46 -05:00
Drew Bailey 3099eb0c73
fix changelog date (#9862) 2021-01-20 13:14:21 -05:00
Seth Hoenig 53218716b3
docs: fix typo in changelog
Co-authored-by: Tim Gross <tgross@hashicorp.com>
2021-01-20 09:50:59 -06:00
Seth Hoenig 991884e715 consul/connect: Enable running multiple ingress gateways per Nomad agent
Connect ingress gateway services were being registered into Consul without
an explicit deterministic service ID. Consul would generate one automatically,
but then Nomad would have no way to register a second gateway on the same agent
as it would not supply 'proxy-id' during envoy bootstrap.

Set the ServiceID for gateways, and supply 'proxy-id' when doing envoy bootstrap.

Fixes #9834
2021-01-19 12:58:36 -06:00
Seth Hoenig f213b8c51b consul/connect: always set gateway proxy default timeout
If the connect.proxy stanza is left unset, the connection timeout
value is not set but is assumed to be, and may cause a non-fatal NPE
on job submission.
2021-01-19 11:23:41 -06:00
Drew Bailey 009b8d5363
Persist shared allocated ports for inplace update (#9830)
* Persist shared allocated ports for inplace update

Ports were not copied over when performing inplace updates in the
generic scheduler

* changelog

* drop spew
2021-01-15 12:45:12 -05:00
leonardobsjr 16ec2c76e7
Missed improvement regarding IGW improvement
Seems like this was missing from the docs. Was trying to make this work on 1.0.1 (it was on the docs), however, it's only working on 1.0.2.
2021-01-15 12:34:11 -03:00
Drew Bailey cdc7f85964
Release 1.0.2 (#9819)
* changelog for release 1.0.2

* Generate files for 1.0.2 release

* Release v1.0.2

* rm generated files, update changelog for next release

* checkout bindata_assetfs

* bump version

Co-authored-by: Nomad Release bot <nomad@hashicorp.com>
2021-01-14 15:08:28 -05:00
Drew Bailey 9cd274ba8d
changelogfmt (#9807) 2021-01-13 15:21:17 -05:00
Drew Bailey a7aaa57258
changelog for release 1.0.2 2021-01-13 11:44:30 -05:00
Dave May 35d43c19ab
nomad agent-info: Add json/gotemplate formatting (#9788)
* nomad agent-info: Add json/gotemplate formatting
* Add CHANGELOG entry
* update docs
2021-01-13 09:42:46 -05:00
Jasmine Dahilig 0b8c1865e1
changelog for #9361 (#9783) 2021-01-12 15:12:49 -05:00
Michael Lange 7f2cb4037a
Merge pull request #9780 from hashicorp/d/changelog-9733
Changelog entry for 9733
2021-01-12 10:34:52 -08:00
Seth Hoenig 17bb46903d
Merge pull request #9770 from hashicorp/docs-update-cl
docs: update cl with graviton fix
2021-01-12 12:30:01 -06:00
Michael Lange 1ea19d8616 Changelog entry for 9733 2021-01-12 09:56:02 -08:00
Florian Apolloner df7e22362d Properly detect unloaded dynamic modules on RHEL derivates. Fixes #9776
The modules.dep file on RHEL includes .xz for compressed kernel modules.
2021-01-12 18:28:00 +01:00
Seth Hoenig c145e630c4 docs: update cl with graviton fix 2021-01-11 12:07:05 -06:00
Tim Gross d78b4fc1a1 safely handle existing net namespace in default network manager
When a client restarts, the network_hook's prerun will call
`CreateNetwork`. Drivers that don't implement their own network manager will
fall back to the default network manager, which doesn't handle the case where
the network namespace is being recreated safely. This results in an error and
the task being restarted for `exec` tasks with `network` blocks (this also
impacts the community `containerd` and probably other community task drivers).

If we get an error when attempting to create the namespace and that error is
because the file already exists and is locked by its process, then we'll
return a `nil` error with the `created` flag set to false, just as we do with
the `docker` driver.
2021-01-11 11:31:03 -05:00
Chris Baker a53e54d7a6 changelog for 9761 2021-01-08 19:26:42 +00:00
Drew Bailey c87adfac62
persist shared ports during inplace updates (#9736)
AllocatedSharedResources were not being copied over to the new
allocation struct the scheduler makes during inplace updates. This
caused downstream issues after the plan was applied, namely the shared
ports were dropped causing issues with service
registration/deregistration.

test that shared ports are preserved

change log, also carry over shared network

copy networks
2021-01-08 09:00:41 -05:00
Tim Gross cb0c4b1d0b changelog entry for #9532 2021-01-07 15:44:13 -05:00
Seth Hoenig 09c13b0066
Merge pull request #9751 from hashicorp/b-envoyv-segfault
consul/connect: fix panic during in-place upgrade with connect jobs
2021-01-07 14:22:27 -06:00
Tim Gross 4eafcb06ef changelog: add entry for GH-9050 2021-01-07 15:01:04 -05:00
Seth Hoenig 303856183c consul/connect: fix panic during in-place upgrade with connect jobs
When upgrading from Nomad v0.12.x to v1.0.x, Nomad client will panic on
startup if the node is running Connect enabled jobs. This is caused by
a missing piece of plumbing of the Consul Proxies API interface during the
client restore process.

Fixes #9738
2021-01-07 13:24:24 -06:00
Nick Ethier ab01e19df3 command/agent/consul: use port's to value when building service address under 'alloc' addr_mode 2021-01-06 13:52:48 -05:00
Seth Hoenig c46a503fdb docs: update changelog 2021-01-05 09:31:22 -06:00
Seth Hoenig bc7dd881dd docs: add changelog entry 2021-01-05 08:48:12 -06:00
Chris Baker 60095f47a5 changelog 2021-01-04 22:25:37 +00:00
Michael Schurter 7a6e55b21f
Merge pull request #9686 from hashicorp/golang1.15.6
build: upgrade from Go 1.15.5 -> 1.15.6
2021-01-04 12:07:41 -08:00
Michael Schurter 772ab5502d build: upgrade from Go 1.15.5 -> 1.15.6
Also updated scripts/update_golang_version.sh to handle new CircleCI
file layout.
2021-01-04 08:34:00 -08:00
Mahmood Ali 66c0e85b9c add changelog 2021-01-04 09:09:58 -05:00
Tim Gross ea395d5636 changelog: add missing entry from 0.12.4 2020-12-17 14:31:43 -05:00
Seth Hoenig 93da234e9d docs: move changelog entry 2020-12-16 17:42:28 -06:00
Michael Schurter 72329f8356 docs: release v1.0.1
- Update release date in changelog
- Update download version
- Update alert banner to not be so specific
2020-12-16 13:55:09 -08:00
Michael Schurter 9530d0733e
Merge pull request #9653 from hashicorp/docs-9625-changelog
docs: add #9625 to changelog
2020-12-16 11:13:59 -08:00
Tim Gross 1785822386
template: trigger change_mode for dynamic secrets on restore (#9636)
When a task is restored after a client restart, the template runner will
create a new lease for any dynamic secret (ex. Consul or PKI secrets
engines). But because this lease is being created in the prestart hook, we
don't trigger the `change_mode`.

This changeset uses the the existence of the task handle to detect a
previously running task that's been restored, so that we can trigger the
template `change_mode` if the template is changed, as it will be only with
dynamic secrets.
2020-12-16 13:36:19 -05:00
Michael Schurter e5c54708a7 docs: add #9625 to changelog 2020-12-16 09:50:10 -08:00
Seth Hoenig 283be57d30 docs: add two connect entries to changelog
https://github.com/hashicorp/nomad/pull/9624
https://github.com/hashicorp/nomad/pull/9611
2020-12-16 11:02:12 -06:00
Tim Gross 782c05f8c0
cni: prevent NPE if no interface has sandbox field set
When we iterate over the interfaces returned from CNI setup, we filter for one
with the `Sandbox` field set. Ensure that if none of the interfaces has that
field set that we still return an available interface.
2020-12-16 10:36:03 -05:00
Mahmood Ali de954da350
docker: introduce a new hcl2-friendly `mount` syntax (#9635)
Introduce a new more-block friendly syntax for specifying mounts with a new `mount` block type with the target as label:

```hcl
config {
  image = "..."

  mount {
    type = "..."
    target = "target-path"
    volume_options { ... }
  }
}
```

The main benefit here is that by `mount` being a block, it can nest blocks and avoids the compatibility problems noted in https://github.com/hashicorp/nomad/pull/9634/files#diff-2161d829655a3a36ba2d916023e4eec125b9bd22873493c1c2e5e3f7ba92c691R128-R155 .

The intention is for us to promote this `mount` blocks and quietly deprecate the `mounts` type, while still honoring to preserve compatibility as much as we could.

This addresses the issue in https://github.com/hashicorp/nomad/issues/9604 .
2020-12-15 14:13:50 -05:00
Drew Bailey 54becaab7d
Events/acl events (#9595)
* fix acl event creation

* allow way to access secretID without exposing it to stream

test that values are omitted

test event creation

test acl events

payloads are pointers

fix failing tests, do all security steps inside constructor

* increase time

* ignore empty tokens

* uncomment line

* changelog
2020-12-11 10:40:50 -05:00
Seth Hoenig ead89d3a2b
docs: fixup changelog
Co-authored-by: Tim Gross <tgross@hashicorp.com>
2020-12-09 11:27:12 -06:00
Seth Hoenig b51459a879 consul/connect: interpolate connect block
This PR enables job submitters to use interpolation in the connect
block of jobs making use of consul connect. Before, only the name of
the connect service would be interpolated, and only for a few select
identifiers related to the job itself (#6853). Now, all connect fields
can be interpolated using the full spectrum of runtime parameters.

Note that the service name is interpolated at job-submission time,
and cannot make use of values known only at runtime.

Fixes #7221
2020-12-09 09:10:00 -06:00
Michael Schurter b70f5f2ff3 docs: fix cpu comment for 10->1 to 20->1
Reported by https://github.com/hashicorp/nomad/pull/8996/files#r538702174
2020-12-08 10:59:19 -08:00
Michael Schurter acd607ee68 docs: add the release date for 1.0 2020-12-08 09:27:26 -08:00
Tim Gross 82aad26330 changelog entry for #9495 2020-12-08 09:21:52 -05:00
davemay99 36022c9c59 nomad operator debug changelog / doc updates 2020-12-08 08:51:45 -05:00
Tim Gross ead6f801d8 changelog entry for #8822 2020-12-07 11:25:37 -05:00
James Rasell be48e89d6c
Merge pull request #9523 from hashicorp/b-improve-consul-template-dep-upgrade-detail-1.0.0
CHANGELOG: amend consul-template dep update to ref correct version.
2020-12-04 16:15:50 +01:00
Drew Bailey f37acc71ba
remove prerelease bug fix from GA changelog (#9524) 2020-12-04 10:15:21 -05:00
James Rasell 58f8afed50
CHANGELOG: amend consul-template dep update to ref correct version. 2020-12-04 14:43:18 +01:00
Drew Bailey 17de8ebcb1
API: Event stream use full name instead of Eval/Alloc (#9509)
* use full name for events

use evaluation and allocation instead of short name

* update api event stream package and shortnames

* update docs

* make sync; fix typo

* backwards compat not from 1.0.0-beta event stream api changes

* use api types instead of string

* rm backwards compat note that only changed between prereleases

* remove backwards incompat that only existed in prereleases
2020-12-03 11:48:18 -05:00
Tim Gross d286d941dc docker: kill signal API should include timeout context
When the Docker driver kills as task, we send a request via the Docker API for
dockerd to fire the signal. We send that signal and then block for the
`kill_timeout` waiting for the container to exit. But if the Docker API
blocks, we will block indefinitely because we haven't configured the API call
with the same timeout.

This changeset is a minimal intervention to add the timeout to the Docker API
call _only_ when we have the `kill_timeout` set. Future work should examine
whether we should be threading contexts through other `go-dockerclient` API
calls.
2020-12-02 16:51:57 -05:00
Seth Hoenig 3b2b083cbf
Merge pull request #9487 from hashicorp/f-connect-sidecar-concurrency
consul/connect: default envoy concurrency to 1
2020-12-01 15:51:41 -06:00
Seth Hoenig bf857684d1 consul/connect: default envoy concurrency to 1
Previously, every Envoy Connect sidecar would spawn as many worker
threads as logical CPU cores. That is Envoy's default behavior when
`--concurrency` is not explicitly set. Nomad now sets the concurrency
flag to 1, which is sensible for the default cpu = 250 Mhz resources
allocated for sidecar proxies. The concurrency value can be configured
in Client configuration by setting `meta.connect.proxy_concurrency`.

Closes #9341
2020-12-01 13:12:45 -06:00
Michael Schurter ea0e1789f4
Merge pull request #9435 from hashicorp/f-allocupdate-timer
client: always wait 200ms before sending updates
2020-12-01 08:45:17 -08:00
Drew Bailey a0b7f05a7b
Remove Managed Sinks from Nomad (#9470)
* Remove Managed Sinks from Nomad

Managed Sinks were a beta feature in Nomad 1.0-beta2. During the beta
period it was determined that this was not a scalable approach to
support community and third party sinks.

* update comment

* changelog
2020-11-30 14:00:31 -05:00
Michael Schurter b7c4d16a78 docs: add #9435 to changelog 2020-11-30 10:27:13 -08:00
Seth Hoenig e81e9223ef consul/connect: enable setting datacenter in connect upstream
Before, upstreams could only be defined using the default datacenter.
Now, the `datacenter` field can be set in a connect upstream definition,
informing consul of the desire for an instance of the upstream service
in the specified datacenter. The field is optional and continues to
default to the local datacenter.

Closes #8964
2020-11-30 10:38:30 -06:00
Tim Gross 8ba9bde2ff changelog entries for CSI 2020-11-25 16:44:20 -05:00
Mahmood Ali b2a8752c5f
honor task user when execing into raw_exec task (#9439)
Fix #9210 .

This update the executor so it honors the User when using nomad alloc exec. The bug was that the exec task didn't honor the init command when execing.
2020-11-25 09:34:10 -05:00
Seth Hoenig 3fe3259d32 docs: update changelog with group/task network labels fix 2020-11-23 12:56:54 -06:00
Chris Baker a659091fd9 api: Event().Stream() should use the index parameter 2020-11-21 16:49:52 +00:00
Michael Schurter 85b71e76f7 docs: add 0.12.9, 0.11.8, and 0.10.9 to changelog
upstream fix: #9383

backport PRs: #9391, #9402, and #9405
2020-11-19 14:23:42 -08:00
Chris Baker a207050f01 changelog for #9368 2020-11-16 16:52:40 +00:00
Seth Hoenig 4cc3c01d5b
Merge pull request #9352 from hashicorp/f-artifact-headers
jobspec: add support for headers in artifact stanza
2020-11-13 14:04:27 -06:00
Seth Hoenig bb8a5816a0 jobspec: add support for headers in artifact stanza
This PR adds the ability to set HTTP headers when downloading
an artifact from an `http` or `https` resource.

The implementation in `go-getter` is such that a new `HTTPGetter`
must be created for each artifact that sets headers (as opposed
to conveniently setting headers per-request). This PR maintains
the memoization of the default Getter objects, creating new ones
only for artifacts where headers are set.

Closes #9306
2020-11-13 12:03:54 -06:00
Michael Schurter 156410807f docs: mention upgrade to Go 1.15.5 2020-11-12 14:23:32 -08:00
Jasmine Dahilig aa5587f5df changelog: added poststop to task lifecycle 2020-11-12 08:56:46 -08:00
Mahmood Ali ed6968ade8 changelog: Update 0.12.8 and backported releases 2020-11-12 08:41:03 -05:00
Mahmood Ali bd654c4020 tweak 1.0 changelog 2020-11-12 08:40:49 -05: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 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 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 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 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 53aa5e75c9 fix #9227: use both job and type query on scaling policy list endpoint 2020-11-10 23:26:35 +00: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 cac55f8991 update changelog
[ci skip]
2020-11-10 12:50:34 -05:00
Michael Schurter 1a4fe89866 docs: add go upgrade to changelog 2020-11-10 08:38:05 -08: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
Luiz Aoqui fb0faa657c
add CHANGELOG entry for #9296 2020-11-09 15:26:38 -05:00
Seth Hoenig bbd6ab6167 docs: add changelog entry 2020-11-09 14:16:33 -06:00
Chris Baker be32fb7d3c updated Allocation.List to properly handle ACL checking for namespace=* 2020-11-05 17:26:33 +00:00
Mahmood Ali be11f735c2
Merge pull request #9205 from hashicorp/b-gh-7703
Repurpose dispatch-job capability to dispatch periodic jobs
2020-11-02 13:11:58 -05:00
Mahmood Ali a3755d526c update docs and changelog 2020-11-02 12:44:03 -05:00
Charlie Voiselle b762680102
CHANGELOG entry for #9225
changelog entry for https://github.com/hashicorp/nomad/pull/9225
2020-11-01 13:36:56 -05:00
Tim Gross 8b93397e5d
changelog entry for #8967 (#9164) 2020-10-23 14:27:32 -04:00
Michael Schurter dc5d16bd9e
Merge pull request #9135 from hashicorp/f-namespaces
core: open source namespaces
2020-10-23 10:23:55 -07:00
Tim Gross 10b6551065
docs: add regression warning for GH-9148 to upgrade guide (#9157)
* docs: add regression warning for GH-9148 to upgrade guide
* changelog entry
2020-10-23 10:05:56 -04:00
Michael Schurter 2c78d6cb5d docs: namespaces are oss in Nomad 1.0 2020-10-22 15:26:32 -07:00