Commit graph

10598 commits

Author SHA1 Message Date
Pedro Algarvio
823886028b
Merge 3006.x into 3007.x 2024-02-21 19:14:47 +00:00
Salt Project Packaging
ce9d09bc9c
Release v3006.7 2024-02-20 22:04:07 +00:00
Pedro Algarvio
3b24505b3a Remove deprecated code 2024-02-07 08:51:31 +00:00
jeanluc
0b129443e3 Update enable_ssh_minions docs after PR 65646 2024-02-02 14:55:41 -07:00
Pedro Algarvio
e5d3ef7ff7
Merge 3006.x into 3007.x 2024-02-01 09:00:02 +00:00
Pedro Algarvio
ede09ef43e
Fix pre-commit 2024-01-31 21:12:34 +00:00
Pedro Algarvio
0d7512b824 Release v3006.6
-----BEGIN PGP SIGNATURE-----
 
 iQGzBAABCgAdFiEEEIV//dP5Hq5XeiHWZMu8gXPXaz8FAmW6s70ACgkQZMu8gXPX
 az86nQv+NgLecuQ+zUa+YQzK8zCAXS0pHzqVjNmRSbdYr91aUtQhHSmlH9LAi+YK
 tDa9C7eVD3PNVstxD9DBFP/uVDY20Lls78GgcuE+BLsTe1LHX+YARCy2cZmZq5ft
 CzdAyty0pcwGmJA9aeOYD04bdL9Ffq7xALt/jK7/iuFFAvx99SUAfoqgIA4d+5DX
 sJpA33mApRaQ0TMUszMjyDeMfvD8b0X8VR3VMGvtFLadvP+ha4PAX8TaBnFbBcEJ
 mhUNYuOIpvm+nfXCACZNQe++4XSshpnNUDUjQ/y7cCG1ijioxBz9GdFu63wjTLNz
 ZEkaH18HDTlYQx0fJEK1HIDEyxiEa8Xu+Dw1cJdyZia5oGyoc6jNMYFmc0OnF/8W
 EaqlzIazTqx+puMWThbQp3sytTXhcCjb3qhlndujhrscdfk9dWdaS0Mji4CVNkHy
 ZMH16VOmuh//muBi8C1mDClv2ayrBSK5oWxNm8j5T+8+pgvBdDM6iFSA4O6U0juT
 vY+U7xnD
 =HOve
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE0pCPs6gjsPqzvSH1uza/ZYSimP8FAmW6tKAACgkQuza/ZYSi
 mP86DA//ROPz8A5OYtsJEZoPbzUqE3w3iIK6udcIn5lgw6GfCQ2n5AzRU3jecNNB
 caDkYHKz5p4yRdoqHiGEpU5Y12R28EP7IdDnYMqOskZwubrwnxzqxHJh3scGpVQ7
 VPDNAhtAn6lcHtq07Al2YPCaCk3iGZjABz251H7qWcWQcv0nyWGQnYYpBlOJTzk6
 gA5G/TJfZDPw2cdBQqcL9p2Dq9POED08DcuX7q6FR46hxYTpijg/0sL+Y+t2HMr5
 bZePEiigEkbnlJ6ssoQ9aCvUBz6E1sCNy4pfXc0IVx+j7x67gldpK5+ByGcMHiOj
 S1tXqQzTnaLpUcepfUD5Qe1VPjfuk94QUF8UdicJ8u72iTkQKM2n9IYeybDxmoj9
 iKrhw0fxOLd5afwzy8/NqLXHSH6sfqpRHKcOAwyg4L0aOZqdlsjFNxp9TMN6xami
 XRlLLSqWDCvsSzw5btbYJ20zjv+TGsleDyFkJMDkeQlr/oCcWza8cakq5JnHX38y
 rEDm5tMTcxX/GOGf3qexePU4Ca8tGkdKuss/QlBeuRSH0djzqtUrEjcQJAu14C/3
 nY5F5Z6vgmwSK5l+wnH3cEx9fDqryPRFJCygaQ5yhl1nSpDtzRuDkYYgbU0JOYxA
 cBJQrKndI/sezDC2T6rmS+buVGLTQasAXvOIg3UGw6ynG95LZ7I=
 =PsFs
 -----END PGP SIGNATURE-----

