Commit graph

17567 commits

Author SHA1 Message Date
Mahmood Ali 6daac02548 avoid forwarding leadership checks in tests
The tests only care if a test server recognizes the leader.
2020-03-02 13:47:43 -05:00
Mahmood Ali acbfeb5815 Simplify Bootstrap logic in tests
This change updates tests to honor `BootstrapExpect` exclusively when
forming test clusters and removes test only knobs, e.g.
`config.DevDisableBootstrap`.

Background:

Test cluster creation is fragile.  Test servers don't follow the
BootstapExpected route like production clusters.  Instead they start as
single node clusters and then get rejoin and may risk causing brain
split or other test flakiness.

The test framework expose few knobs to control those (e.g.
`config.DevDisableBootstrap` and `config.Bootstrap`) that control
whether a server should bootstrap the cluster.  These flags are
confusing and it's unclear when to use: their usage in multi-node
cluster isn't properly documented.  Furthermore, they have some bad
side-effects as they don't control Raft library: If
`config.DevDisableBootstrap` is true, the test server may not
immediately attempt to bootstrap a cluster, but after an election
timeout (~50ms), Raft may force a leadership election and win it (with
only one vote) and cause a split brain.

The knobs are also confusing as Bootstrap is an overloaded term.  In
BootstrapExpect, we refer to bootstrapping the cluster only after N
servers are connected.  But in tests and the knobs above, it refers to
whether the server is a single node cluster and shouldn't wait for any
other server.

Changes:

This commit makes two changes:

First, it relies on `BootstrapExpected` instead of `Bootstrap` and/or
`DevMode` flags.  This change is relatively trivial.

Introduce a `Bootstrapped` flag to track if the cluster is bootstrapped.
This allows us to keep `BootstrapExpected` immutable.  Previously, the
flag was a config value but it gets set to 0 after cluster bootstrap
completes.
2020-03-02 13:47:43 -05:00
James Rasell 00c163fd5c
docs: remove Nomad binary size specifics from documentation. 2020-03-02 19:31:06 +01:00
JanMa 9309084ec8 add missing sidebar item 2020-02-29 20:54:46 +01:00
JanMa df1ee5b4d1 fix page layout settings 2020-02-29 18:07:15 +01:00
Jan Martens 5e082c7ac3 docs: add nspawn as external task driver plugin 2020-02-29 17:52:06 +01:00
Michael Schurter 5276c573e5 docs: mention #7231 in changelog 2020-02-28 13:40:51 -08:00
Mahmood Ali d32f0ff079 Update github.com/hashicorp/hcl
hashicorp/hcl library added some better validation for error and illegal
characters.  The diff is primarily improved error reporting.  The
parser.go change includes a case where illegal characters were silently
dropped, but now get reported as invalid characters.
2020-02-28 15:40:01 -05:00
Mahmood Ali 386f20099b Honor CNI and bridge related fields
Nomad agent may silently ignore cni_path and bridge setting, when it
merges configs from multiple files (or against default/dev config).

This PR ensures that the values are merged properly.
2020-02-28 14:23:13 -05:00
Mahmood Ali 437d03779c tests: add tests for parsing cni fields 2020-02-28 14:18:45 -05:00
Mahmood Ali a8d6950007 Remove rkt as a built-in driver
Rkt has been archived and is no longer an active project:
* https://github.com/rkt/rkt
* https://github.com/rkt/rkt/issues/4024

