Commit graph

21862 commits

Author SHA1 Message Date
Luiz Aoqui a81e6a427d
ui: fix job dispatch page when job doesn't have any meta fields (#10934) 2021-08-03 13:50:43 -04:00
Mahmood Ali 28bc234e84 e2e: fix tests
Use basic sleeps in busybox images. busybox are very light, and ping has
permissions complications, and it may fail for network related
issues.
2021-08-03 11:38:35 -04:00
Seth Hoenig 3371214431 core: implement system batch scheduler
This PR implements a new "System Batch" scheduler type. Jobs can
make use of this new scheduler by setting their type to 'sysbatch'.

Like the name implies, sysbatch can be thought of as a hybrid between
system and batch jobs - it is for running short lived jobs intended to
run on every compatible node in the cluster.

As with batch jobs, sysbatch jobs can also be periodic and/or parameterized
dispatch jobs. A sysbatch job is considered complete when it has been run
on all compatible nodes until reaching a terminal state (success or failed
on retries).

Feasibility and preemption are governed the same as with system jobs. In
this PR, the update stanza is not yet supported. The update stanza is sill
limited in functionality for the underlying system scheduler, and is
not useful yet for sysbatch jobs. Further work in #4740 will improve
support for the update stanza and deployments.

Closes #2527
2021-08-03 10:30:47 -04:00
James Rasell 78a489418d
cli: fix minor format error within -ca-cert help text. 2021-08-03 16:05:06 +02:00
みゃお 8d970d97d3
[doc]Add replication_token link with authoritative_region
replication_token always works together with authoritative_region, add a link for better doc.
2021-08-03 18:56:00 +08:00
Mahmood Ali 0bc12fba7c
Only initialize task.VolumeMounts when not-nil (#10990)
1.1.3 had a bug where task.VolumeMounts will be an empty slice instead of nil. Eventually, it gets canonicalized and is set to `nil`, but it seems to confuse dry-run planning.

The regression was introduced in https://github.com/hashicorp/nomad/pull/10855/files#diff-56b3c82fcbc857f8fb93a903f1610f6e6859b3610a4eddf92bad9ea27fdc85ecL1028-R1037 . Curiously, it's the only place where `len(apiTask.VolumeMounts)` check was dropped. I assume it was dropped accidentally.

Fixes #10981
2021-08-02 13:08:10 -04:00
Mike Wickett 85278ab3f7
website: update consent manager (#10977) 2021-08-02 12:56:20 -04:00
Derek Strickland 7210f855e8
Merge pull request #10976 from itorres/api-docs-allocation-restart-sample
API docs: Fix allocation restart example
2021-08-02 08:48:45 -04:00
James Rasell 15dc41d17f
Merge pull request #10987 from hashicorp/f-docs-order-external-drivers-alphabetically
docs: order external driver overview alphabetically.
2021-08-02 12:50:16 +02:00
James Rasell 167b6c50ff
docs: order external driver overview alphabetically. 2021-08-02 10:51:37 +02:00
Lir (Rookout) 216d0392a8
Rookout driver docs (#10950)
Co-authored-by: James Rasell <jrasell@users.noreply.github.com>
2021-08-02 10:09:45 +02:00
Mahmood Ali 8585aa8991
Merge pull request #10969 from hashicorp/merge-release-1.1.3
Merge release 1.1.3
2021-07-30 11:23:25 -04:00
Ignacio Torres Masdeu 3f784f17f7
Fix allocation restart API docs example 2021-07-30 16:45:21 +02:00
Mike Nomitch 6a8158fd5a
Adds documentation for file mode to sink docs (#10972) 2021-07-29 16:09:18 -04:00
Mahmood Ali b590d43b0d
website: publish 1.1.3 release (#10970) 2021-07-29 12:35:18 -04:00
Mahmood Ali 327ad78ea5 prepare for next dev cycle 2021-07-29 12:32:09 -04:00
Kent 'picat' Gruber b70ad3c190 Add configuration for /website using NPM 2021-07-29 11:03:26 -04:00
Kent 'picat' Gruber ec69a71c63 Add initial Dependabot configuration 2021-07-29 10:52:25 -04:00
Mahmood Ali 70f541287b
e2e: wait for allocs and deployments (#10967)
As we moved to using `-detach` for registering jobs, we should wait
until allocs and deployments are created before asserting their
properties.

Fixing `TestNodeDrainIgnoreSystem` and `TestRescheduleProgressDeadlineFail` tests as they seem particularly flaky, failing 9 and 7 times (respectively) in the last two weeks.
2021-07-29 10:52:04 -04:00
Nomad Release Bot 423799b2dd remove generated files 2021-07-29 04:17:44 +00:00
Nomad Release Bot 6b52b26517
Release v1.1.3 2021-07-29 04:17:00 +00:00
Nomad Release bot b5dff8be42 Generate files for 1.1.3 release 2021-07-29 03:43:03 +00:00
Mahmood Ali 12d4a0b759 prepare release docker image for fetching 2021-07-28 23:33:59 -04:00
Mahmood Ali 2ecc7462cf update changelog for release 2021-07-28 21:59:03 -04:00
Mahmood Ali 22a91f7003
update changelog (#10963) 2021-07-28 16:02:04 -04:00
Grant Griffiths fecbbaee22 CSI ListSnapshots secrets implementation
Signed-off-by: Grant Griffiths <ggriffiths@purestorage.com>
2021-07-28 11:30:29 -07:00
Bryce Kalow 6714bb0fdf
adds back tab styles (#10961) 2021-07-28 12:42:46 -04:00
Mahmood Ali 62fe6f12f9
api: revert to defaulting to http/1 (#10958)
* api: revert to defaulting to http/1

PR #10778 incidentally changed the api http client to connect with
HTTP/2 first. However, the websocket libraries used in `alloc exec`
features don't handle http/2 well, and don't downgrade to http/1
gracefully.

Given that the switch is incidental, and not requested by users.
Furthermore, api consumers can opt-in to forcing http/2 by setting
custom http clients.

Fixes #10922
2021-07-28 11:21:53 -04:00
Bryce Kalow e3b045e376
web: migrate to web platform- packages (#10908) 2021-07-27 16:11:46 -05:00
Mahmood Ali fdb82b9398
Update some dependencies to match Enterprise (#10940)
Noticed that the private Enterprise repository dependencies drifted a bit. Here, we update the OSS to the dependencies used by Enterprise.

We should update all dependencies as a matter of hygiene, but that's an issue for another time.
2021-07-27 16:33:18 -04:00
Michael Schurter ea996c321d
Merge pull request #10916 from hashicorp/f-audit-log-mode
Add audit log file mode config parameter
2021-07-27 12:16:37 -07:00
Michael Schurter d64d70607a docs: add changelog for #10916 2021-07-27 11:51:38 -07:00
Mahmood Ali ac3cf10849
nomad: only activate one-time auth tokens with 1.1.0 (#10952)
Fix a panic in handling one-time auth tokens, used to support `nomad ui
--authenticate`.

If the nomad leader is a 1.1.x with some servers running as 1.0.x, the
pre-1.1.0 servers risk crashing and the cluster may lose quorum. That
can happen when `nomad authenticate -ui` command is issued, or when the
leader scans for expired tokens every 10 minutes.

Fixed #10943 .
2021-07-27 13:17:55 -04:00
James Rasell a15d03556c
Merge pull request #10945 from HZHgagaga/main
Update client.mdx
2021-07-27 11:35:36 +02:00
HZHgagaga fafaf1e07e
Update client.mdx
Missing "-" symbol, "bridge_ Network name" should be "bridge_ network_name".
2021-07-27 11:24:34 +08:00
Jai Bhagat e7f0cd28f3 edit fuzzy search callback logic
Namespaces are set-up in Nomad to be an object that has an id property.
However, namespaces actually don't have that shape. Our search was expecting
a namespace object, but we actually don't have a namespace assigned to jobs
in our config and namespace is set to null. Normally, these namespaces would
be set to default, but that would require us to refactor our Mirage config
if we wanted to assert that namespaces are 'default' and not null. So this is
a bandaid solution.
2021-07-26 17:25:43 -04:00
Mahmood Ali 5c45d74f3c
Merge pull request #10931 from hashicorp/b-hcl1-backport-fields
Support the new post-1.0.0 job spec fields in the HCLv1 parser.

The HCLv1 parser is still the default (or only!) parser in many downstream tools, e.g. [Levant](e48c439f14/template/render.go (L13-L30)), and [terraform-provider-nomad](bce32a7831/nomad/resource_job.go (L735-L743)) .

While we initially intended to deprecate HCLv1 parser in 1.0.0, we never communicated that publicly. We did not fully anticipate the public usage of `jobspec` package (we assumed it's a private package), or the friction that HCLv2 introduced in some cases (e.g. https://github.com/hashicorp/nomad/issues/10777, https://github.com/hashicorp/nomad/issues/9838).

So moving forward we intend to ensure that new job spec fields are honored in both the HCLv1 and HCLv2 parser until we solidify the migration path and communicate it properly.
2021-07-26 12:06:09 -04:00
Mahmood Ali e0efe2f09d hcl: add new cores resources field 2021-07-26 11:45:10 -04:00
Mahmood Ali d97927ebcf
cli: Use glint to determine if os.Stdout is tty (#10926)
Use glint to determine if os.Stdout is a terminal.

glint Terminal renderer expects os.Stdout [not only to be a terminal, but also to have non-zero size](b492b545f6/renderer_term.go (L39-L46)). It's unclear how this condition arises, but this additional check causes Nomad to render deployments progress through glint when glint cannot support it.

By using golint to perform the check, we eliminate the risk of mis-judgement.
2021-07-23 11:27:47 -04:00
Mahmood Ali 63aa8157aa support gateway mesh 2021-07-22 17:10:59 -04:00
Timothé Perez ce877bdf7c fix: load token in docker auth config 2021-07-22 22:27:29 +02:00
Mahmood Ali 715380d53c add a test for envoy_dns_discovery_type 2021-07-22 16:06:48 -04:00
Mahmood Ali d75a4db0a7 parse service check body 2021-07-22 16:06:48 -04:00
Mahmood Ali 17756a1e90 services OnUpdate 2021-07-22 16:06:48 -04:00
Mahmood Ali 22f786d375 hclv1: parse service upstreams 2021-07-22 16:06:48 -04:00
Mahmood Ali 7ac28d74e6 test parsing more service fields 2021-07-22 16:06:26 -04:00
Jai Bhagat 1440b562e0 Merge remote-tracking branch 'origin/main' into b-ui/search-namespaces 2021-07-22 15:16:30 -04:00
Seth Hoenig da32936c29
Merge pull request #10924 from hashicorp/deps-upgrade-consul-api
deps: upgrade consul api to 1.9.1
2021-07-22 12:41:56 -05:00
Seth Hoenig d4d558fae8
Merge pull request #10925 from hashicorp/deps-update-aws-cpus
env/aws: update ec2 cpu data
2021-07-22 12:41:25 -05:00
Jai 0ccf60444d
Merge pull request #10893 from hashicorp/f-ui/namespace-acl-bug
edit ember-can to add additional attribute for namespace
2021-07-22 12:57:34 -04:00