Skip to content

Commit 71d2010

Browse files
authored
Merge pull request #78 from psadmin-io/staging
Release v0.3.0 — first public release
2 parents 8751415 + a08f2df commit 71d2010

76 files changed

Lines changed: 8438 additions & 1559 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: Bug report
2+
description: Report a defect in psa-cli
3+
labels: ["bug"]
4+
body:
5+
- type: textarea
6+
id: what-happened
7+
attributes:
8+
label: What happened?
9+
description: A clear description of the bug, including the command you ran.
10+
placeholder: |
11+
I ran `psa dpk apply --summary` and ...
12+
validations:
13+
required: true
14+
15+
- type: textarea
16+
id: expected
17+
attributes:
18+
label: Expected behavior
19+
validations:
20+
required: true
21+
22+
- type: textarea
23+
id: reproduce
24+
attributes:
25+
label: Steps to reproduce
26+
placeholder: |
27+
1. Run `psa config setup --yes`
28+
2. Run `psa ...`
29+
3. Observe ...
30+
validations:
31+
required: true
32+
33+
- type: input
34+
id: psa-version
35+
attributes:
36+
label: psa-cli version
37+
description: Output of `psa --version`
38+
placeholder: psa version 0.3.0
39+
validations:
40+
required: true
41+
42+
- type: input
43+
id: peopletools
44+
attributes:
45+
label: PeopleTools version
46+
placeholder: 8.62.04
47+
validations:
48+
required: false
49+
50+
- type: input
51+
id: os
52+
attributes:
53+
label: Operating system
54+
placeholder: Oracle Linux 9.3
55+
validations:
56+
required: false
57+
58+
- type: input
59+
id: python
60+
attributes:
61+
label: Python version
62+
description: Output of `python --version`
63+
placeholder: Python 3.11.7
64+
validations:
65+
required: false
66+
67+
- type: textarea
68+
id: logs
69+
attributes:
70+
label: Logs / output
71+
description: Paste relevant CLI output. Run with `-v` for verbose mode.
72+
render: shell
73+
validations:
74+
required: false

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: Security vulnerability
4+
url: https://github.com/psadmin-io/psa-cli/blob/main/SECURITY.md
5+
about: Please report security issues privately, not via public issues.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Feature request
2+
description: Suggest a new feature or enhancement
3+
labels: ["enhancement"]
4+
body:
5+
- type: textarea
6+
id: problem
7+
attributes:
8+
label: What problem are you trying to solve?
9+
description: Describe the pain point or workflow this would improve.
10+
validations:
11+
required: true
12+
13+
- type: textarea
14+
id: proposal
15+
attributes:
16+
label: Proposed solution
17+
description: How could psa-cli address this?
18+
validations:
19+
required: true
20+
21+
- type: textarea
22+
id: alternatives
23+
attributes:
24+
label: Alternatives considered
25+
description: Other approaches you've thought about.
26+
validations:
27+
required: false
28+
29+
- type: textarea
30+
id: context
31+
attributes:
32+
label: Additional context
33+
description: Screenshots, related issues, links, etc.
34+
validations:
35+
required: false

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
## Summary
2+
3+
<!-- What does this PR change, and why? -->
4+
5+
## Changes
6+
7+
<!-- Bullet list of notable changes -->
8+
9+
## Test plan
10+
11+
<!-- How did you verify this works? -->
12+
13+
- [ ] `pytest` passes
14+
- [ ] `ruff check .` passes
15+
- [ ] Manually verified on a PeopleSoft environment (describe below)
16+
17+
## Related issues
18+
19+
<!-- Closes #N, Refs #N -->

