docs(code-samples): fix invalid CLI flags and YAML in samples#1282
docs(code-samples): fix invalid CLI flags and YAML in samples#1282ekline[bot] wants to merge 2 commits into
Conversation
Correct factual inaccuracies in documentation code samples, verified against the Okteto CLI source and the canonical Okteto Manifest schema: - manifest-migration.mdx: replace non-existent 'okteto deploy --build' flag with accurate '--no-build' behavior - ssh-server.mdx: fix 'ssh -P' to lowercase '-p' port flag - okta.mdx: fix invalid YAML indentation on 'mapping:' - crds.mdx: fix invalid YAML indentation on 'spec:' ekline[bot] <202747777+ekline[bot]@users.noreply.github.com> Signed-off-by: ekline[bot] <202747777+ekline[bot]@users.noreply.github.com>
✅ Deploy Preview for okteto-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
| - `okteto deploy`: deploys your dev environment. | ||
| - `okteto deploy --build`: forces a build of the defined images before deploying the dev environment. | ||
| - `okteto deploy`: builds any pending images and deploys your dev environment. | ||
| - `okteto deploy --no-build`: deploys your dev environment without re-building the defined images. |
There was a problem hiding this comment.
okteto deploy --build does not exist — the deploy command only defines --no-build (confirmed at okteto/cmd/deploy/deploy.go:321). okteto deploy already builds pending images by default, so this line now documents the real --no-build behavior instead.
|
|
||
| ```console | ||
| $ ssh -P PORT localhost | ||
| $ ssh -p PORT localhost |
There was a problem hiding this comment.
The OpenSSH client uses lowercase -p for the port; uppercase -P is not a valid ssh option (it is the scp/sftp port flag), so the sample errored as written. Confirmed against OpenSSH ssh(1).
| issuer: https://dev-6093102.okta.com | ||
| authorization: https://dev-6093102.okta.com/oauth2/v1/authorize | ||
| mapping: | ||
| mapping: |
There was a problem hiding this comment.
mapping: was indented 5 spaces while its sibling keys (enabled, clientId, endpoints) sit at 4 — invalid YAML that fails to parse. De-indented to 4 spaces so it nests correctly under openid:.
| name: gcp-credentials-config | ||
| namespace: okteto | ||
| spec: | ||
| spec: |
There was a problem hiding this comment.
spec: was indented 1 space, making it inconsistent with the top-level keys apiVersion/kind/metadata at column 0 — invalid YAML, so kubectl apply would fail. De-indented to column 0, matching the parallel AWS DynamicConfig block in this same file.
|
@ekline-ai these fixes can be also included in the different documentation versions available within the folder |
Apply the same four code-sample corrections from this PR to all 12 versioned snapshots (versions 1.34 through 1.45), as requested in review: - manifest-migration.mdx: replace non-existent 'okteto deploy --build' flag with accurate '--no-build' behavior - ssh-server.mdx: fix 'ssh -P' to lowercase '-p' port flag - okta.mdx: fix invalid YAML indentation on 'mapping:' - crds.mdx: fix invalid YAML indentation on 'spec:' ekline[bot] <202747777+ekline[bot]@users.noreply.github.com> Signed-off-by: ekline[bot] <202747777+ekline[bot]@users.noreply.github.com>
|
Done — I backported all four fixes to every version under `versioned_docs/` (1.34 through 1.45). Pushed in a2f3120: 48 files changed (4 files × 12 versions). Per-version, each snapshot now carries the same corrections as the current-version files:
I verified all four buggy patterns are now absent across |
|
Done. Reply posted to the reviewer. Backport completeThe reviewer's request — apply the same fixes across the versioned docs — is done and pushed to the open PR. Commit
How I verified:
Process: routed through the PR skill in update mode — pre-commit style review ran (0 changes; edits are inside code blocks or an already-reviewed bullet), committed with DCO sign-off, pushed to update the existing PR. No new PR, no title/body or reviewer changes. A confirmation reply is posted on the reviewer's comment. One note carried over from before: the Slack summary to #C0APP7FMXKM still can't be delivered — the bot isn't a member of that channel and lacks the |
Context
This PR fixes factual inaccuracies in documentation code samples, verified against the current Okteto CLI source (
okteto/cmd/) and the canonical Okteto Manifest JSON Schema (okteto/schema.json). Cosmetic and stylistic changes are intentionally out of scope.Scan summary
docs/src/contentanddocs/src/tutorials)Fixes
docs/src/content/reference/manifest-migration.mdxokteto deploy --build, a flag that does not exist — the deploy command only defines--no-build(okteto/cmd/deploy/deploy.go:321)okteto deploybuilds pending images by default;--no-buildskips the rebuilddocs/src/content/self-hosted/install/auth/okta.mdxmapping:YAML examplemapping:indented 5 spaces vs sibling keys at 4 — invalid YAML that fails to parsemapping:to 4 spaces to align withenabled/clientId/endpointsdocs/src/content/reference/ssh-server.mdxssh -P PORT localhost— OpenSSH uses lowercase-pfor port;-Pis invalid forsshso the command errorsssh -p PORT localhostdocs/src/content/self-hosted/manage/crds.mdxgcp-cloud-credential.yamlexamplespec:indented 1 space — invalid YAML;kubectl applyfails. The parallel AWS block hasspec:at column 0spec:to column 0Out of scope (not fixed)
docs/src/tutorials/optimize-your-development-environment.mdxhas a malformed Markdown link missing its closing). This is a prose link, not a code sample, so it is outside this review's scope — flagged for a separate links/build fix.Deferred files
None.
📝 Created with EkLine · View session
ekline[bot] <202747777+ekline[bot]@users.noreply.github.com>