Release »nctl.0.7.1«

Vollendet
09/24/23 15:11:54
Released
nctl.0.7.1
Projekt
nctl
Titel
control nginx configurations with backends, snippets and scripts in style!
Kategorie
bash (27)
Tags
web-server(3), cfg(12), nginx(3), good-ux(3), console(22)
Maintainer
Pieli
Src
unveröffentlicht
Abhängigkeiten

Das ist eine produktive Release von nctl.

nctl's own usage

nctl <CMD> <HENDL> [<CLONE>] [external] - mache ein wenig herum mit nginx's virtuellen horsts

$#> nctl build [<HENDL>]           – baue alle/eine externe für nginx-HENDL-Konfiguration(en), nicht nur für <HENDL>
$#> nctl cat [<HENDL>] [external]  – zeigt interne/externe Konfigurationen für nginx-HENDL <HENDL>
$#> nctl clone [<HENDL>] [<CLONE>] – klont eine nginx-HENDL-Konfiguration von <HENDL> zu <CLONE>
$#> nctl del [<HENDL>]             – löscht nginx-HENDL-Konfiguration für <HENDL>
$#> nctl edit [<HENDL>]            – editiert nginx-HENDL-Konfiguration für <HENDL> im Liebling-Editor
$#> nctl start [<HENDL>]           – fügt neue nginx-HENDL-Konfiguration für <HENDL> hinzu
$#> nctl reset                     – setzt alles zurück auf Anfang
$#> nctl set [<HENDL>] [<KEY>] [<CMD>] [<VAL>] – setzt Schlüssel <KEY> der internen/externen Konfiguration von nginx-HENDL <HENDL> auf <VAL>
$#> nctl start [<HENDL>]           – nimmt nginx-HENDL <HENDL> online
$#> nctl status [<WHAT>]           – zeigt Status von nginx-HENDL <HENDL>
$#> nctl stop [<HENDL>]            – nimmt nginx-HENDL <HENDL> offline
$#> nctl user [<HENDL>] [<KEY>] [<CMD>] [<VAL>] – hantiert mit ncsa-Nutzern für nginx-HENDL-Konfigurationen.

Ready. (nctl v0.6.3-r1)

nctl's own nginx.conf

# ----------------------------------------------------------------------------
# /etc/nginx/nginx.conf
# Last Update: 09-13-2023 11:00:41Z by nctl
# Copyright (c) 2023 rundfunk IT services, <rundfunk(at)pieli(dot)net>
# ----------------------------------------------------------------------------

user nginx;

# Set number of worker processes automatically based on number of CPU cores.
worker_processes auto;

# Enables the use of JIT for regular expressions to speed-up their processing.
pcre_jit on;

# Configures default error logger.
error_log /var/log/nginx/error.log warn;

# Includes files with directives to load dynamic modules.
include /etc/nginx/modules/*.conf;

events {
  worker_connections 1024;
}

http {
  include /etc/nginx/defaults.d/mime.types;

  # nctl brings standards to the mix
  include /etc/nginx/defaults.d/standards.conf;

  # Enable gzipping of responses.
  gzip on;

  # Set the Vary HTTP header as defined in the RFC 2616. Default is 'off'.
  gzip_vary on;

  # Specifies the main log format.
  include /etc/nginx/defaults.d/logging.conf;

  # Includes pull in before additional config.
  include /etc/nginx/defaults.d/pullInBefore.conf;

  # Includes pull in default config.
  include /etc/nginx/defaults.d/http_standard_wartung.conf;

  # Includes virtual hosts configs.
  include /etc/nginx/servers.d/*.conf;

  # Includes pull in after additional config.
  include /etc/nginx/defaults.d/pullInAfter.conf;
}

nctl's /etc/nginx-structure

/etc/nginx
├── auth.d          # where the ncsa auth files are kept
├── backends.d      # where main serving cfg snippets are kept
├── cfgs.d          # where nctl's server configs are kept
├── cmds.d          # where nctl's server command snippets are kept
├── defaults.d      # where nctl has banned nginx's main config files
├── modules         # where nginx stores module cfgs
├── servers.d       # where nctl stores complete server cfgs
├── snippets.d      # nctl's minor cfg snippets
├── ssl             # ssl certs are kept here
└── nginx.conf      # the nginx cfg from above

10 directories, 249 files