Merge upstream 3006.6 into 3006.x
2024-01-31 20:59:12 +00:00
Pedro Algarvio
297e2003b1
Merge 3005.x into 3006.x 2024-01-31 18:01:15 +00:00
Salt Project Packaging
b1fa82b9a8
Release v3006.6 2024-01-26 12:06:14 +00:00
Alyssa Rock
e39b65aa4b Add man pages 2024-01-24 14:38:29 -07:00
Alyssa Rock
066ab8fd5a More revisions 2024-01-24 14:38:29 -07:00
Alyssa Rock
20aff06da5 Add minor revisions requested by Shane 2024-01-24 14:38:29 -07:00
Alyssa Rock
ac52f60ee3 Create 3006.5 release notes and update 3005 changelog 2024-01-24 14:38:29 -07:00
Pedro Algarvio
6694a7a273
Merge 3006.x into 3007.x 2024-01-19 07:40:21 +00:00
Shane Lee
c45a5e865e Fix pre-commit failures 2024-01-18 10:21:22 -07:00
Alyssa Rock
e3c8b45715 Add new maintenance policy 2024-01-18 10:21:22 -07:00
Megan Wilhite
81e15ea6c9 Migrate package tests to the main test suite 2024-01-17 16:58:39 -07:00
Salt Project Packaging
257c067ef6
Release v3007.0rc1 2024-01-02 21:47:46 +00:00
Daniel A. Wozniak
887a9f30c8 Fix another spelling wart 2023-12-28 00:29:50 -07:00
Daniel A. Wozniak
a31597fea7 Fix up docs 2023-12-28 00:29:50 -07:00
Daniel A. Wozniak
eee8396473 Fix review comments 2023-12-28 00:29:50 -07:00
Daniel A. Wozniak
fdbb4ed333 Update transport docs with websockt transport 2023-12-28 00:29:50 -07:00
Daniel A. Wozniak
15f44f2d12 Fix up code review spelling grammar 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
a49554a4d3 Fix another code review grammar issue 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
80a6efb608 Fix up issues found in code revieww 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
bc4a8390c8 Add master-cluster to doctree 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
39197b9b40 Add cluster config settings to docs 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
aaca103604 wip docs for master cluster 2023-12-18 14:30:58 -07:00
Daniel A. Wozniak
c7d7454056 Fix pre-commit 2023-12-18 04:33:53 -07:00
mrx
b874028705 Update index.rst
update syntax
2023-12-18 04:33:53 -07:00
mike.reider
24e7991f6b sdb doc example subkeys 2023-12-18 04:33:53 -07:00
jeanluc
56ad1ec942 Fix saltext vault/pushover docs
* the correct organization is `salt-extensions`, not `saltstack`
* the release file is strict GitHub-flavoured Markdown only
2023-12-18 03:42:28 -07:00
Daniel Wozniak
21391fe7ba Revert "URL auditor with URL fixes"
This reverts commit d07172cc0e.
2023-12-17 23:13:58 -07:00
ScriptAutomate
d07172cc0e URL auditor with URL fixes 2023-12-17 22:30:41 -07:00
Clay Sweetser
3e491c3416 Remove TOC for Returners from Configuration page.
Remove the table of contents for the "Returners" page from the "Configuration" page.
2023-12-16 04:33:01 -07:00
Clay Sweetser
433642f21f Add TOC for Returners to Remote Execution page
Add a table of contents for the "Returners" page to the "Remote Execution" page.
2023-12-16 04:33:01 -07:00
nicholasmhughes
22a160e791 adding another/different example use case for clarity 2023-12-15 21:46:44 -07:00
nicholasmhughes
a05205bb4f use sentence case instead of title case for headings 2023-12-15 21:46:44 -07:00
nicholasmhughes
2304b355b1 fixes saltstack/salt#65222 document using slots for contents via function call in file state modules 2023-12-15 21:46:44 -07:00
jeanluc
f2121e5ade
Rewrite vault core, issue AppRoles to minions (#62684)
* Rewrite vault core, orchestrate AppRoles for minions

This commit represents a fundamental rewrite in how Salt interacts with
Vault. The master should still be compatible with minions running the
old code. There should be no breaking changes to public interfaces and
the old configuration format should still apply.

Core:
- Issue AppRoles to minions
- Manage entities with templatable metadata for minions
- Use inbuilt Salt cache
- Separate config cache from token cache
- Cache: introduce connection-scope vs global scope

Utility module:
- Support being imported (__utils__ deprecation)
- Raise exceptions on queries to simplify response handling
- Add classes to wrap complexity, especially regarding KV v2
- Lay some groundwork for renewing tokens

Execution module:
- Add patch_secret
- Add version support to delete_secret
- Allow returning listed keys only in list_secret
- Add policy_[fetch/write/delete] and policies_list
- Add query for arbitrary API queries

State module:
- Make use of execution module
- Change output format

Docs:
- Update for new configuration format
- Correct examples
- Add configuration examples
- Add required policies

* Fix linting for rewritten vault integration

* Add pytest unit tests for utils.vault, fix found issues

* Fix old vault runner tests

* Rewrite vault sdb tests, migrate to pytests

* Adapt vault ext_pillar tests

* Adapt vault execution module tests, migrate to pytests

* Add more vault execution module unit tests

* Support python <3.7 (vault util), time-independent tests

* Add/migrate vault runner unit tests (pytest)

* Add vault state module pytests

* Fix tests lint

* Refactor Vault container fixture, move to session scope

* Fix for existing vault execution/sdb module integration tests

* Improve existing vault runner integration tests

* Fix vault test support, add list policies

* Add more functional execution module tests, fix deprecated warning

* Refactor vault pytest support

* Add integration tests, improve/fix caching/issue_params

* Improve caching behavior, fix tests

* Always use session cache as well
* Also flush session cache when requested
* Make KV metadata caching behavior configurable
* Update tests to account for changes from prev commit

* Allow to autodiscover platform default CA bundle

* Remove runner approle param overrides

There is no simple way to ensure they are kept.

* Add clear_cache runner function

* Also manage token metadata for issued secret IDs

* Cleanup tests

* Cleanup code, pylint logging suggestions

* Do not always invalidate config when verify=default

* Ensure concatted metadata lists are sorted

* Add changelog (partly)

* Work with legacy peer_run configuration as well

* Consume a token use regardless of status code

* Correct verify semantics

* Refine token uses handling, add changelog/tests for old issues

* Add changelog for main features

* Add test for issue 58580

* Fix vault docs

* Provide all old make_request functionality, add tests

* Allow token use override, add docstrings to query funcs

* Simplify config_location merge

* Cleanup

* Fix make_request warning

* Attempt to fix memory issues during CI test run

* Increase documented version

* Improve lease handling

* Refine lease ttl handling/add token lifecycle management

* Fix docs build

* Adapt formatting

* assert what you get against what you expect
* drop empty parentheses after wrapper
* use `is` to compare against strictly boolean vars

* Fix issue param overrides

* during pillar rendering, they were always reset by the master (for
  AppRoles)
* overrides were only respected for some settings (AppRoles)
* old config syntax was using the old syntax internally (tech debt)

* Introduce session-scoped cache

* Tokens with a single use left are unrenewable

* Allow override of flushing of cached leases during lookup

* Refactor cache classes, save lease data

* Rename session token cache key

* Add lease management utility

* Fix runner integration tests

after renaming the token cache key

* Do not overwrite data of cached leases after renewal

* Pass token_lifecycle to minions

* Do not fail syncing multiple approles/entities with pillar templates

* Ensure config cache expiration can be disabled

* Rename changelog files (.md)

* Declare vaultpolicylexer as parallel read safe

* Correct meta[data] payload key

For tokens it is `meta`, but for secret IDs, `metadata`.

* Reuse TCP connection

* Refactor utils module

* Ensure client is recreated after clearing cache

* Always use unwrap_client config as expected server

This should fix the test failure in the runner integration test
TestAppRoleIssuance::test_server_switch_does_not_break_minion_auth

* Ensure client is recreated after clearing cache 2

* Simulate patch for KV v1 or missing `patch` capability

* Add `patch` option to Vault SDB driver

* Reduce lease validity when revocation fails

* Extract AppRole/Identity API from runner into utils

* Revoke tokens, fire events, improve cache/exception handling

* Tokens (and therefore associated leases) are revoked when cleared by default
* It's possible to disable clearing cache when a perfectly valid token
  is available, but a PermissionDeniedError is encountered.
* UnwrapExceptions always cause an event to be fired
* It's possible to enable sending of events when
    a) cache is cleared
    b) a lease is requested from cache, but it is/will be invalid
