Skip to content

Releases

Caddyfile v0.1.0

Choose a tag to compare

@github-actions github-actions released this 05 Dec 11:18
cb9d116

Added

  • caddyfile language for Caddyfile, Caddyfile.*, Caddyfile-*, *.caddyfile, *.Caddyfile and *.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:generate from 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) inside route/handle; unknown directives, options, subdirectives and matchers (warnings, for plugins); matcher definitions, duplicates and undefined @matcher references; 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, intermediate or modern) for tls { protocols … ciphers … }, HSTS max-age, insecure_secrets_log and tls_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_auth passwords, tls internal/local_certs on public names, on-demand TLS without ask, 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> and ca_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 fmt without 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 for basic_auth.
  • Snippets for common sites, matchers, snippets, redirects, basic auth and headers.