The rkt driver will continue to live as an external plugin.
2020-02-26 22:16:41 -05:00
Michael Schurter ac3db90497 api: fix panic when displaying devices w/o stat
"<none>" mathces `node status -verbose` output
2020-02-26 21:24:31 -05:00
Dane Harrigan 84f8ac8656
Fix rendered backslash in group "<required>"
The `<require>` tag contained backslashes and the first backslash was getting rendered. See on live site: https://nomadproject.io/docs/job-specification/job/#inlinecode-group-7
2020-02-25 19:22:30 -08:00
Brandon Romano ad126af9c7
Merge pull request #7222 from jescalan/redesigned-website
website: Homepage redesign & use-cases pages
2020-02-24 16:43:08 -08:00
Brandon Romano f2c119d3b0 Fix the line spacing for the codeblock 2020-02-24 19:31:43 -05:00
Brandon Romano 93414b7190 Fix indentation 2020-02-24 19:08:57 -05:00
Brandon Romano 6433c4e2f9 Remove global mega-nav component
We've temporarily ejected the meganav component to add some custom
styling that needed to happen for NomadProject.io
2020-02-23 13:40:37 -08:00
Brandon Romano 7580bdb821
Update website/pages/use-cases/non-containerized-application-orchestration.jsx
Co-Authored-By: Mike Wickett <mike@wickett.ca>
2020-02-23 13:28:32 -08:00
Brandon Romano a2d5049a01
Title case consul connect feature
Co-Authored-By: Mike Wickett <mike@wickett.ca>
2020-02-23 13:27:02 -08:00
Brandon Romano 7d51ffe312
Feature capitalization
Co-Authored-By: Mike Wickett <mike@wickett.ca>
2020-02-23 13:23:15 -08:00
Brandon Romano e0ce5e74c1
Simplify mini-cta optional code
Co-Authored-By: Mike Wickett <mike@wickett.ca>
2020-02-23 13:14:23 -08:00
Fredrik Hoem Grelland edb3bd0f3f Update consul-template to v0.24.1 and remove deprecated vault_grace (#7170) 2020-02-23 16:24:53 +01:00
nicolelyn f056b3353f Homepage redesign & use-cases pages 2020-02-22 15:41:06 -08:00
Nick Ethier eb9c8593ba
Merge pull request #7163 from hashicorp/b-driver-plugin-recovery
drivermanager: attempt dispense on reattachment failure
2020-02-21 10:33:20 -05:00
Seth Hoenig 0f99cdd0d9
Merge pull request #7192 from hashicorp/b-connect-stanza-ignore
consul/connect: in-place update sidecar service registrations on changes
2020-02-21 09:24:53 -06:00
Seth Hoenig 07b9b24ceb
nomad: note why AddressMode is not part of CSD hash
Co-Authored-By: Michael Schurter <mschurter@hashicorp.com>
2020-02-21 09:24:42 -06:00
James Rasell 50f9b08b00
Merge pull request #7207 from hashicorp/b-gh-7203
Fix panic when canonicalizing a jobspec with incorrect job type.
2020-02-21 16:01:13 +01:00
James Rasell b1e372a275
Update CHANGELOG.md 2020-02-21 14:21:34 +01:00
James Rasell 6463532577
Fix panic when canonicalizing a jobspec with incorrect job type.
When canonicalizing the ReschedulePolicy a panic was possible if
the passed job type was not valid. This change protects against
this possibility, in a verbose way to ensure the code path is
clear.
2020-02-21 09:14:36 +01:00
Jeff Escalante e9ea75b108
correct analytics traffic pointer (#7212) 2020-02-20 20:16:48 -05:00
Michael Schurter d3a9ab3a79
Merge pull request #7083 from hashicorp/d-service-lifecycle
Document service lifecycle
2020-02-20 14:56:17 -08:00
Michael Schurter 17ddd46322
Merge pull request #7196 from hashicorp/website-0104
Update website to v0.10.4
2020-02-20 09:24:12 -08:00
James Rasell e7eb49fe84 api: check response content length before decoding.
The API decodeBody function will now check the content length
before attempting to decode. If the length is zero, and the out
interface is nil then it is safe to assume the API call is not
returning any data to the user. This allows us to better handle
passing nil to API calls in a single place.
2020-02-20 10:07:44 +01:00
Nick Ethier 96d9713c36
Merge pull request #7202 from hashicorp/prep-011-cycle
release: prep for next dev cycle
2020-02-19 18:43:33 -05:00
Michael Schurter 02af3cd33a docs: update to Nomad 0.10.4 in Vagrantfile 2020-02-19 12:55:59 -08:00
Michael Schurter 74d5f662e6 docs: update download page for 0.10.4 final 2020-02-19 12:51:02 -08:00
Mahmood Ali 6d0280fa88
Merge pull request #7191 from hashicorp/revert-6979-f/codeowners
Revert "Add the digital marketing team as the code owners for the website dir"
2020-02-19 14:01:16 -06:00
Michael Schurter ba2dba92e8
Merge pull request #7164 from pulecp/master
fix port forwarding of TCP/4646
2020-02-19 11:34:00 -08:00
Nick Ethier c3b66c78f5 release: prep for next dev cycle 2020-02-19 14:31:31 -05:00
Seth Hoenig 54b5173eca consul/connect: in-place update sidecar service registrations on changes
Fix a bug where consul service definitions would not be updated if changes
were made to the service in the Nomad job. Currently this only fixes the
bug for cases where the fix is a matter of updating consul agent's service
registration. There is related bug where destructive changes are required
(see #6877) which will be fixed in another PR.

The enable_tag_override configuration setting for the parent service is
applied to the sidecar service.

Fixes #6459
2020-02-19 13:07:04 -06:00
Charlie Voiselle 6d6d8d0ce7
Merge pull request #7190 from hashicorp/d-cv-connect-namespace-note
[docs] Add note Nomad Connect requires namespaces...
2020-02-19 13:26:49 -05:00
Mahmood Ali d539052f68
Revert "Add the digital marketing team as the code owners for the website dir" 2020-02-19 12:25:42 -06:00
Mahmood Ali 07943f95a4
Merge pull request #7149 from th0m/tlefebvre/no-pivot-root
client: support no_pivot_root in exec driver configuration
2020-02-19 12:18:51 -06:00
Drew Bailey 21b119cdb0
Merge pull request #7187 from hashicorp/guard-for-ent
check if website-docker-image job should run
2020-02-19 13:15:51 -05:00
Drew Bailey 4ba846476b
make config.yml 2020-02-19 12:44:47 -05:00
Drew Bailey c507fd0e2e
refact to remove conditional nesting 2020-02-19 12:44:22 -05:00
Charlie Voiselle d32cf47836 [docs] Add note Nomad Connect requires namespaces...
and can only run on linux oses at the moment.
2020-02-19 12:16:20 -05:00
Mahmood Ali f4d8e1296f
Merge pull request #7171 from hashicorp/update-autopilot-20200214
Update consul vendor and add MinQuorum flag
2020-02-19 10:45:20 -06:00
Michael Schurter 4d8de5eda1 docs: mention group service registration
A few minor tweaks and cleanups as well.
2020-02-19 08:29:58 -08:00
Kyle MacDonald 6be8cb2090 website: indent mode bullets in network params 2020-02-19 11:16:00 -05:00