* A VaultAuthException does not immediately lead to clearing
  the connection cache
* get_authd_client and others: multiple small enhancements and fixes

* Allow updating cached config w/o closing session

* Homogenize funcs, update docs, cleanup

* Minor internal fixes

`is_valid_for` is present on all lease-like objects, while `is_valid`
specifically should account for more, e.g. the number of uses.

The Vault API does not return 404 when a lookup fails.

* Add release note

* Address review remarks

* Fix release notes

* Remove loading minion_mods from factory

* Address other review remarks

* Add inline specification of trusted CA root cert

* Small QoL additions

* Fix lint

* Fix lint for Python >=3.8 support

* Add missing fixes

* Fix unit tests

In some cases, the `spec` calls were failing because the underlying
object was already patched

---------

Co-authored-by: Thomas Phipps <tphipps@vmware.com>
2023-12-15 21:42:08 -07:00
Zhiwei Liang
e9cb14c91e Add backups_enabled option; improve docs 2023-12-15 01:17:27 -07:00
Pedro Algarvio
e3ba31dc7a
Merge 3006.x into 3007.x 2023-12-14 11:32:20 +00:00
Megan Wilhite
d453007a8f Migrate package tests to the main test suite 2023-12-12 15:29:41 -07:00
Salt Project Packaging
0472fd381e
Release v3006.5 2023-12-12 18:03:35 +00:00
Daniel A. Wozniak
d7549bd155 Fix docstring 2023-12-10 21:06:45 -07:00
Daniel A. Wozniak
7a366444ab Fix pre-commit 2023-12-10 18:22:28 -07:00
Thomas Merkel
788b922d34 Update doc/topics/tutorials/gitfs.rst
Co-authored-by: Caleb Beard <53276404+MKLeb@users.noreply.github.com>
2023-12-10 16:45:39 -07:00
Thomas Merkel
f933e66a77 doc: gitfs_remotes provide additional ordering information
The user should be informed that a state in a file will overrule a state
in an directory for gitfs_remotes because the remotes are merged
together to one structure.

An extra example should illustrate that it.
2023-12-10 16:45:39 -07:00
Benjamin Drung
b9b0c2462b doc: Exclude documentation_options.js from default theme
`documentation_options.js` from the default theme sets the option
`URL_ROOT` to:

```
document.getElementById("documentation_options").getAttribute('data-url_root')
```

This requires that the script element for `documentation_options.js`
includes the tag `id="documentation_options"` and sets the
`data-url_root` tag. Otherwise evaluating `URL_ROOT` will fail and
building the documentation during the Debian package build will fail:

```
dh_sphinxdoc: error: DOCUMENTATION_OPTIONS does not define URL_ROOT
```

The variable `DOCUMENTATION_OPTIONS` is directly set `layout.html` and
therefore `documentation_options.js` does not need to be included. So
just exclude it.

Signed-off-by: Benjamin Drung <benjamin.drung@ionos.com>
2023-12-10 16:23:20 -07:00
Ari Maniatis
0b423e443f The script attribute is not userdata 2023-12-10 15:12:23 -07:00