aboutsummaryrefslogtreecommitdiffhomepage
path: root/org/meta_conf_make_meta.org
diff options
context:
space:
mode:
Diffstat (limited to 'org/meta_conf_make_meta.org')
-rw-r--r--org/meta_conf_make_meta.org173
1 files changed, 88 insertions, 85 deletions
diff --git a/org/meta_conf_make_meta.org b/org/meta_conf_make_meta.org
index 737b309..f91a615 100644
--- a/org/meta_conf_make_meta.org
+++ b/org/meta_conf_make_meta.org
@@ -42,56 +42,56 @@ NOTES on configuration hierarchy:
** table
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cfg ctfe | config local | cli | cli-run | composite | default | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| _cfg. | ["webserv"] | -- | opt_action. | _struct_composite.conf. | default | ✓ ✗ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| www_doc_root | ["data_root_path"] | output | output_dir_set | output_path | "/srv/www/spine" | ✓ |
-| | | | | | "/var/www" | |
-| | | | | | "/var/www/html" | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| www_http | ["http"] | www-http | webserver_http | w_srv_http | "http" or "https" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| www_host | ["domain"] | www-host | webserver_host_name | CHECK | "localhost" | ✓ |
-| | | | | | "sisudoc" | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| www_host_doc_root | [""] | www-host-doc-root | webserver_host_doc_root | w_srv_data_root_path | | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| www_url_doc_root? | | www-url-doc-root | | | "http://localhost" | |
-| CHECK | | | | | "https://sisudoc.org" | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_http | [""] | cgi-http | | | | ✗ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_host | [""] | cgi-host | | | | ✗ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_bin_root | ["cgi_bin_path"] | cgi-bin-root | cgi_bin_root | cgi_bin_root | "/var/www/cgi/cgi-bin" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_filename | ["cgi_search_script"] | cgi-sqlite-search-filename | cgi_sqlite_search_filename | w_srv_cgi_search_script | "spine_search" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_url_root | ["cgi_bin_url"] | cgi-url-root | cgi_url_root | | REMOVE UNUSED | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_url_action | ["cgi_action"] | cgi-url-action | cgi_url_action | w_srv_cgi_action | "http://localhost/cgi-bin/spine-search" | ✓ |
-| | | | | | "https://sisudoc.org/spine-search" | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| cgi_search_form_title | ["cgi_search_form_title"] | cgi-search-title | cgi_search_title | w_srv_cgi_search_form_title | "≅ SiSU Spine search" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| | | config | | | | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| default_language | [""] | lang | languages_set | | "all" or "en" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| default_papersize | [""] | set-papersize | latex_papersize | set_papersize | "a4"? | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| default_text_wrap | [""] | set-textwrap | text_wrap | set_text_wrap | 80 | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| default_hash_digest | [""] | set-digest | hash_digest_type | | sha258 | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| db_sqlite_path | [""] | sqlite-db-path | sqliteDB_path | w_srv_db_sqlite_path | "/var/www/sqlite" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| db_sqlite_filename | [""] | sqlite-db-filename | sqliteDB_filename | w_srv_db_sqlite_filename | "spine_search.db" | ✓ |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
-| | | | | | | |
-|-----------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cfg ctfe | config local | cli | cli-run | composite | default | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| _cfg. | ["webserv"] | -- | opt_action. | _struct_composite.conf. | default | ✓ ✗ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| processing_path_doc_root | ["data_root_path"] | output | output_dir_set | output_path | "/srv/www/spine" | ✓ |
+| | | | | | "/var/www" | |
+| | | | | | "/var/www/html" | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| http_request_type | ["http"] | www-http | webserver_http | w_srv_http | "http" or "https" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| www_host | ["domain"] | www-host | webserver_host_name | CHECK | "localhost" | ✓ |
+| | | | | | "sisudoc" | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| www_host_doc_root | [""] | www-host-doc-root | webserver_host_doc_root | w_srv_data_root_path | | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| www_url_doc_root? | | www-url-doc-root | | | "http://localhost" | |
+| CHECK | | | | | "https://sisudoc.org" | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_http | [""] | cgi-http | | | | ✗ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_host | [""] | cgi-host | | | | ✗ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_bin_root | ["cgi_bin_path"] | cgi-bin-root | cgi_bin_root | cgi_bin_root | "/var/www/cgi/cgi-bin" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_filename | ["cgi_search_script"] | cgi-sqlite-search-filename | cgi_sqlite_search_filename | w_srv_cgi_search_script | "spine_search" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_url_root | ["cgi_bin_url"] | cgi-url-root | cgi_url_root | | REMOVE UNUSED | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_url_action | ["cgi_action"] | cgi-url-action | cgi_url_action | w_srv_cgi_action | "http://localhost/cgi-bin/spine-search" | ✓ |
+| | | | | | "https://sisudoc.org/spine-search" | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| cgi_search_form_title | ["cgi_search_form_title"] | cgi-search-title | cgi_search_title | w_srv_cgi_search_form_title | "≅ SiSU Spine search" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| | | config | | | | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| default_language | [""] | lang | languages_set | | "all" or "en" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| default_papersize | [""] | set-papersize | latex_papersize | set_papersize | "a4"? | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| default_text_wrap | [""] | set-textwrap | text_wrap | set_text_wrap | 80 | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| default_hash_digest | [""] | set-digest | hash_digest_type | | sha258 | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| db_sqlite_path | [""] | sqlite-db-path | sqliteDB_path | w_srv_db_sqlite_path | "/var/www/sqlite" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| db_sqlite_filename | [""] | sqlite-db-filename | sqliteDB_filename | w_srv_db_sqlite_filename | "spine_search.db" | ✓ |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
+| | | | | | | |
+|--------------------------+---------------------------+----------------------------+----------------------------+-----------------------------+-----------------------------------------+-----|
** cli flag
@@ -124,27 +124,29 @@ string[string] settings = [
- see: config_d_cfte.org
for configuration_example.txt
+#+HEADER: :NO-tangle "../views/configuration.txt"
#+BEGIN_SRC d
+/+ obt - org-mode generated file +/
struct Cfg {
- string www_http = "http";
- string www_host = "localhost";
- string www_url_doc_root = "http://localhost";
- string www_doc_root = "/srv/www/spine";
- string www_host_doc_root = "localhost";
- string cgi_bin_root = "/var/www/cgi/cgi-bin";
- string cgi_bin_subpath = "";
- string cgi_filename = "spine_search";
- string cgi_url_root = "http://localhost/";
- string cgi_port = "";
- string cgi_user = "";
- string cgi_url_action = "http://localhost/spine_search";
- string cgi_search_form_title = "≅ SiSU Spine search";
- string db_sqlite_path = "/var/www/sqlite";
- string db_sqlite_filename = "spine.search.db";
- string default_language = "en";
- string default_papersize = "a4";
- string default_text_wrap = "80";
- string default_hash_digest = "sha256";
+ string http_request_type = "http";
+ string http_host = "localhost";
+ string www_url_doc_root = "http://localhost";
+ string www_url_doc_subroot = "/spine";
+ string processing_path_doc_root = "/srv/www/spine";
+ string cgi_bin_root = "/var/www/cgi/cgi-bin";
+ string cgi_bin_subpath = "/cgi-bin";
+ string cgi_filename = "spine_search";
+ string cgi_url_root = "http://localhost/cgi-bin";
+ string cgi_port = "";
+ string cgi_user = "";
+ string cgi_url_action = "http://localhost/cgi-bin/spine_search";
+ string cgi_search_form_title = "≅ SiSU Spine search";
+ string db_sqlite_path = "/var/www/sqlite";
+ string db_sqlite_filename = "spine.search.db";
+ string default_language = "en";
+ string default_papersize = "a4";
+ string default_text_wrap = "80";
+ string default_hash_digest = "sha256";
}
enum _cfg = Cfg();
#+END_SRC
@@ -166,25 +168,25 @@ default:
text_wrap: "80"
digest: "sha256"
webserv:
- http: "https" # "http"
- domain: "sisudoc" # "localhost"
+ http: "http" # "https"
+ domain: "localhost" # "mysite"
data_http: "https" # "http"
- data_domain: "sisudoc" # "localhost"
- data_root_url: "https://sisudoc.org" # "http://localhost"
+ data_domain: "localhost" # "mysite"
+ data_root_url: "http://localhost" # "https://mysite.org"
data_root_path: "/srv/www/spine" # "/var/www/html"
- data_root_part: ""
+ data_root_part: "" # "/spine"
images_root_part: "image"
cgi_search_form_title: "≅ SiSU Spine search"
- cgi_http: "https" # "http"
- cgi_domain: "sisudoc.org" # "localhost"
- cgi_bin_url: "http://sisudoc.org/cgi-bin" # "http://localhost/cgi-bin"
+ cgi_http: "http" # "https"
+ cgi_domain: "localhost" # "mysite.org"
+ cgi_bin_url: "http://localhost/cgi-bin" # "https://mysite.org/cgi-bin"
cgi_bin_part: "cgi-bin"
cgi_bin_path: "/var/www/cgi/cgi-bin" # "/usr/lib/cgi-bin"
cgi_search_script: "spine_search"
cgi_search_script_raw_fn_d: "spine_search.d"
cgi_port: ""
cgi_user: ""
- cgi_action: "https://sisudoc.org/spine_search" # "http://localhost/cgi-bin/spine-search"
+ cgi_action: "http://localhost/cgi-bin/spine-search" # "https://mysite.org/spine_search"
db_sqlite_filename: "spine.search.db"
db_sqlite_path: "/var/www/sqlite"
db_pg_table: ""
@@ -601,9 +603,9 @@ template contentYAMLtoSpineStruct() {
= _opt_action.webserver_http;
} else {
_struct_composite.conf.w_srv_http
- = (_cfg.www_http.empty)
+ = (_cfg.http_request_type.empty)
? "http"
- : _cfg.www_http;
+ : _cfg.http_request_type;
if (("webserv" in _yaml && _yaml["webserv"].type.sequence)
&& (_yaml["webserv"].type.mapping
&& _yaml["webserv"].tag.match(rgx.yaml_tag_is_map))
@@ -733,9 +735,9 @@ template contentYAMLtoSpineStruct() {
= (_opt_action.output_dir_set.asNormalizedPath).array;
} else {
_struct_composite.conf.output_path
- = (_cfg.www_doc_root.empty)
+ = (_cfg.processing_path_doc_root.empty)
? "/srv/www/spine"
- : _cfg.www_doc_root;
+ : _cfg.processing_path_doc_root;
if (("webserv" in _yaml && _yaml["webserv"].type.sequence)
&& (_yaml["webserv"].type.mapping
&& _yaml["webserv"].tag.match(rgx.yaml_tag_is_map))
@@ -761,9 +763,9 @@ template contentYAMLtoSpineStruct() {
= _opt_action.webserver_host_doc_root;
} else {
_struct_composite.conf.w_srv_data_root_path
- = (_cfg.www_doc_root.empty)
+ = (_cfg.processing_path_doc_root.empty)
? "/var/www/spine"
- : _cfg.www_doc_root;
+ : _cfg.processing_path_doc_root;
if (("webserv" in _yaml && _yaml["webserv"].type.sequence)
&& (_yaml["webserv"].type.mapping
&& _yaml["webserv"].tag.match(rgx.yaml_tag_is_map))
@@ -859,7 +861,8 @@ if (("webserv" in _yaml
) {
_struct_composite.conf.w_srv_data_root_url = _yaml["webserv"]["data_root_url"].get!string;
_struct_composite.conf.w_srv_data_root_url_html =
- _yaml["webserv"]["data_root_url"].get!string ~ "/"
+ _yaml["webserv"]["data_root_url"].get!string
+ ~ _struct_composite.conf.w_srv_data_root_part ~ "/"
~ _manifested.src.language ~ "/"
~ "html";
} else {