Commit Graph

16032 Commits

Author SHA1 Message Date
Mahmood Ali
7e69a5be21 fix comment typo 2019-09-18 09:11:08 -04:00
Mahmood Ali
922663ae56 Merge pull request #6326 from hashicorp/b-docker-start-failure-handling
Fix bugs around docker start retries
2019-09-18 08:27:19 -04:00
Tim Gross
00c24fcc29 e2e: move consul status check helpers to e2eutil (#6314) 2019-09-18 08:18:19 -04:00
Mahmood Ali
b5b445c101 add exponential backoff for docker api calls 2019-09-18 08:12:54 -04:00
Nick Ethier
404d2d4c98 reduce memory required for logmon, docker_logger and executor p… (#6341)
* reduce memory required for logmon, docker_logger and executor processes

* comment early importing
2019-09-17 23:55:07 -04:00
Mahmood Ali
57850dd003 Merge pull request #6328 from hashicorp/b-gh-6269
cli: emit job version number proper
2019-09-17 19:06:44 -04:00
Michael Schurter
d1af605881 Merge pull request #6345 from Veraghin/patch-1
Update GNUmakefile
2019-09-17 14:08:04 -07:00
Veraghin
ae874b9124 Update GNUmakefile
Cert auth generation echo fixed
2019-09-17 22:05:53 +01:00
Danielle
0245d2e61c Merge pull request #6330 from hashicorp/f-host-vols-fail-startup
client: Fail startup if host volumes do not exist
2019-09-17 10:55:30 -07:00
Mahmood Ali
82700ddb5f Merge pull request #6338 from hashicorp/d-ui-readme-20190917
Tweaks for UI README
2019-09-17 12:28:25 -04:00
Mahmood Ali
59306bd3e9 add some ui development tips 2019-09-17 08:51:24 -04:00
Mahmood Ali
df03de84f6 Merge pull request #6327 from hashicorp/b-ui-alloc-no-services
ui: protect against no services
2019-09-17 06:33:52 -04:00
Michael Lange
6ced5d688c Merge pull request #6274 from hashicorp/f-ui/restore-headless-testing
UI: Restore local headless testing
2019-09-17 00:15:41 -07:00
Mahmood Ali
d966a2fe9e ui: protect against nil services
Protect against case where an alloc has no services and avoid
dereferencing null.

Here, we ensure that the model and test serializers mimic the API by
having nil TaskGroup.Services instead of an empty array.
2019-09-16 16:50:30 -04:00
Tim Gross
6a9911d9aa remove resolved TODO from UpdateTTL docstring (#6336) 2019-09-16 16:26:06 -04:00
Danielle
f232c7258e Merge pull request #6321 from hashicorp/dani/remove-config
Hoist Volume.Config.Source into Volume.Source
2019-09-16 10:12:58 -07:00
Danielle
42cf4f96b5 docs: Mark volume source as required
Co-Authored-By: Michael Schurter <mschurter@hashicorp.com>
2019-09-16 10:05:50 -07:00
Charlie Voiselle
4c5a16e412 Merge pull request #6234 from hashicorp/docs-template-split-cert-parts
Added vault PKI example with separate cert files
2019-09-16 10:19:19 -04:00
Mahmood Ali
48034051d4 cli: emit job version number proper
We must emit alloc job number rather than its the field address.
2019-09-13 19:04:32 -04:00
Danielle Lancashire
bf8cbf70c1 client: Fail startup if host volumes do not exist
Some drivers will automatically create directories when trying to mount
a path into a container, but some will not.

To unify this behaviour, this commit requires that host volumes already exist,
and can be stat'd by the Nomad Agent during client startup.
2019-09-13 23:28:10 +02:00
Mahmood Ali
d5051687b8 retry transient docker errors within function 2019-09-13 15:25:31 -04:00
Mahmood Ali
2f47a6d86c docker: defensive against failed starts
This handles a bug where we may start a container successfully, yet we
fail due to retries and startContainer not being idempotent call.

Here, we ensure that when starting a container fails with 500 error,
the retry succeeds if container was started successfully.
2019-09-13 13:02:35 -04:00
Ruslan Usifov
a88482a9ec close file handle when FileRotator object will closed. Fixes https://github.com/hashicorp/nomad/issues/6309 (#6323) 2019-09-13 10:31:13 -04:00
Tim Gross
ad741aff08 client/networking: wrap error message from CNI plugin (#6316) 2019-09-13 08:20:05 -04:00
Danielle Lancashire
e195043bff docs: Remove config from volumes 2019-09-13 04:37:59 +02:00
Danielle Lancashire
ab5ba7aa9b config: Hoist volume.config.source into volume
Currently, using a Volume in a job uses the following configuration:

```
volume "alias-name" {
  type = "volume-type"
  read_only = true

  config {
    source = "host_volume_name"
  }
}
```

This commit migrates to the following:

```
volume "alias-name" {
  type = "volume-type"
  source = "host_volume_name"
  read_only = true
}
```

The original design was based due to being uncertain about the future of storage
plugins, and to allow maxium flexibility.

However, this causes a few issues, namely:
- We frequently need to parse this configuration during submission,
scheduling, and mounting
- It complicates the configuration from and end users perspective
- It complicates the ability to do validation

As we understand the problem space of CSI a little more, it has become
clear that we won't need the `source` to be in config, as it will be
used in the majority of cases:

- Host Volumes: Always need a source
- Preallocated CSI Volumes: Always needs a source from a volume or claim name
- Dynamic Persistent CSI Volumes*: Always needs a source to attach the volumes
                                   to for managing upgrades and to avoid dangling.
- Dynamic Ephemeral CSI Volumes*: Less thought out, but `source` will probably point
                                  to the plugin name, and a `config` block will
                                  allow you to pass meta to the plugin. Or will
                                  point to a pre-configured ephemeral config.
*If implemented

The new design simplifies this by merging the source into the volume
stanza to solve the above issues with usability, performance, and error
handling.
2019-09-13 04:37:59 +02:00
Kris Hicks
4876353dcf Merge pull request #6318 from hashicorp/hicks/fix-upstreams-link
Fix upstreams docs link
2019-09-12 15:36:52 -07:00
Kris Hicks
de84c81acd Fix upstreams docs link 2019-09-12 15:12:26 -07:00
Luiz Aoqui
94d4825bf2 Merge pull request #6317 from hashicorp/docs-fix-volume-docs
Fix `volume_mount` attribute in the docs and formatting
2019-09-12 16:53:30 -04:00
Luiz Aoqui
507e05b114 docs: fix formatting for volume and volume_mount doc pages 2019-09-12 16:13:04 -04:00
Luiz Aoqui
545054ef99 docs: replace source with volume attribute in volume_mount docs 2019-09-12 16:08:18 -04:00
Tim Gross
15f9fea2c3 dev: expose Consul port 8500 in linux-ui Vagrantfile (#6292) 2019-09-11 14:53:30 -04:00
Tim Gross
c9f7656489 doc: ulimit recommendations for local development (#6311)
The default ulimit for open files on macOS is really small (256),
which leads to "too many open files" errors during plugin launches if
you're running unit tests in `drivers/docker`. Recommend setting
`ulimit -n 1024`.
2019-09-11 14:53:03 -04:00
Mahmood Ali
232295f83f Merge pull request #6294 from hashicorp/c-vagrant-tweaks-20190906
manage dev deps in vagrant
2019-09-11 11:27:21 -07:00
Mahmood Ali
8177d45193 Merge pull request #6080 from lchayoun/bug-6079
Allow dash in environment variable names
2019-09-11 11:17:24 -07:00
Mahmood Ali
97448cf33d Merge pull request #6260 from hashicorp/c-circleci-tweak-20190903
ci: ignore nested pkgs in GOTEST_PKGS_EXCLUDE
2019-09-11 11:17:10 -07:00
Charlie Voiselle
32ad0eef31 Typo fix 2019-09-11 09:13:28 -04:00
Tim Gross
31f91cf4c8 e2e: fixes for race conditions in testing (#6300)
- In script checks, ensure we're running `Exec` against the new running
  allocation and not the earlier stopped one.
- In script checks, allow `Exec` calls to error due to lack of pty when
  we use the exec to kill the task.
- In `utils.go/RegisterAllocs`, force query for allocations to wait on
  wait index returned by registration call.
2019-09-10 13:45:16 -04:00
Tim Gross
ae3488dbac test: expand symlink for temp dir for macOS compatibility (#6303)
On macOS, `os.TempDir` returns a symlinked path under `/var` which is
outside of the directories shared into the VM used for Docker, and
that fails tests using Docker that need that mount. If we expand the
symlink to get the real path in `/private`, we're in the shared
folders and can safely mount them.
2019-09-10 12:20:09 -04:00
Preetha Appan
1b53b72475 Update version 2019-09-09 14:58:40 -07:00
Tim Gross
d62dd486bf upgrade notes for 0.9.5 2019-09-09 14:58:25 -07:00
Mahmood Ali
8055f6ec8c Merge pull request #6304 from hashicorp/d-ns-quota-api
website: document Quota field in ns payloads
2019-09-09 16:54:04 -04:00
Mahmood Ali
2c1c8b08ea website: document Quota field in ns payloads 2019-09-09 13:48:58 -07:00
Mahmood Ali
ea14029f3e website: fix typo 2019-09-09 10:26:08 -07:00
Mahmood Ali
7b978bde38 Merge pull request #6302 from hashicorp/b-fix-nomad-ns-help
fix 'nomad namespace apply' help message
2019-09-09 13:24:45 -04:00
Buck Doyle
2be3748fd1 Convert resources page to Markdown (#6301)
The auto-generation of TOC wasn’t working because the
“auto-linking header tags” described here doesn’t work
if the file isn’t Markdown:
https://github.com/hashicorp/middleman-hashicorp#auto-linking-header-tags
2019-09-09 12:05:16 -05:00
Mahmood Ali
483b10ab0e fix 'nomad namespace apply' help
Named arguments need to preceed positional arguments.
2019-09-09 10:04:41 -07:00
Mahmood Ali
6d2b3f68e4 docs: mark consul connect integration as beta 2019-09-09 09:59:55 -07:00
Mahmood Ali
0a546833f0 Merge pull request #6299 from hashicorp/d-0.10.0-beta1-link
website: Link to 0.10.0-beta1 release
2019-09-09 12:06:26 -04:00
Mahmood Ali
8ae94cc79d website: Link to 0.10.0-beta1 release 2019-09-09 09:05:06 -07:00