Commit Graph

4909 Commits

Author SHA1 Message Date
Tim Gross
33c68dcc58 docs: clarify workload-associated policy parameters (#24882)
Workload-associated ACL policies can only be set on a specific job within a
namespace, not the namespace as a whole. Clarify the documentation for the CLI
and API.

Fixes: https://github.com/hashicorp/terraform-provider-nomad/issues/500
Ref: https://github.com/hashicorp/terraform-provider-nomad/pull/504
2025-01-17 10:51:33 -05:00
Brian McClain
b4cc5d88e7 docs: update install command for Fedora to match install page (#24870) 2025-01-16 13:39:56 -05:00
James Rasell
689f935e0a services: Support TLS Skip Verify within Nomad service checks. (#24781)
Checks within a service using the Nomad provider can now utilise
the `tls_skip_verify` parameter.
2025-01-15 07:39:39 +00:00
Tim Gross
3a11a0b1e1 quotas: refactor storage limit specification (#24785)
In anticipation of having quotas for dynamic host volumes, we want the user
experience of the storage limits to feel integrated with the other resource
limits. This is currently prevented by reusing the `Resources` type instead of
having a specific type for `QuotaResources`.

Update the quota limit/usage types to use a `QuotaResources` that includes a new
storage resources quota block. The wire format for the two types are compatible
such that we can migrate the existing variables limit in the FSM.

Also fixes improper parallelism in the quota init test where we change working
directory to avoid file write conflicts but this breaks when multiple tests are
executed in the same process.

Ref: https://github.com/hashicorp/nomad-enterprise/pull/2096
2025-01-13 09:25:00 -05:00
Aimee Ukasick
ffb34319d5 Docs SEO: Update Configuration section to improve search (#24759)
* Docs SEO: Update Configuration section to improve search engine opt

CE-775

* Add enterprise only back to audit

* Update descriptions and add intro paragraph

* Fix typo

* replace "below" and "see"

* Apply suggestions from code review

Co-authored-by: Jeff Boruszak <104028618+boruszak@users.noreply.github.com>

---------

Co-authored-by: Jeff Boruszak <104028618+boruszak@users.noreply.github.com>
2025-01-10 11:05:23 -06:00
Mitch Pronschinske
b050c73a6d Update who-uses-nomad.mdx (#24815)
* Update who-uses-nomad.mdx

Our new contract with Roblox states that we can't mention anywhere on our sites that they use us.

* Update who-uses-nomad.mdx

Edited the sentence above the companies list to more accurately reflect them.

Also added Target to the list with a link to their case study.
2025-01-09 09:05:26 -06:00
Ruben Nic
894b32f178 Merge pull request #24791 from hashicorp/rm/version-bump-prettier
Add override to force prettier 5.0
2025-01-08 10:01:48 -05:00
Tim Gross
08a6f870ad cni: use check command when restoring from restart (#24658)
When the Nomad client restarts and restores allocations, the network namespace
for an allocation may exist but no longer be correctly configured. For example,
if the host is rebooted and the task was a Docker task using a pause container,
the network namespace may be recreated by the docker daemon.

When we restore an allocation, use the CNI "check" command to verify that any
existing network namespace matches the expected configuration. This requires CNI
plugins of at least version 1.2.0 to avoid a bug in older plugin versions that
would cause the check to fail.

If the check fails, destroy the network namespace and try to recreate it from
scratch once. If that fails in the second pass, fail the restore so that the
allocation can be recreated (rather than silently having networking fail).

This should fix the gap left #24650 for Docker task drivers and any other
drivers with the `MustInitiateNetwork` capability.

Fixes: https://github.com/hashicorp/nomad/issues/24292
Ref: https://github.com/hashicorp/nomad/pull/24650
2025-01-07 09:38:39 -05:00
Piotr Kazmierczak
0906f788f0 keyring: warn if removing a key that was used for encrypting variables (#24766)
Adds an additional check in the Keyring.Delete RPC to make sure we're not
trying to delete a key that's been used to encrypt a variable. It also adds a
-force flag for the CLI/API to sidestep that check.
2025-01-07 10:15:02 +01:00
Robert Main
ca0deab87c Add override to force prettier 5.0
This fixes an issue with prettier incorrectly causing pre-commit hooks
to fail
2025-01-06 16:07:51 -05:00
Charles Z.
f7b12dc54e add noswap to secretdir tmpfs (#24645) 2025-01-06 09:44:43 -05:00
Tim Gross
c3ac9c19a0 event stream: add events for CSI volumes and plugins (#24724)
Adds new topics to the event stream for CSI volumes and CSI plugins. We'll emit
event when either is created or deleted, and when CSI volumes are claimed.
2024-12-19 15:26:29 -05:00
Tim Gross
9cf0ad9447 event stream: add events for dynamic host volumes (#24721)
Add a new topic to the event stream for host volumes. We'll emit events when a
dynamic host volume is registered or deregistered, and whenever a node
fingerprints with a changed volume.

Ref: https://hashicorp.atlassian.net/browse/NET-11549
2024-12-19 14:55:38 -05:00
Aimee Ukasick
1065769f1e Docs: fix typo in lower_bound (#24731)
reported via Slack
2024-12-19 13:31:37 -06:00
Aimee Ukasick
1c12fc59a6 Docs: change stop_after to stop_on_client_after (#24727)
* change stop_after to stop_on_client_after

CE-800  GH https://github.com/hashicorp/nomad/issues/24702

* Move disconnect entry to correct alphabetical place in nav
2024-12-19 13:13:57 -06:00
Aimee Ukasick
8dc4a94b35 Add link to published tutorial (#24712)
CE-801
2024-12-19 12:52:05 -06:00
James Rasell
7d48aa2667 client: emit optional telemetry from prerun and prestart hooks. (#24556)
The Nomad client can now optionally emit telemetry data from the
prerun and prestart hooks. This allows operators to monitor and
alert on failures and time taken to complete.

The new datapoints are:
  - nomad.client.alloc_hook.prerun.success (counter)
  - nomad.client.alloc_hook.prerun.failed (counter)
  - nomad.client.alloc_hook.prerun.elapsed (sample)

  - nomad.client.task_hook.prestart.success (counter)
  - nomad.client.task_hook.prestart.failed (counter)
  - nomad.client.task_hook.prestart.elapsed (sample)

The hook execution time is useful to Nomad engineering and will
help optimize code where possible and understand job specification
impacts on hook performance.

Currently only the PreRun and PreStart hooks have telemetry
enabled, so we limit the number of new metrics being produced.
2024-12-12 14:43:14 +00:00
dependabot[bot]
9a1d951f45 chore(deps-dev): bump prettier from 3.2.4 to 3.4.1 in /website (#24573)
Bumps [prettier](https://github.com/prettier/prettier) from 3.2.4 to 3.4.1.
- [Release notes](https://github.com/prettier/prettier/releases)
- [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prettier/prettier/compare/3.2.4...3.4.1)

---
updated-dependencies:
- dependency-name: prettier
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-06 09:40:05 -05:00
Aimee Ukasick
af5e2a742e Docs Feature: Add clone and edit feature (#24593)
* Docs: Add clone and edit feature

CE-741

* Change clone and edit heading level

* A few work tweaks
2024-12-05 09:21:27 -06:00
CJ
4563165196 Update sentinel.mdx (#24598) 2024-12-03 11:24:06 -05:00
CJ
b603b97d26 Update security.mdx 2024-12-02 11:43:24 -06:00
Piotr Kazmierczak
f7a4ded2c0 security: add CT executeTemplate to default function_denylist (#24541)
This PR adds Consul Template's executeTemplate function to the denylist by
default, in order to prevent accidental or malicious infinitely recursive
execution.

---------

Co-authored-by: Tim Gross <tgross@hashicorp.com>
2024-11-22 19:33:56 +01:00
Piotr Kazmierczak
368241dbf2 security: a more comprehensive env.denylist (#24540)
A more comprehensive env.denylist that now includes more token, token file and
license variables. 

---------

Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
2024-11-22 18:54:18 +01:00
Juana De La Cuesta
25cc492a16 docs: update the job subcommands on the docs (#24506) 2024-11-20 08:37:43 -06:00
Phil Renaud
83b30128a0 Add an image of the rendered UI block for a jobspec (#24481) 2024-11-20 09:33:47 -05:00
James Rasell
11bba3dbcd docs: fix broken link within enterprise Sentinel docs. (#24486) 2024-11-20 07:43:30 +00:00
Florian Apolloner
0a343798b6 Add NOMAD_* variables to CNI args. Fixes #23830 (#24319)
Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
2024-11-19 12:48:48 -08:00
Aimee Ukasick
4dfedf1aef add top-level heading so the page renders correctly (#24491)
Add opening paragraph; update description
2024-11-19 11:10:10 -06:00
James Rasell
dc501339da docs: Add federated region concept and operations pages. (#24477)
In order to help users understand multi-region federated
deployments, this change adds two new sections to the website.

The first expands the architecture page, so we can add further
detail over time with an initial federation page. The second adds
a federation operations page which goes into failure planning and
mitigation.

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>
Co-authored-by: Michael Schurter <mschurter@hashicorp.com>
2024-11-19 12:39:57 +00:00
Michael Schurter
8dd570d6ca docs: upgrade docs should point at real version (#24438)
Let users know what happened to 1.9.2 but label the gc change as the
first working release (1.9.3).
2024-11-12 11:05:27 -08:00
Eduardo Medeiros
f8c85b036b docs: remove duplicated word. (#24433)
remove duplicated word “Using using”
2024-11-11 16:10:10 -05:00
Shantanu Gadgil
1d123fdc7b docs/tools: add Nomad Tools (#24416)
Add Nomad Tools

`https://github.com/Kamilcuk/nomad-tools`
2024-11-11 14:22:46 -05:00
Juana De La Cuesta
dfa0066d06 [gh-24311] Expand on documentation about jobs that are both parameterised and periodic (#24384)
* docs: expand on documentation about jobs that are both parameterized and periodic

* fix: typo

* docs: expand on the example

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/periodic.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/periodic.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* style: improve the content with PR suggestions

* periodic.mdx fix link to parameterized

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update parameterized.mdx

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update website/content/docs/job-specification/parameterized.mdx

Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>

* Update parameterized.mdx

---------

Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>
2024-11-08 17:29:46 +01:00
Daniel Bennett
a036b75aef api: new dispatch endpoint sends body as Payload (#24381)
this opens up dispatching parameterized jobs by systems
that do not allow modifying what http request body they send

e.g. these two things are equal:

POST '{"Payload": "'"$(base64 <<< "hello")"'"}' /v1/job/my-job/dispatch
POST 'hello' /v1/job/my-job/dispatch/payload
2024-11-07 10:12:29 -06:00
Daniel Bennett
c32d9ed6f5 docs: ipv6: small fixes (#24368)
* escaping newlines is not allowed in go-sockaddr template
* client{} block in client section
* tiny extra clarification that the NOMAD_ADDR is an example
2024-11-05 11:11:36 -06:00
Piotr Kazmierczak
f7847c6e5b state: remove TimeTable and rely on objects' modify times instead (#24112)
Core scheduler relies on a special table in the state store—the TimeTable—to
figure out which objects can be GC'd. The TimeTable correlates Raft indices
with objects insertion time, a solution we used before most of the objects we
store in the state contained timestamps. This introduced a bit of a memory
overhead and complexity, but most importantly meant that any GC threshold users
set greater than timeTableLimit = 72 * time.Hour was ignored. This PR removes
the TimeTable and relies on object timestamps to determine whether they could
be GCd or not.
2024-11-01 19:38:04 +01:00
Michael Smithhisler
658c429d75 Drivers: add work_dir config to exec/raw_exec/java drivers (#24249)
---------

Co-authored-by: wurosh <uros.m.perisic@gmail.com>
Co-authored-by: Michael Schurter <mschurter@hashicorp.com>
Co-authored-by: Tim Gross <tgross@hashicorp.com>
2024-11-01 11:04:40 -04:00
James Rasell
58ea294f0b docs: add note to reschedule block for update progress deadline. (#24346)
Co-authored-by: Aimee Ukasick <aimee.ukasick@hashicorp.com>
2024-11-01 14:54:51 +00:00
Juana De La Cuesta
c18418fa61 Merge pull request #20073 from hashicorp/feat/uid-gid-restriction
Adds ability to restrict uid and gids in exec and raw_exec
2024-10-31 15:48:45 +01:00
Juana De La Cuesta
3449056cd6 Update website/content/docs/drivers/raw_exec.mdx
Co-authored-by: Michael Smithhisler <michael.smithhisler@hashicorp.com>
2024-10-31 10:26:26 +01:00
Juana De La Cuesta
3f32557f1e Update website/content/docs/drivers/exec.mdx
Co-authored-by: Michael Smithhisler <michael.smithhisler@hashicorp.com>
2024-10-31 09:43:49 +01:00
Aimee Ukasick
5b1ad83d82 Docs: Add IPv6 support page (#24228)
* initial content from Daniel's doc

* Add IPv6 support doc to operations section.

* daniel obsessively re-refactors his docs

* Style guide edits

* a few more style nits

---------

Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
2024-10-29 14:02:04 -05:00
johncooler
c72e5755f8 Add info about authentication (#23934)
Co-authored-by: James Rasell <jrasell@users.noreply.github.com>
2024-10-29 15:45:49 +00:00
Etienne Bruines
09703b244a fix: documentation of idempotency_token in API (#24317)
The parsing of the idempotency_token requires snake case, as it is a URL query parameter and not part of the JSON request body. 

See also: 2df473c561/command/agent/http.go (L951)
2024-10-29 09:45:33 -05:00
Mike Nomitch
9565dde138 Only parsing id ranges once 2024-10-28 11:15:41 +01:00
Mike Nomitch
9cc3992ca6 Adds ability to restrict uid and gids in exec and raw_exec 2024-10-28 11:15:37 +01:00
Jamie Finnigan
dec1bf51c0 update ndjson links due to domain expiry/resale (#24306) 2024-10-28 09:06:50 +00:00
Martijn Vegter
6236f354a5 consul: add support for service weight (#24186) 2024-10-25 11:21:38 -04:00
Tim Gross
a1ede9765c docs: warn about UID overlap between workload and Envoy tproxy (#24291)
When using transparent proxy mode with the `connect` block, the UID of the
workload cannot be the same as the UID of the Envoy sidecar (currently 101 in
the default Envoy container image).

Fixes: https://github.com/hashicorp/nomad/issues/23508
2024-10-24 08:45:44 -04:00
R.B. Boyer
4e8f596311 docs: update broken consul acl token links (#24287) 2024-10-23 13:34:21 -04:00