Repository navigation
Releases
Releases · JuanTorchia/gmm-caddy-vscode
Caddyfile v0.1.0
Added
caddyfilelanguage forCaddyfile,Caddyfile.*,Caddyfile-*,*.caddyfile,*.Caddyfileand*.caddy, and for any file a workspace Caddyfile imports.- TextMate grammar: sites, snippets, named routes, directives, matchers, placeholders, environment variables, strings, backticks, heredocs, numbers and comments.
- Catalog of Caddy v2.11.9 generated by
npm run catalog:generatefrom the caddyserver.com docs (45 directives with their subdirectives, 41 global options, 17 request matchers, 139 placeholders and shorthands) and the Caddy source (directive order, accepted subdirectives, HTTP placeholders). - Language server diagnostics: unbalanced braces, strings and heredocs; the global options block out of place; site addresses Caddy rejects and duplicate sites; global options in sites, directives in the global options block, site-only directives (
tls,log,bind,handle_errors) insideroute/handle; unknown directives, options, subdirectives and matchers (warnings, for plugins); matcher definitions, duplicates and undefined@matcherreferences; snippets and named routes (also from imported files); missing imported files; unknown{http.request.*}placeholders; renamed directives with a quick fix. - TLS lint against the Mozilla Server Side TLS guidelines (6.0,
intermediateormodern) fortls { protocols … ciphers … }, HSTSmax-age,insecure_secrets_logandtls_insecure_skip_verify, with quick fixes. Rule IDs are shared with NGINX Config, Apache Config and HAProxy Config. - Security lint: admin API on a public interface, plaintext
basic_authpasswords,tls internal/local_certson public names, on-demand TLS withoutask, upstreams taken from the Host header. # gmm-lint-disable-next-line [ids]and# gmm-lint-disable-line [ids]comments.- Certificate insights for
tls <cert> <key>andca_root: hover with subject, SANs, issuer, validity, key and chain; expiry, key match, site addresses outside the SANs and chain order checks; Open in CertView CodeLens when CertView is installed. - Completion of directives, global options, subdirectives, matchers, named matchers, snippet names and placeholders; hover docs; outline; folding; navigation for imports, snippets, named routes, matchers and certificate files.
- A formatter that gives the result of
caddy fmtwithout the binary and never adds or removes lines. - Optional commands that use an installed Caddy: check with
caddy adapt --validate, show the adapted JSON, hash a password forbasic_auth. - Snippets for common sites, matchers, snippets, redirects, basic auth and headers.