.github/workflows/docs.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Docs
2+
3+
on:
4+
push:
5+
branches: [main]
6+
paths:
7+
- docs/**
8+
- mkdocs.yml
9+
- .github/workflows/docs.yml
10+
workflow_dispatch:
11+
12+
permissions:
13+
contents: write
14+
15+
jobs:
16+
deploy:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v4
20+
with:
21+
fetch-depth: 0
22+
23+
- name: Set up Python
24+
uses: actions/setup-python@v5
25+
with:
26+
python-version: "3.12"
27+
28+
- name: Install MkDocs Material
29+
run: pip install mkdocs-material
30+
31+
- name: Deploy to GitHub Pages
32+
run: mkdocs gh-deploy --force

.github/workflows/test.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Test
2+
3+
on:
4+
push:
5+
branches: [main, staging]
6+
pull_request:
7+
branches: [main, staging]
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
python-version: ["3.9", "3.10", "3.11", "3.12"]
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Set up Python ${{ matrix.python-version }}
21+
uses: actions/setup-python@v5
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
25+
- name: Install uv
26+
uses: astral-sh/setup-uv@v3
27+
with:
28+
enable-cache: true
29+
30+
- name: Install dependencies
31+
run: uv sync --extra dev
32+
33+
- name: Lint with ruff
34+
run: uv run ruff check .
35+
continue-on-error: true
36+
37+
- name: Run tests
38+
run: uv run pytest -v

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,6 @@ htmlcov/
4141
# Distribution
4242
*.tar.gz
4343
*.whl
44+
45+
# MkDocs build output
46+
site/

CHANGELOG.md

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# Changelog
2+
3+
All notable changes to psa-cli are documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## [0.3.0] — 2026-05-12
9+
10+
**First public release.** psa-cli is now open source under the MIT license. This release collapses the un-tagged 0.2.1 through 0.2.5 development work into the first public cut.
11+
12+
> :warning: **Pre-1.0 / beta.** Not yet recommended for production. The CLI surface, config schema, and command behavior may change before 1.0.
13+
14+
### Highlights
15+
16+
- **Domain lifecycle**`psa domain list / status / start / stop / restart / bounce / compare` with Rich-rendered output, JSON mode, quiet/verbose flags, and `--force` confirmation skips.
17+
- **DPK workflow** — end-to-end PeopleSoft DPK provisioning: `psa dpk stage → setup → init → sync → apply → cleanup`, including a 3-tier Hiera layout, `dpk module install` for custom Puppet modules, `dpk facts` for site facts, and `dpk lookup` for hiera key resolution.
18+
- **`psa dpk apply --summary`** — filtered, readable Puppet apply output with surfaced errors, exit-code mapping, and ANSI handling.
19+
- **Discovery**`psa discover` finds local PeopleSoft domains and can report results to a configured API.
20+
- **Configuration**`psa config setup` (interactive + `--yes` non-interactive), `psa config show`, `psa config set` for individual keys, with auto-detection of `PS_*` and `DPK_*` paths.
21+
- **Resilient file operations**`SudoFileOps` abstraction transparently cascades to `sudo` when the runtime user lacks write permission, with timeout-driven diagnostics for missing passwordless sudo.
22+
23+
### Added since v0.2.0
24+
25+
#### Domain
26+
- `psa domain compare` replaces `psa domain drift`; archive picker, archive age display, raw-config diff that handles `%PS_SERVDIR%` vars
27+
- Global `-q/--quiet` / `-v/--verbose` flags; Rich spinners
28+
- `--force/-f` flag (renamed from `--yes/-y`) on destructive operations
29+
- `psa domain status --json` with full process detail
30+
- Web tier renamed `pia``web`; status/start/stop route through `psadmin -w` for PT 8.62
31+
- Graceful already-stopped / already-purged handling
32+
33+
#### DPK
34+
- `psa dpk` command group consolidates DPK provisioning
35+
- `psa dpk module install <org/repo>` with `--branch`, `--dry-run`, `--as <name>`
36+
- `psa dpk facts` (writes to `/etc/`, not the DPK install tree)
37+
- `psa dpk init` auto-creates config, generates `hiera.yaml` (eyaml backend), 3-tier hiera layout
38+
- `psa dpk lookup` for hiera key resolution
39+
- `psa dpk apply --summary` mode + puppet error surfacing + stderr scanning + Rich bypass for raw streams
40+
- `psa dpk apply` auto-sudo to root unless already root or `runtime_user`
41+
- `psa dpk sync` with `SudoFileOps` permission fallback
42+
- `psa dpk status --json` + manifest parsing
43+
- `psa dpk cleanup --domains-only` for scoped domain+service teardown
44+
- `psa dpk stage --version` and `--dry-run` fix
45+
- Split `DPK_BASE` vs `DPK_HOME` with `--dpk-cust-home` flag
46+
- EL 9+ ncurses prereq: per-lib symlink fallback
47+
- OL8/RHEL8+ libnsl in DPK prereq checks
48+
- DPK repo commands: `init`, `status`, `list`
49+
50+
#### Config
51+
- `psa config set` for individual config keys (`ps_cfg_home`, `ps_base`, `ps_home`, etc.)
52+
- `psa config show` groups DPK paths, uppercases path labels
53+
- `DPK_CUST_HOME` foundation (renamed from `PSA_CUST`)
54+
- `psa ops setup` moved out of `config` group (hidden by default)
55+
56+
#### Quality / internal
57+
- Minimum Python bumped to 3.9
58+
- `SudoFileOps` centralized file operations
59+
- Resilient domain discovery (skips permission errors, scopes by type)
60+
- Test fixes: verbosity reset, tmadmin process-table parsing, "Started" prcs pattern
61+
- Demo-lab regression fixes: status parser, PIA paths, empty errors, PS path auto-detect
62+
63+
### Removed
64+
65+
- `psa cache` and `psa secrets` (stub commands that were never wired into the CLI)
66+
- `psa domain drift` (replaced by `psa domain compare`)
67+
- `psa ops register` (folded into `psa ops setup`)
68+
- `start/stopPIA.sh` shim (now routes through `psadmin -w`)
69+
- `io_base` config key
70+
71+
### Known limitations
72+
73+
- **Encrypted password leak in JSON**`psa domain --json` includes raw config content that contains encrypted password fields (`ConnectPswd`, `OprPswd`, etc). Values are encrypted, not cleartext, but should not appear in piped output. Tracked as issue #23, fix planned for 0.4.
74+
- **`psa ops` is hidden** — depends on the private psadmin.io ops API; not intended for general public use in this release.
75+
- **`psa kit` is gated** — requires `enable_psa_kit: true` in config and SSH access to the private `psadmin-io/psa-kit` repository.
76+
- Tested against **PeopleTools 8.62**; older versions may work but are unverified.
77+
- No PyPI release yet — install from the GitHub release wheel or from source.
78+
79+
### Compatibility
80+
81+
- Python 3.9, 3.10, 3.11, 3.12
82+
- Linux (Oracle Linux 8/9, RHEL 8/9 covered; other distros likely fine)
83+
- PeopleTools 8.62
84+
85+
[0.3.0]: https://github.com/psadmin-io/psa-cli/releases/tag/v0.3.0

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 psadmin.io
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)