diff --git a/Makefile b/Makefile index 321efd8b..9956c4ab 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ PROJECT := ahriman -FILES := AUTHORS COPYING README.md docs package src setup.cfg setup.py +FILES := AUTHORS COPYING README.md docs package src setup.cfg setup.py web.png TARGET_FILES := $(addprefix $(PROJECT)/, $(FILES)) IGNORE_FILES := package/archlinux src/.mypy_cache diff --git a/README.md b/README.md index 2d293663..e14c76e3 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ For installation details please refer to the [documentation](docs/setup.md). For ```shell $ ahriman --help usage: ahriman [-h] [-a ARCHITECTURE] [-c CONFIGURATION] [--force] [-l LOCK] [--no-report] [-q] [--unsafe] [-v] - {aur-search,search,key-import,package-add,add,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} + {aur-search,search,key-import,package-add,add,package-update,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} ... ArcH Linux ReposItory MANager @@ -41,16 +41,17 @@ optional arguments: -l LOCK, --lock LOCK lock file (default: /tmp/ahriman.lock) --no-report force disable reporting to web service (default: False) -q, --quiet force disable any logging (default: False) - --unsafe allow to run ahriman as non-ahriman user (default: False) + --unsafe allow to run ahriman as non-ahriman user. Some actions might be unavailable (default: False) -v, --version show program's version number and exit command: - {aur-search,search,key-import,package-add,add,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} + {aur-search,search,key-import,package-add,add,package-update,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} command to run aur-search (search) search for package key-import import PGP key - package-add (add) add package + package-add (add, package-update) + add package package-remove (remove) remove package package-status (status) @@ -59,9 +60,9 @@ command: remove package status package-status-update (status-update) update package status - patch-add patches control - patch-list patches control - patch-remove patches control + patch-add add patch set + patch-list list patch sets + patch-remove remove patch set repo-check (check) check for updates repo-clean (clean) clean local caches repo-config (config) @@ -78,8 +79,8 @@ command: repo-sync (sync) sync repository repo-update (update) update packages - user-add create or update user for web services - user-remove remove user for web services + user-add create or update user + user-remove remove user web web server ``` @@ -88,3 +89,5 @@ Subcommands have own help message as well. ## Configuration Every available option is described in the [documentation](docs/configuration.md). + +## [FAQ](docs/faq.md) diff --git a/docs/ahriman-architecture.svg b/docs/ahriman-architecture.svg index f59faef2..deb0e624 100644 --- a/docs/ahriman-architecture.svg +++ b/docs/ahriman-architecture.svg @@ -4,3669 +4,3842 @@ - - + + G - + ahriman_application_ahriman - -ahriman. -application. -ahriman + +ahriman. +application. +ahriman ahriman_application_application - -ahriman. -application. -application + +ahriman. +application. +application ahriman_application_handlers_add - -ahriman. -application. -handlers. -add + +ahriman. +application. +handlers. +add ahriman_application_application->ahriman_application_handlers_add - - + ahriman_application_handlers_clean - -ahriman. -application. -handlers. -clean + +ahriman. +application. +handlers. +clean ahriman_application_application->ahriman_application_handlers_clean - - + ahriman_application_handlers_init - -ahriman. -application. -handlers. -init + +ahriman. +application. +handlers. +init ahriman_application_application->ahriman_application_handlers_init - - + ahriman_application_handlers_key_import - -ahriman. -application. -handlers. -key_import + +ahriman. +application. +handlers. +key_import ahriman_application_application->ahriman_application_handlers_key_import - - + + + + + +ahriman_application_handlers_patch + +ahriman. +application. +handlers. +patch + + + +ahriman_application_application->ahriman_application_handlers_patch + + - + ahriman_application_handlers_rebuild - -ahriman. -application. -handlers. -rebuild + +ahriman. +application. +handlers. +rebuild - + ahriman_application_application->ahriman_application_handlers_rebuild - - - + + + - + ahriman_application_handlers_remove - -ahriman. -application. -handlers. -remove + +ahriman. +application. +handlers. +remove - + ahriman_application_application->ahriman_application_handlers_remove - - + + - + ahriman_application_handlers_remove_unknown - -ahriman. -application. -handlers. -remove_unknown + +ahriman. +application. +handlers. +remove_unknown - + ahriman_application_application->ahriman_application_handlers_remove_unknown - - + + - + ahriman_application_handlers_report - -ahriman. -application. -handlers. -report + +ahriman. +application. +handlers. +report - + ahriman_application_application->ahriman_application_handlers_report - - + + - -ahriman_application_handlers_setup - -ahriman. -application. -handlers. -setup - - - -ahriman_application_application->ahriman_application_handlers_setup - - - - - -ahriman_application_handlers_sign - -ahriman. -application. -handlers. -sign - - - -ahriman_application_application->ahriman_application_handlers_sign - - - - - -ahriman_application_handlers_status - -ahriman. -application. -handlers. -status - - - -ahriman_application_application->ahriman_application_handlers_status - - - - - -ahriman_application_handlers_status_update - +ahriman_application_handlers_setup + ahriman. application. handlers. -status_update +setup + + + +ahriman_application_application->ahriman_application_handlers_setup + + + + + +ahriman_application_handlers_sign + +ahriman. +application. +handlers. +sign + + + +ahriman_application_application->ahriman_application_handlers_sign + + + + +ahriman_application_handlers_status + +ahriman. +application. +handlers. +status + + + +ahriman_application_application->ahriman_application_handlers_status + + + + + + +ahriman_application_handlers_status_update + +ahriman. +application. +handlers. +status_update - + ahriman_application_application->ahriman_application_handlers_status_update - - + + - + ahriman_application_handlers_sync - -ahriman. -application. -handlers. -sync + +ahriman. +application. +handlers. +sync - + ahriman_application_application->ahriman_application_handlers_sync - - + + - + ahriman_application_handlers_update - -ahriman. -application. -handlers. -update + +ahriman. +application. +handlers. +update - + ahriman_application_application->ahriman_application_handlers_update - - - + + - + ahriman_application_handlers_user - -ahriman. -application. -handlers. -user + +ahriman. +application. +handlers. +user - + ahriman_application_application->ahriman_application_handlers_user - - + + ahriman_application_handlers - -ahriman. -application. -handlers + +ahriman. +application. +handlers - + ahriman_application_handlers->ahriman_application_ahriman - - + + - + ahriman_application_handlers_add->ahriman_application_handlers - + - + ahriman_application_handlers_clean->ahriman_application_handlers - + ahriman_application_handlers_dump - -ahriman. -application. -handlers. -dump + +ahriman. +application. +handlers. +dump - + ahriman_application_handlers_dump->ahriman_application_handlers - + + + ahriman_application_handlers_handler - -ahriman. -application. -handlers. -handler + +ahriman. +application. +handlers. +handler - + ahriman_application_handlers_handler->ahriman_application_handlers - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_add - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_clean - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_dump - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_init - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_key_import - - + + + + + +ahriman_application_handlers_handler->ahriman_application_handlers_patch + + - + ahriman_application_handlers_handler->ahriman_application_handlers_rebuild - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_remove - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_remove_unknown - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_report - - + + - + ahriman_application_handlers_search - -ahriman. -application. -handlers. -search + +ahriman. +application. +handlers. +search - + ahriman_application_handlers_handler->ahriman_application_handlers_search - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_setup - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_sign - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_status - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_status_update - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_sync - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_update - - + + - + ahriman_application_handlers_handler->ahriman_application_handlers_user - - + + - + ahriman_application_handlers_web - -ahriman. -application. -handlers. -web + +ahriman. +application. +handlers. +web - + ahriman_application_handlers_handler->ahriman_application_handlers_web - - + + + + - + ahriman_application_handlers_init->ahriman_application_handlers - + - + ahriman_application_handlers_key_import->ahriman_application_handlers - + + + + +ahriman_application_handlers_patch->ahriman_application_handlers + - + ahriman_application_handlers_rebuild->ahriman_application_handlers - + - + ahriman_application_handlers_remove->ahriman_application_handlers - + - + ahriman_application_handlers_remove_unknown->ahriman_application_handlers - + + - + ahriman_application_handlers_report->ahriman_application_handlers - + - + ahriman_application_handlers_search->ahriman_application_handlers - + - + ahriman_application_handlers_setup->ahriman_application_handlers - - + - + ahriman_application_handlers_sign->ahriman_application_handlers - + - + ahriman_application_handlers_status->ahriman_application_handlers - + - + ahriman_application_handlers_status_update->ahriman_application_handlers - - - + - + ahriman_application_handlers_sync->ahriman_application_handlers - + - + ahriman_application_handlers_update->ahriman_application_handlers - - - - - - + + + + - + ahriman_application_handlers_user->ahriman_application_handlers - + - + ahriman_application_handlers_web->ahriman_application_handlers - - + + - + ahriman_application_lock - -ahriman. -application. -lock + +ahriman. +application. +lock - + ahriman_application_lock->ahriman_application_handlers_handler - - + - + ahriman_core - -ahriman.core + +ahriman.core - + ahriman_core->ahriman_application_application - - - - - + - + ahriman_core->ahriman_application_handlers_add - - - - + - + ahriman_core->ahriman_application_handlers_clean - - - + + - + ahriman_core->ahriman_application_handlers_dump - - - + + + + - + ahriman_core->ahriman_application_handlers_handler - - - - + + + + + - + ahriman_core->ahriman_application_handlers_init - - + - + ahriman_core->ahriman_application_handlers_key_import - + + + + + +ahriman_core->ahriman_application_handlers_patch + + - + ahriman_core->ahriman_application_handlers_rebuild - - + + - + ahriman_core->ahriman_application_handlers_remove - - + - + ahriman_core->ahriman_application_handlers_remove_unknown - - - + + + - + ahriman_core->ahriman_application_handlers_report - - - + + + - + ahriman_core->ahriman_application_handlers_search - - + + + - + ahriman_core->ahriman_application_handlers_setup - - + + + - + ahriman_core->ahriman_application_handlers_sign - - - + + + - + ahriman_core->ahriman_application_handlers_status - - + + + - + ahriman_core->ahriman_application_handlers_status_update - - + + - + ahriman_core->ahriman_application_handlers_sync - + + + + + - + ahriman_core->ahriman_application_handlers_update - + + - + ahriman_core->ahriman_application_handlers_user - - - - + + - + ahriman_core->ahriman_application_handlers_web - - - - + - + ahriman_core->ahriman_application_lock - - + + - + ahriman_models_auth_settings - -ahriman. -models. -auth_settings + +ahriman. +models. +auth_settings - + ahriman_core->ahriman_models_auth_settings - - + + - + ahriman_models_build_status - -ahriman. -models. -build_status + +ahriman. +models. +build_status - + ahriman_core->ahriman_models_build_status - - + + + - + ahriman_models_package - -ahriman. -models. -package + +ahriman. +models. +package - + ahriman_core->ahriman_models_package - + - + ahriman_models_package_source - -ahriman. -models. -package_source + +ahriman. +models. +package_source - + ahriman_core->ahriman_models_package_source - - + + - + ahriman_models_report_settings - -ahriman. -models. -report_settings + +ahriman. +models. +report_settings - + ahriman_core->ahriman_models_report_settings - - + + - + ahriman_models_sign_settings - -ahriman. -models. -sign_settings + +ahriman. +models. +sign_settings - + ahriman_core->ahriman_models_sign_settings - - + + - + ahriman_models_upload_settings - -ahriman. -models. -upload_settings + +ahriman. +models. +upload_settings - + ahriman_core->ahriman_models_upload_settings - - + + - + ahriman_web_middlewares_auth_handler - -ahriman. -web. -middlewares. -auth_handler + +ahriman. +web. +middlewares. +auth_handler - + ahriman_core->ahriman_web_middlewares_auth_handler - - - + - + ahriman_web_views_base - -ahriman. -web. -views. -base + +ahriman. +web. +views. +base - + ahriman_core->ahriman_web_views_base - - - + + - + ahriman_web_views_index - -ahriman. -web. -views. -index + +ahriman. +web. +views. +index - + ahriman_core->ahriman_web_views_index - - - - + - + ahriman_web_views_service_reload_auth - -ahriman. -web. -views. -service. -reload_auth + +ahriman. +web. +views. +service. +reload_auth - + ahriman_core->ahriman_web_views_service_reload_auth - - - - + - + ahriman_web_views_status_package - -ahriman. -web. -views. -status. -package + +ahriman. +web. +views. +status. +package - + ahriman_core->ahriman_web_views_status_package - - + + - + ahriman_web_views_user_login - -ahriman. -web. -views. -user. -login + +ahriman. +web. +views. +user. +login - + ahriman_core->ahriman_web_views_user_login - - + - + ahriman_web_views_user_logout - -ahriman. -web. -views. -user. -logout + +ahriman. +web. +views. +user. +logout - + ahriman_core->ahriman_web_views_user_logout - - + + + - + ahriman_web_web - -ahriman. -web. -web + +ahriman. +web. +web - + ahriman_core->ahriman_web_web - - + + + + + - + ahriman_core_alpm - -ahriman. -core. -alpm + +ahriman. +core. +alpm - + ahriman_core_repository_properties - -ahriman. -core. -repository. -properties + +ahriman. +core. +repository. +properties - + ahriman_core_alpm->ahriman_core_repository_properties - - + - + ahriman_core_alpm->ahriman_models_package - + + + - + ahriman_core_alpm_pacman - -ahriman. -core. -alpm. -pacman + +ahriman. +core. +alpm. +pacman - + ahriman_core_alpm_pacman->ahriman_core_repository_properties - - + + - + ahriman_core_alpm_pacman->ahriman_models_package - + + - + ahriman_core_alpm_repo - -ahriman. -core. -alpm. -repo + +ahriman. +core. +alpm. +repo - + ahriman_core_alpm_repo->ahriman_core_repository_properties - + - + ahriman_core_auth - -ahriman. -core. -auth + +ahriman. +core. +auth - + ahriman_core_auth->ahriman_web_middlewares_auth_handler - - + + - + ahriman_core_auth->ahriman_web_views_base - - + + - + ahriman_core_auth->ahriman_web_views_index - + + - + ahriman_core_auth->ahriman_web_views_service_reload_auth - - + + - + ahriman_core_auth->ahriman_web_views_user_login - - + + + - + ahriman_core_auth->ahriman_web_views_user_logout - - + - + ahriman_core_auth->ahriman_web_web - + + - + ahriman_core_auth_auth - -ahriman. -core. -auth. -auth + +ahriman. +core. +auth. +auth - + ahriman_core_auth_mapping - -ahriman. -core. -auth. -mapping + +ahriman. +core. +auth. +mapping - + ahriman_core_auth_auth->ahriman_core_auth_mapping - - - + + + - + ahriman_core_auth_auth->ahriman_web_middlewares_auth_handler - + + + - + ahriman_core_auth_auth->ahriman_web_views_base - - + - + ahriman_core_auth_auth->ahriman_web_views_service_reload_auth - - + + - + ahriman_core_auth_auth->ahriman_web_web - + + - + ahriman_core_auth_helpers - -ahriman. -core. -auth. -helpers + +ahriman. +core. +auth. +helpers - + ahriman_core_auth_helpers->ahriman_web_views_index - - + + + - + ahriman_core_auth_helpers->ahriman_web_views_user_login - - + + - + ahriman_core_auth_helpers->ahriman_web_views_user_logout - - + + + - + ahriman_core_auth_oauth - -ahriman. -core. -auth. -oauth + +ahriman. +core. +auth. +oauth - + ahriman_core_auth_mapping->ahriman_core_auth_oauth - - + + - + ahriman_core_auth_oauth->ahriman_core_auth_auth - - + + - + ahriman_core_auth_oauth->ahriman_web_views_user_login - - + - + ahriman_core_build_tools - -ahriman. -core. -build_tools + +ahriman. +core. +build_tools - + ahriman_core_build_tools->ahriman_application_application - + + + + + + + +ahriman_core_build_tools->ahriman_application_handlers_patch + + - + ahriman_core_repository_executor - -ahriman. -core. -repository. -executor + +ahriman. +core. +repository. +executor - + ahriman_core_build_tools->ahriman_core_repository_executor - - + + - + ahriman_core_tree - -ahriman. -core. -tree + +ahriman. +core. +tree - + ahriman_core_build_tools->ahriman_core_tree - - + + - + ahriman_core_build_tools->ahriman_models_package - - - + + + + + + +ahriman_core_build_tools_sources + +ahriman. +core. +build_tools. +sources + + + +ahriman_core_build_tools_sources->ahriman_application_application + + + + + +ahriman_core_build_tools_sources->ahriman_application_handlers_patch + + - + ahriman_core_build_tools_task - -ahriman. -core. -build_tools. -task + +ahriman. +core. +build_tools. +task - - -ahriman_core_build_tools_task->ahriman_application_application - - - - + + +ahriman_core_build_tools_sources->ahriman_core_build_tools_task + + + + + + +ahriman_core_build_tools_sources->ahriman_core_tree + + + + + + +ahriman_core_build_tools_sources->ahriman_models_package + - + ahriman_core_build_tools_task->ahriman_core_repository_executor - - - - - -ahriman_core_build_tools_task->ahriman_core_tree - - + + - + ahriman_core_configuration - -ahriman. -core. -configuration + +ahriman. +core. +configuration - + ahriman_core_configuration->ahriman_application_application - - - + + - + ahriman_core_configuration->ahriman_application_handlers_add - - + + + - + ahriman_core_configuration->ahriman_application_handlers_clean - - - - + + + + + - + ahriman_core_configuration->ahriman_application_handlers_dump - - + - + ahriman_core_configuration->ahriman_application_handlers_handler - - - + - + ahriman_core_configuration->ahriman_application_handlers_init - - - - + + + - + ahriman_core_configuration->ahriman_application_handlers_key_import - - - - + + + + + + + + +ahriman_core_configuration->ahriman_application_handlers_patch + + - + ahriman_core_configuration->ahriman_application_handlers_rebuild - - + + - + ahriman_core_configuration->ahriman_application_handlers_remove - - + + + + + - + ahriman_core_configuration->ahriman_application_handlers_remove_unknown - + + + - + ahriman_core_configuration->ahriman_application_handlers_report - - - + + - + ahriman_core_configuration->ahriman_application_handlers_search - - - + + - + ahriman_core_configuration->ahriman_application_handlers_setup - - + + + - + ahriman_core_configuration->ahriman_application_handlers_sign - - + + + - + ahriman_core_configuration->ahriman_application_handlers_status - - - + - + ahriman_core_configuration->ahriman_application_handlers_status_update - - + + - + ahriman_core_configuration->ahriman_application_handlers_sync - - - - + + - + ahriman_core_configuration->ahriman_application_handlers_update - - - + + - + ahriman_core_configuration->ahriman_application_handlers_user - - - + - + ahriman_core_configuration->ahriman_application_handlers_web - + + - + ahriman_core_configuration->ahriman_application_lock - - + + + + - + ahriman_core_configuration->ahriman_core_alpm_pacman - - + + - + ahriman_core_configuration->ahriman_core_auth_auth - - + + - + ahriman_core_configuration->ahriman_core_auth_mapping - + + - + ahriman_core_configuration->ahriman_core_auth_oauth - - + + - + ahriman_core_configuration->ahriman_core_build_tools_task - - - - + + - + ahriman_core_report_email - -ahriman. -core. -report. -email + +ahriman. +core. +report. +email - + ahriman_core_configuration->ahriman_core_report_email - - - - - + + - + ahriman_core_report_html - -ahriman. -core. -report. -html + +ahriman. +core. +report. +html - + ahriman_core_configuration->ahriman_core_report_html - - + + - + ahriman_core_report_jinja_template - -ahriman. -core. -report. -jinja_template + +ahriman. +core. +report. +jinja_template - + ahriman_core_configuration->ahriman_core_report_jinja_template - - + - + ahriman_core_report_report - -ahriman. -core. -report. -report + +ahriman. +core. +report. +report - + ahriman_core_configuration->ahriman_core_report_report - - - - + + - + ahriman_core_configuration->ahriman_core_repository_properties - - + + + - + ahriman_core_sign_gpg - -ahriman. -core. -sign. -gpg + +ahriman. +core. +sign. +gpg - + ahriman_core_configuration->ahriman_core_sign_gpg - - - + + + - + ahriman_core_spawn - -ahriman. -core. -spawn + +ahriman. +core. +spawn - + ahriman_core_configuration->ahriman_core_spawn - - + + + - + ahriman_core_status_client - -ahriman. -core. -status. -client + +ahriman. +core. +status. +client - + ahriman_core_configuration->ahriman_core_status_client - + + - + ahriman_core_status_watcher - -ahriman. -core. -status. -watcher + +ahriman. +core. +status. +watcher - + ahriman_core_configuration->ahriman_core_status_watcher - - + + - + ahriman_core_status_web_client - -ahriman. -core. -status. -web_client + +ahriman. +core. +status. +web_client - + ahriman_core_configuration->ahriman_core_status_web_client - - + + + + +ahriman_core_upload_github + +ahriman. +core. +upload. +github + + + +ahriman_core_configuration->ahriman_core_upload_github + + + + - + ahriman_core_upload_rsync - -ahriman. -core. -upload. -rsync + +ahriman. +core. +upload. +rsync - + ahriman_core_configuration->ahriman_core_upload_rsync - - - + + + + - + ahriman_core_upload_s3 - -ahriman. -core. -upload. -s3 + +ahriman. +core. +upload. +s3 - + ahriman_core_configuration->ahriman_core_upload_s3 - + - + ahriman_core_upload_upload - -ahriman. -core. -upload. -upload + +ahriman. +core. +upload. +upload - + ahriman_core_configuration->ahriman_core_upload_upload - + - + ahriman_core_configuration->ahriman_web_views_base - - - - - + + + - + ahriman_core_configuration->ahriman_web_web - - - - + - + ahriman_core_exceptions - -ahriman. -core. -exceptions + +ahriman. +core. +exceptions - + ahriman_core_exceptions->ahriman_application_handlers_handler - - - - - - - -ahriman_core_exceptions->ahriman_application_handlers_status_update - - + + + + + - + ahriman_core_exceptions->ahriman_application_lock - - - + + - + ahriman_core_exceptions->ahriman_core_alpm_repo - + + - + ahriman_core_exceptions->ahriman_core_auth_auth - - - - + + - + ahriman_core_exceptions->ahriman_core_auth_oauth - - - + + - + ahriman_core_exceptions->ahriman_core_build_tools_task - - + + + - + ahriman_core_exceptions->ahriman_core_configuration - - + + - + ahriman_core_exceptions->ahriman_core_report_report - + + + + + + +ahriman_core_exceptions->ahriman_core_repository_properties + - + ahriman_core_exceptions->ahriman_core_sign_gpg - - + + - + ahriman_core_exceptions->ahriman_core_status_watcher - - - - + - + ahriman_core_exceptions->ahriman_core_upload_upload - - - + - + ahriman_core_util - -ahriman. -core. -util + +ahriman. +core. +util - + ahriman_core_exceptions->ahriman_core_util - - + + - + ahriman_core_exceptions->ahriman_models_auth_settings - - - + + + - + ahriman_core_exceptions->ahriman_models_package - - - + + - + ahriman_core_exceptions->ahriman_models_report_settings - - + + - + ahriman_core_exceptions->ahriman_models_sign_settings - - + + - + ahriman_core_exceptions->ahriman_models_upload_settings - - - + + - + ahriman_core_exceptions->ahriman_web_views_status_package - - + + + - + ahriman_core_exceptions->ahriman_web_web - - + + - + ahriman_core_report - -ahriman. -core. -report + +ahriman. +core. +report - + ahriman_core_report->ahriman_core_repository_executor - + + - + ahriman_core_report_email->ahriman_core_report_report - - - + + + - + ahriman_core_report_jinja_template->ahriman_core_report_email - - + + - + ahriman_core_report_jinja_template->ahriman_core_report_html - - + + - + ahriman_core_report_report->ahriman_core_report_html - - - + + + - + ahriman_core_report_report->ahriman_core_repository_executor - - - + + - + ahriman_core_repository - -ahriman. -core. -repository + +ahriman. +core. +repository - + ahriman_core_repository->ahriman_application_application - - + + - + ahriman_core_repository->ahriman_core_status_watcher - - + + - + ahriman_core_repository_cleaner - -ahriman. -core. -repository. -cleaner + +ahriman. +core. +repository. +cleaner - + ahriman_core_repository_cleaner->ahriman_core_repository_executor - - + + - + ahriman_core_repository_update_handler - -ahriman. -core. -repository. -update_handler + +ahriman. +core. +repository. +update_handler - + ahriman_core_repository_cleaner->ahriman_core_repository_update_handler - - + + - + ahriman_core_repository_repository - -ahriman. -core. -repository. -repository + +ahriman. +core. +repository. +repository - + ahriman_core_repository_executor->ahriman_core_repository_repository - - + + - + ahriman_core_repository_properties->ahriman_core_repository_cleaner - - + + - + ahriman_core_repository_repository->ahriman_application_application - - + + - + ahriman_core_repository_repository->ahriman_core_status_watcher - + + - + ahriman_core_repository_update_handler->ahriman_core_repository_repository - - + + - + ahriman_core_sign - -ahriman. -core. -sign + +ahriman. +core. +sign - + ahriman_core_sign->ahriman_core_report_jinja_template - - - + + - + ahriman_core_sign->ahriman_core_repository_properties - - + + + - + ahriman_core_sign_gpg->ahriman_core_report_jinja_template - - + + - + ahriman_core_sign_gpg->ahriman_core_repository_properties - - - + + - + ahriman_core_spawn->ahriman_application_handlers_web - - + + - + ahriman_core_spawn->ahriman_web_views_base - + + - + ahriman_core_spawn->ahriman_web_web - - + - + ahriman_core_status - -ahriman. -core. -status + +ahriman. +core. +status - + ahriman_core_status->ahriman_application_lock - - + + + - + ahriman_core_status->ahriman_core_repository_properties - - - + + - + ahriman_core_status->ahriman_web_views_base - - - - - - + + - + ahriman_core_status->ahriman_web_web - + + - + ahriman_core_status_client->ahriman_application_lock - - - + + - + ahriman_core_status_client->ahriman_core_repository_properties - - + + - + ahriman_core_status_client->ahriman_core_status_web_client - - - + + + - + ahriman_core_status_watcher->ahriman_web_views_base - + + - + ahriman_core_status_watcher->ahriman_web_web - - - + + - + ahriman_core_tree->ahriman_application_application - + - + ahriman_core_upload - -ahriman. -core. -upload + +ahriman. +core. +upload - + ahriman_core_upload->ahriman_core_repository_executor - + + + - - -ahriman_core_upload_rsync->ahriman_core_upload_upload - - - + + +ahriman_core_upload_github->ahriman_core_upload_upload + + + - + ahriman_core_upload_upload->ahriman_core_repository_executor - + + + + + +ahriman_core_upload_upload->ahriman_core_upload_rsync + + + - + ahriman_core_upload_upload->ahriman_core_upload_s3 - - - + + + - + ahriman_core_util->ahriman_application_application - + + + + + + + +ahriman_core_util->ahriman_application_lock + + + - + ahriman_core_util->ahriman_core_alpm_repo - - - - + + + + + + +ahriman_core_util->ahriman_core_build_tools_sources + + - + ahriman_core_util->ahriman_core_build_tools_task - - + + - + ahriman_core_util->ahriman_core_report_email - - + + + - + ahriman_core_util->ahriman_core_report_jinja_template - - - + + + + +ahriman_core_util->ahriman_core_repository_properties + + + - + ahriman_core_util->ahriman_core_repository_repository - - - + + - + ahriman_core_util->ahriman_core_sign_gpg - + + - + ahriman_core_util->ahriman_core_status_web_client - - + + + + +ahriman_core_util->ahriman_core_upload_github + - + ahriman_core_util->ahriman_core_upload_rsync - - - + + + + + +ahriman_core_util->ahriman_core_upload_s3 + + - + ahriman_core_util->ahriman_models_build_status - - + + - + ahriman_core_util->ahriman_models_package - - - + + + + - + ahriman_core_util->ahriman_models_package_source - - + + - + ahriman_core_util->ahriman_web_views_index - - + + + + - + ahriman_models - -ahriman.models + +ahriman.models - + ahriman_models->ahriman_application_ahriman - - + + - + ahriman_models->ahriman_application_application - - - - - - + + - + ahriman_models->ahriman_application_handlers_handler - - + + + + +ahriman_models->ahriman_application_handlers_patch + - + ahriman_models->ahriman_application_handlers_remove_unknown - - - + + - + ahriman_models->ahriman_application_handlers_setup - - - + - + ahriman_models->ahriman_application_handlers_status - - + + + + + + +ahriman_models->ahriman_application_handlers_status_update + + + + - + ahriman_models->ahriman_application_handlers_user - - + + + - + ahriman_models->ahriman_application_lock - - + - + ahriman_models->ahriman_core_alpm_repo - + - + ahriman_models->ahriman_core_auth_auth - + + - + ahriman_models->ahriman_core_auth_mapping - - + - + ahriman_models->ahriman_core_auth_oauth - - - + + + - + ahriman_models->ahriman_core_build_tools_task - - + + - + ahriman_models->ahriman_core_report_email - - - - + + - + ahriman_models->ahriman_core_report_html - - + + + + + - + ahriman_models->ahriman_core_report_jinja_template - + - + ahriman_models->ahriman_core_report_report - - + + - + ahriman_models->ahriman_core_repository_executor - - - - + - + ahriman_models->ahriman_core_repository_properties - - + + + - + ahriman_models->ahriman_core_repository_repository - - + + + - + ahriman_models->ahriman_core_repository_update_handler - - + - + ahriman_models->ahriman_core_sign_gpg - - + + - + ahriman_models->ahriman_core_spawn - - + + - + ahriman_models->ahriman_core_status_client - - + + + - + ahriman_models->ahriman_core_status_watcher - + + - + ahriman_models->ahriman_core_status_web_client - - - + - + ahriman_models->ahriman_core_tree - - + + + + + + +ahriman_models->ahriman_core_upload_github + + + - + ahriman_models->ahriman_core_upload_rsync - - + + + + - + ahriman_models->ahriman_core_upload_s3 - - - + - + ahriman_models->ahriman_core_upload_upload - - + + - + ahriman_models->ahriman_web_middlewares_auth_handler - + - + ahriman_models->ahriman_web_views_base - + + + - + ahriman_models->ahriman_web_views_index - - + + - + ahriman_web_views_service_add - -ahriman. -web. -views. -service. -add + +ahriman. +web. +views. +service. +add - + ahriman_models->ahriman_web_views_service_add - - - - + + - + ahriman_models->ahriman_web_views_service_reload_auth - - - - - - - + - + ahriman_web_views_service_remove - -ahriman. -web. -views. -service. -remove + +ahriman. +web. +views. +service. +remove - + ahriman_models->ahriman_web_views_service_remove - - + + + - + ahriman_web_views_service_request - -ahriman. -web. -views. -service. -request + +ahriman. +web. +views. +service. +request - + ahriman_models->ahriman_web_views_service_request - - + + + + - + ahriman_web_views_service_search - -ahriman. -web. -views. -service. -search + +ahriman. +web. +views. +service. +search - + ahriman_models->ahriman_web_views_service_search - - + + + + + + - + ahriman_web_views_status_ahriman - -ahriman. -web. -views. -status. -ahriman + +ahriman. +web. +views. +status. +ahriman - + ahriman_models->ahriman_web_views_status_ahriman - - + - + ahriman_models->ahriman_web_views_status_package - - - + + - + ahriman_web_views_status_packages - -ahriman. -web. -views. -status. -packages + +ahriman. +web. +views. +status. +packages - + ahriman_models->ahriman_web_views_status_packages - - + + + - + ahriman_web_views_status_status - -ahriman. -web. -views. -status. -status + +ahriman. +web. +views. +status. +status - + ahriman_models->ahriman_web_views_status_status - - + + - + ahriman_models->ahriman_web_views_user_login - - - - + + - + ahriman_models->ahriman_web_views_user_logout - - + + + + + +ahriman_models_action + +ahriman. +models. +action + + + +ahriman_models_action->ahriman_application_ahriman + + + + + + +ahriman_models_action->ahriman_application_handlers_patch + + + + + +ahriman_models_action->ahriman_application_handlers_status_update + + + + + +ahriman_models_action->ahriman_application_handlers_user + + + + - + ahriman_models_auth_settings->ahriman_core_auth_auth - - + + + - + ahriman_models_auth_settings->ahriman_core_auth_mapping - - + + - + ahriman_models_auth_settings->ahriman_core_auth_oauth - - + - + ahriman_models_build_status->ahriman_application_ahriman - - + - + ahriman_models_build_status->ahriman_application_handlers_status - - + - + ahriman_models_build_status->ahriman_application_lock - + + - + ahriman_models_build_status->ahriman_core_status_client - - + + - + ahriman_models_build_status->ahriman_core_status_watcher - - - + - + ahriman_models_build_status->ahriman_core_status_web_client - - - - + + - + ahriman_models_counters - -ahriman. -models. -counters + +ahriman. +models. +counters - + ahriman_models_build_status->ahriman_models_counters - - + + - + ahriman_models_build_status->ahriman_web_views_status_ahriman - - + + + - + ahriman_models_build_status->ahriman_web_views_status_package - - + + + - + ahriman_models_internal_status - -ahriman. -models. -internal_status + +ahriman. +models. +internal_status - + ahriman_models_counters->ahriman_models_internal_status - - + + - + ahriman_models_counters->ahriman_web_views_status_status - - + - + ahriman_models_internal_status->ahriman_core_status_client - - + + - + ahriman_models_internal_status->ahriman_core_status_web_client - - - + + + + - + ahriman_models_internal_status->ahriman_web_views_status_status - - - + + + + - + ahriman_models_package->ahriman_application_application - + + + + + +ahriman_models_package->ahriman_application_handlers_patch + + + + + - + ahriman_models_package->ahriman_application_handlers_remove_unknown - - + + - + ahriman_models_package->ahriman_application_handlers_status - - - - + + + + - + ahriman_models_package->ahriman_core_build_tools_task - - - + + - + ahriman_models_package->ahriman_core_report_email - - + + - + ahriman_models_package->ahriman_core_report_html - - + + + + - + ahriman_models_package->ahriman_core_report_jinja_template - - - + - + ahriman_models_package->ahriman_core_report_report - - - + + - + ahriman_models_package->ahriman_core_repository_executor - - + - + ahriman_models_package->ahriman_core_repository_repository - - + + + - + ahriman_models_package->ahriman_core_repository_update_handler - - - - + + + - + ahriman_models_package->ahriman_core_status_client - - - - + + - + ahriman_models_package->ahriman_core_status_watcher - - + + + + + - + ahriman_models_package->ahriman_core_status_web_client - - + - + ahriman_models_package->ahriman_core_tree - - - - + + + + + +ahriman_models_package->ahriman_core_upload_github + + - + ahriman_models_package->ahriman_core_upload_rsync - - + + - + ahriman_models_package->ahriman_core_upload_s3 - - - + + + - + ahriman_models_package->ahriman_core_upload_upload - - - + + - + ahriman_models_package->ahriman_models_counters - - + + - + ahriman_models_package->ahriman_web_views_status_package - - + - + ahriman_models_package_description - -ahriman. -models. -package_description + +ahriman. +models. +package_description - + ahriman_models_package_description->ahriman_models_package - - + + - + ahriman_models_package_source->ahriman_application_ahriman - - - - + + + - + ahriman_models_package_source->ahriman_application_application - - - + - + ahriman_models_package_source->ahriman_core_spawn - - + + + - + ahriman_models_report_settings->ahriman_core_report_report - + + - + ahriman_models_repository_paths - -ahriman. -models. -repository_paths + +ahriman. +models. +repository_paths - + ahriman_models_repository_paths->ahriman_application_handlers_handler - + + + - + ahriman_models_repository_paths->ahriman_application_handlers_setup - - - + + - + ahriman_models_repository_paths->ahriman_core_alpm_repo - - - + + - + ahriman_models_repository_paths->ahriman_core_build_tools_task - + - + ahriman_models_repository_paths->ahriman_core_repository_properties - - + + + + + + +ahriman_models_repository_paths->ahriman_core_tree + + - + ahriman_models_repository_paths->ahriman_models_package - - + + - + ahriman_models_sign_settings->ahriman_application_ahriman - + - + ahriman_models_sign_settings->ahriman_core_report_jinja_template - + + + + - + ahriman_models_sign_settings->ahriman_core_sign_gpg - - + - + ahriman_models_smtp_ssl_settings - -ahriman. -models. -smtp_ssl_settings + +ahriman. +models. +smtp_ssl_settings - + ahriman_models_smtp_ssl_settings->ahriman_core_report_email - + + - + ahriman_models_upload_settings->ahriman_core_upload_upload - - - + + + - + ahriman_models_user - -ahriman. -models. -user + +ahriman. +models. +user - + ahriman_models_user->ahriman_application_handlers_user - - - + + - + ahriman_models_user->ahriman_core_auth_auth - - + + - + ahriman_models_user->ahriman_core_auth_mapping - - + + + + + - + ahriman_models_user->ahriman_core_status_web_client - + + - + ahriman_models_user_access - -ahriman. -models. -user_access + +ahriman. +models. +user_access - + ahriman_models_user_access->ahriman_application_ahriman - - + - + ahriman_models_user_access->ahriman_application_handlers_user - - - + - + ahriman_models_user_access->ahriman_core_auth_auth - - - - + + + - + ahriman_models_user_access->ahriman_core_auth_mapping - - - + + - + ahriman_models_user_access->ahriman_models_user - - + + - + ahriman_models_user_access->ahriman_web_middlewares_auth_handler - - + - + ahriman_models_user_access->ahriman_web_views_base - + - + ahriman_models_user_access->ahriman_web_views_index - + + - + ahriman_models_user_access->ahriman_web_views_service_add - - + + + + - + ahriman_models_user_access->ahriman_web_views_service_reload_auth - - + + - + ahriman_models_user_access->ahriman_web_views_service_remove - - - - + + - + ahriman_models_user_access->ahriman_web_views_service_request - - - - - + + + - + ahriman_models_user_access->ahriman_web_views_service_search - - + + - + ahriman_models_user_access->ahriman_web_views_status_ahriman - - + + - + ahriman_models_user_access->ahriman_web_views_status_package - - - + + + - + ahriman_models_user_access->ahriman_web_views_status_packages - - - - + + - + ahriman_models_user_access->ahriman_web_views_status_status - - - + + - + ahriman_models_user_access->ahriman_web_views_user_login - - + + + - + ahriman_models_user_access->ahriman_web_views_user_logout - - - + + + - + ahriman_models_user_identity - -ahriman. -models. -user_identity + +ahriman. +models. +user_identity - + ahriman_models_user_identity->ahriman_web_middlewares_auth_handler - - + + - + ahriman_models_user_identity->ahriman_web_views_user_login - + + - + ahriman_version - -ahriman. -version + +ahriman. +version - + ahriman_version->ahriman_application_ahriman - - - + + - + ahriman_version->ahriman_application_lock - - + + - + ahriman_version->ahriman_web_views_index - - - + - + ahriman_version->ahriman_web_views_status_status - - - + + + - + ahriman_web - -ahriman.web + +ahriman.web - + ahriman_web->ahriman_application_handlers_web - + - + ahriman_web_middlewares - -ahriman. -web. -middlewares + +ahriman. +web. +middlewares - + ahriman_web_middlewares->ahriman_web_web - - + + - + ahriman_web_middlewares_auth_handler->ahriman_web_web - + + + - + ahriman_web_middlewares_exception_handler - -ahriman. -web. -middlewares. -exception_handler + +ahriman. +web. +middlewares. +exception_handler - + ahriman_web_middlewares_exception_handler->ahriman_web_web - + + - + ahriman_web_routes - -ahriman. -web. -routes + +ahriman. +web. +routes - + ahriman_web_routes->ahriman_web_web - - + + - + ahriman_web_views - -ahriman. -web. -views + +ahriman. +web. +views - + ahriman_web_views->ahriman_web_routes - - + + - + ahriman_web_views_base->ahriman_web_views_index - - + + - + ahriman_web_views_base->ahriman_web_views_service_add - - + + - + ahriman_web_views_base->ahriman_web_views_service_reload_auth - - + + - + ahriman_web_views_base->ahriman_web_views_service_remove - - + + - + ahriman_web_views_base->ahriman_web_views_service_request - - + + - + ahriman_web_views_base->ahriman_web_views_service_search - - + + - + ahriman_web_views_base->ahriman_web_views_status_ahriman - - + + - + ahriman_web_views_base->ahriman_web_views_status_package - - + + - + ahriman_web_views_base->ahriman_web_views_status_packages - - + + - + ahriman_web_views_base->ahriman_web_views_status_status - - + + - + ahriman_web_views_base->ahriman_web_views_user_login - - + + - + ahriman_web_views_base->ahriman_web_views_user_logout - - + + - + ahriman_web_views_index->ahriman_web_routes - + + + - + ahriman_web_views_service - -ahriman. -web. -views. -service + +ahriman. +web. +views. +service - + ahriman_web_views_service->ahriman_web_routes - + - + ahriman_web_views_service_add->ahriman_web_routes - - + - + ahriman_web_views_service_reload_auth->ahriman_web_routes - + + - + ahriman_web_views_service_remove->ahriman_web_routes - + - + ahriman_web_views_service_request->ahriman_web_routes - - + - + ahriman_web_views_service_search->ahriman_web_routes - + - + ahriman_web_views_status - -ahriman. -web. -views. -status + +ahriman. +web. +views. +status - + ahriman_web_views_status->ahriman_web_routes - + - + ahriman_web_views_status_ahriman->ahriman_web_routes - + + + - + ahriman_web_views_status_package->ahriman_web_routes - + - + ahriman_web_views_status_packages->ahriman_web_routes - + - + ahriman_web_views_status_status->ahriman_web_routes - + - + ahriman_web_views_user - -ahriman. -web. -views. -user + +ahriman. +web. +views. +user - + ahriman_web_views_user->ahriman_web_routes - - - + + + - + ahriman_web_views_user_login->ahriman_web_routes - + - + ahriman_web_views_user_logout->ahriman_web_routes - + - + ahriman_web_web->ahriman_application_handlers_web - - + - + aioauthclient - -aioauthclient + +aioauthclient - + aioauthclient->ahriman_core_auth_oauth - + - + aiohttp - -aiohttp + +aiohttp - + aiohttp->ahriman_web_middlewares - - + + - + aiohttp->ahriman_web_middlewares_auth_handler - - - - + + + + - + aiohttp->ahriman_web_middlewares_exception_handler - - + + + - + aiohttp->ahriman_web_routes - + + - + aiohttp->ahriman_web_views_base - + + + - + aiohttp->ahriman_web_views_service_add - - + + - + aiohttp->ahriman_web_views_service_reload_auth - - - + + + - + aiohttp->ahriman_web_views_service_remove - + + - + aiohttp->ahriman_web_views_service_request - - + + - + aiohttp->ahriman_web_views_service_search - - + + - + aiohttp->ahriman_web_views_status_ahriman - - - - - + + - + aiohttp->ahriman_web_views_status_package - - + + + - + aiohttp->ahriman_web_views_status_packages - - - - - + + + + - + aiohttp->ahriman_web_views_status_status - - + + - + aiohttp->ahriman_web_views_user_login - - + + + + - + aiohttp->ahriman_web_views_user_logout - - + + + - + aiohttp->ahriman_web_web - - - + - + aiohttpjinja2 - -aiohttpjinja2 + +aiohttpjinja2 - + aiohttp->aiohttpjinja2 - - + + - + aiohttpsession - -aiohttpsession + +aiohttpsession - + aiohttp->aiohttpsession - - + + - + aiohttpdebugtoolbar - -aiohttpdebugtoolbar + +aiohttpdebugtoolbar - + aiohttpdebugtoolbar->ahriman_web_web - - - + - + aiohttpjinja2->ahriman_web_views_index - - + + - + aiohttpjinja2->ahriman_web_web - + + - + aiohttpsecurity - -aiohttpsecurity + +aiohttpsecurity - + aiohttpsecurity->ahriman_core_auth_helpers - - + + + - + aiohttpsecurity->ahriman_web_middlewares_auth_handler - + + + - + aiohttpsecurity->ahriman_web_views_service_reload_auth - - + + + - + aiohttpsession->ahriman_web_middlewares_auth_handler - + - + aur - -aur + +aur - + aur->ahriman_application_handlers_search - - - + - + aur->ahriman_models_package - - - + + - + aur->ahriman_web_views_service_search - - + - + boto3 - -boto3 + +boto3 - + boto3->ahriman_core_upload_s3 - - + - + cryptography - -cryptography + +cryptography - + cryptography->ahriman_web_middlewares_auth_handler - + + - + cryptography->aiohttpsession - - - + + + - + requests - -requests + +requests - + cryptography->requests - - + + - + jinja2 - -jinja2 + +jinja2 - + jinja2->ahriman_core_report_jinja_template - - + + - + jinja2->ahriman_web_web - - - - + + + - + jinja2->aiohttpjinja2 - - + + - + passlib - -passlib + +passlib - + passlib->ahriman_models_user - - + + - + pyalpm - -pyalpm + +pyalpm - + pyalpm->ahriman_core_alpm_pacman - - + + - + pyalpm->ahriman_models_package - - - + + - + pyalpm->ahriman_models_package_description - - - - + + - + requests->ahriman_core_sign_gpg - - + + + + + - + requests->ahriman_core_status_web_client - - + + + + + + + +requests->ahriman_core_upload_github + + - + requests->ahriman_core_util - - + + - + requests->aur - - + + - + srcinfo - -srcinfo + +srcinfo - + srcinfo->ahriman_models_package - + diff --git a/docs/ahriman.1 b/docs/ahriman.1 index b1c5c15a..a9fd0231 100644 --- a/docs/ahriman.1 +++ b/docs/ahriman.1 @@ -3,7 +3,7 @@ ahriman .SH SYNOPSIS .B ahriman -[-h] [-a ARCHITECTURE] [-c CONFIGURATION] [--force] [-l LOCK] [--no-report] [-q] [--unsafe] [-v] {aur-search,search,key-import,package-add,add,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} ... +[-h] [-a ARCHITECTURE] [-c CONFIGURATION] [--force] [-l LOCK] [--no-report] [-q] [--unsafe] [-v] {aur-search,search,key-import,package-add,add,package-update,package-remove,remove,package-status,status,package-status-remove,package-status-update,status-update,patch-add,patch-list,patch-remove,repo-check,check,repo-clean,clean,repo-config,config,repo-init,init,repo-rebuild,rebuild,repo-remove-unknown,remove-unknown,repo-report,report,repo-setup,setup,repo-sign,sign,repo-sync,sync,repo-update,update,user-add,user-remove,web} ... .SH DESCRIPTION ArcH Linux ReposItory MANager .SH OPTIONS @@ -34,7 +34,7 @@ force disable any logging .TP \fB\-\-unsafe\fR -allow to run ahriman as non\-ahriman user +allow to run ahriman as non\-ahriman user. Some actions might be unavailable .TP \fB\-v\fR, \fB\-\-version\fR @@ -65,13 +65,13 @@ remove package status update package status .TP \fBahriman\fR \fI\,patch-add\/\fR -patches control +add patch set .TP \fBahriman\fR \fI\,patch-list\/\fR -patches control +list patch sets .TP \fBahriman\fR \fI\,patch-remove\/\fR -patches control +remove patch set .TP \fBahriman\fR \fI\,repo-check\/\fR check for updates @@ -107,10 +107,10 @@ sync repository update packages .TP \fBahriman\fR \fI\,user-add\/\fR -create or update user for web services +create or update user .TP \fBahriman\fR \fI\,user-remove\/\fR -remove user for web services +remove user .TP \fBahriman\fR \fI\,web\/\fR web server @@ -137,7 +137,7 @@ search terms, can be specified multiple times .SH OPTIONS 'ahriman key-import' usage: ahriman key-import [-h] [--key-server KEY_SERVER] key -import PGP key from public sources to repository user +import PGP key from public sources to the repository user .TP \fBkey\fR @@ -149,22 +149,22 @@ key server for key import .SH OPTIONS 'ahriman package-add' usage: ahriman package-add [-h] [-n] - [-s {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR}] + [-s {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}] [--without-dependencies] package [package ...] -add package +add existing or new package to the build queue .TP \fBpackage\fR -package base/name or archive path +package base/name or path to local files .TP \fB\-n\fR, \fB\-\-now\fR run update function after .TP -\fB\-s\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR}, \fB\-\-source\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR} +\fB\-s\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}, \fB\-\-source\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local} package source .TP @@ -173,22 +173,46 @@ do not add dependencies .SH OPTIONS 'ahriman add' usage: ahriman package-add [-h] [-n] - [-s {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR}] + [-s {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}] [--without-dependencies] package [package ...] -add package +add existing or new package to the build queue .TP \fBpackage\fR -package base/name or archive path +package base/name or path to local files .TP \fB\-n\fR, \fB\-\-now\fR run update function after .TP -\fB\-s\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR}, \fB\-\-source\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.Directory,PackageSource.AUR} +\fB\-s\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}, \fB\-\-source\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local} +package source + +.TP +\fB\-\-without\-dependencies\fR +do not add dependencies + +.SH OPTIONS 'ahriman package-update' +usage: ahriman package-add [-h] [-n] + [-s {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}] + [--without-dependencies] + package [package ...] + +add existing or new package to the build queue + +.TP +\fBpackage\fR +package base/name or path to local files + +.TP +\fB\-n\fR, \fB\-\-now\fR +run update function after + +.TP +\fB\-s\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local}, \fB\-\-source\fR {PackageSource.Auto,PackageSource.Archive,PackageSource.AUR,PackageSource.Directory,PackageSource.Local} package source .TP @@ -198,7 +222,7 @@ do not add dependencies .SH OPTIONS 'ahriman package-remove' usage: ahriman package-remove [-h] package [package ...] -remove package +remove package from the repository .TP \fBpackage\fR @@ -208,7 +232,7 @@ package name or base .SH OPTIONS 'ahriman remove' usage: ahriman package-remove [-h] package [package ...] -remove package +remove package from the repository .TP \fBpackage\fR @@ -296,7 +320,7 @@ new status .SH OPTIONS 'ahriman patch-add' usage: ahriman patch-add [-h] [-t TRACK] package -create/update for sources +create or update source patches .TP \fBpackage\fR @@ -329,7 +353,7 @@ package base .SH OPTIONS 'ahriman repo-check' usage: ahriman repo-check [-h] [--no-vcs] [package ...] -check for updates. Same as update \-\-dry\-run \-\-no\-manual +check for packages updates. Same as update \-\-dry\-run \-\-no\-manual .TP \fBpackage\fR @@ -342,7 +366,7 @@ do not check VCS packages .SH OPTIONS 'ahriman check' usage: ahriman repo-check [-h] [--no-vcs] [package ...] -check for updates. Same as update \-\-dry\-run \-\-no\-manual +check for packages updates. Same as update \-\-dry\-run \-\-no\-manual .TP \fBpackage\fR @@ -355,7 +379,7 @@ do not check VCS packages .SH OPTIONS 'ahriman repo-clean' usage: ahriman repo-clean [-h] [--no-build] [--no-cache] [--no-chroot] [--no-manual] [--no-packages] -clear local caches +remove local caches .TP @@ -381,7 +405,7 @@ do not clear directory with built packages .SH OPTIONS 'ahriman clean' usage: ahriman repo-clean [-h] [--no-build] [--no-cache] [--no-chroot] [--no-manual] [--no-packages] -clear local caches +remove local caches .TP @@ -407,14 +431,14 @@ do not clear directory with built packages .SH OPTIONS 'ahriman repo-config' usage: ahriman repo-config [-h] -dump configuration for specified architecture +dump configuration for the specified architecture .SH OPTIONS 'ahriman config' usage: ahriman repo-config [-h] -dump configuration for specified architecture +dump configuration for the specified architecture @@ -435,7 +459,7 @@ create empty repository tree. Optional command for auto architecture support .SH OPTIONS 'ahriman repo-rebuild' usage: ahriman repo-rebuild [-h] [--depends-on DEPENDS_ON] -rebuild whole repository +force rebuild whole repository .TP @@ -445,7 +469,7 @@ only rebuild packages that depend on specified package .SH OPTIONS 'ahriman rebuild' usage: ahriman repo-rebuild [-h] [--depends-on DEPENDS_ON] -rebuild whole repository +force rebuild whole repository .TP @@ -455,7 +479,7 @@ only rebuild packages that depend on specified package .SH OPTIONS 'ahriman repo-remove-unknown' usage: ahriman repo-remove-unknown [-h] [--dry-run] -remove packages which are missing in AUR +remove packages which are missing in AUR and do not have local PKGBUILDs .TP @@ -465,7 +489,7 @@ just perform check for packages without removal .SH OPTIONS 'ahriman remove-unknown' usage: ahriman repo-remove-unknown [-h] [--dry-run] -remove packages which are missing in AUR +remove packages which are missing in AUR and do not have local PKGBUILDs .TP @@ -475,7 +499,7 @@ just perform check for packages without removal .SH OPTIONS 'ahriman repo-report' usage: ahriman repo-report [-h] [target ...] -generate report +generate repository report according to current settings .TP \fBtarget\fR @@ -485,7 +509,7 @@ target to generate report .SH OPTIONS 'ahriman report' usage: ahriman repo-report [-h] [target ...] -generate report +generate repository report according to current settings .TP \fBtarget\fR @@ -575,7 +599,7 @@ port of the web service .SH OPTIONS 'ahriman repo-sign' usage: ahriman repo-sign [-h] [package ...] -(re\-)sign packages and repository database +(re\-)sign packages and repository database according to current settings .TP \fBpackage\fR @@ -585,7 +609,7 @@ sign only specified packages .SH OPTIONS 'ahriman sign' usage: ahriman repo-sign [-h] [package ...] -(re\-)sign packages and repository database +(re\-)sign packages and repository database according to current settings .TP \fBpackage\fR @@ -595,7 +619,7 @@ sign only specified packages .SH OPTIONS 'ahriman repo-sync' usage: ahriman repo-sync [-h] [target ...] -sync packages to remote server +sync repository files to remote server according to current settings .TP \fBtarget\fR @@ -605,7 +629,7 @@ target to sync .SH OPTIONS 'ahriman sync' usage: ahriman repo-sync [-h] [target ...] -sync packages to remote server +sync repository files to remote server according to current settings .TP \fBtarget\fR @@ -615,7 +639,7 @@ target to sync .SH OPTIONS 'ahriman repo-update' usage: ahriman repo-update [-h] [--dry-run] [--no-aur] [--no-manual] [--no-vcs] [package ...] -run updates +check for packages updates and run build process if requested .TP \fBpackage\fR @@ -640,7 +664,7 @@ do not check VCS packages .SH OPTIONS 'ahriman update' usage: ahriman repo-update [-h] [--dry-run] [--no-aur] [--no-manual] [--no-vcs] [package ...] -run updates +check for packages updates and run build process if requested .TP \fBpackage\fR @@ -697,7 +721,7 @@ set file permissions to user\-only .SH OPTIONS 'ahriman user-remove' usage: ahriman user-remove [-h] [--no-reload] [-s] username -remove user from the user mapping and write the configuration +remove user from the user mapping and update the configuration .TP \fBusername\fR diff --git a/docs/architecture.md b/docs/architecture.md index 5fa7e6b2..e91bb4fd 100644 --- a/docs/architecture.md +++ b/docs/architecture.md @@ -133,6 +133,16 @@ OAuth's implementation also allows authenticating users via username + password In order to configure users there is special command. +## Remote synchronization + +There are several supported synchronization providers, currently they are `rsync`, `s3`, `github`. + +`rsync` provider does not have any specific logic except for running external rsync application with configured arguments. The service does not handle SSH configuration, thus it has to be configured before running application manually. + +`s3` provider uses `boto3` package and implements sync feature. The files are stored in architecture directory (e.g. if bucket is `repository`, packages will be stored in `repository/x86_64` for the `x86_64` architecture), bucket must be created before any action and API key must have permissions to write to the bucket. No external configuration required. In order to upload only changed files the service compares calculated hashes with the Amazon ETags, used realization is described [here](https://teppen.io/2018/10/23/aws_s3_verify_etags/). + +`github` provider authenticates through basic auth, API key with repository write permissions is required. There will be created a release with the name of the architecture in case if it does not exist; files will be uploaded to the release assets. It also stores array of files and their MD5 checksums in release body in order to upload only changed ones. According to the Github API in case if there is already uploaded asset with the same name (e.g. database files), asset will be removed first. + ## Additional features Some features require optional dependencies to be installed: diff --git a/docs/configuration.md b/docs/configuration.md index b76f155d..86f0878b 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -121,7 +121,7 @@ Group name must refer to architecture, e.g. it should be `github:x86_64` for x86 Group name must refer to architecture, e.g. it should be `rsync:x86_64` for x86_64 architecture. Requires `rsync` package to be installed. Do not forget to configure ssh for user `ahriman`. * `command` - rsync command to run, space separated list of string, required. -* `remote` - remote server to rsync (e.g. `1.2.3.4:5678:path/to/sync`), string, required. +* `remote` - remote server to rsync (e.g. `1.2.3.4:path/to/sync`), string, required. ### `s3:*` groups diff --git a/docs/faq.md b/docs/faq.md new file mode 100644 index 00000000..473f8458 --- /dev/null +++ b/docs/faq.md @@ -0,0 +1,372 @@ +# FAQ + +## General topics + +### What is the purpose of the project? + +This project has been created in order to maintain self-hosted Arch Linux user repository without manual intervention - checking for updates and building packages. + +### How do I install it? + +TL;DR + +```shell +yay -S ahriman +sudo -u ahriman ahriman -a x86_64 init +sudo ahriman -a x86_64 repo-setup --packager "ahriman bot " --repository "repository" +systemctl enable --now ahriman@x86_64.timer +``` + +#### Long answer + +The idea is to install the package as usual, create working directory tree, create configuration for `sudo` and `devtools`. Detailed description of the setup instruction can be found [here](setup.md). + +### Okay, I've installed ahriman, how do I add new package? + +```shell +sudo -u ahriman ahriman package-add ahriman --now +``` + +`--now` flag is totally optional and just run `repo-update` subcommand after the registering the new package, Thus the extended flow is the following: + +```shell +sudo -u ahriman ahriman package-add ahriman +sudo -u ahriman ahriman repo-update +``` + +### AUR is fine, but I would like to create package from local PKGBUILD + +TL;DR + +```shell +sudo -u ahriman ahriman package-add /path/to/local/directory/with/PKGBUILD --now +``` + +Before using this command you will need to create local directory, put `PKGBUILD` there and generate `.SRCINFO` by using `makepkg --printsrcinfo > .SRCINFO` command. These packages will be stored locally and _will be ignored_ during automatic update; in order to update the package you will need to run `package-add` command again. + +### But I just wanted to change PKGBUILD from AUR a bit! + +Well it is supported also. + +1. Clone sources from AUR. +2. Make changes you would like to (e.g. edit `PKGBUILD`, add external patches). +3. Run `sudo -u ahriman ahriman patch-add /path/to/local/directory/with/PKGBUILD`. + +The last command will calculate diff from current tree to the `HEAD` and will store it locally. Patches will be applied on any package actions (e.g. it can be used for dependency management). + +### Package build fails because it cannot validate PGP signature of source files + +TL;DR + +```shell +sudo -u ahriman ahriman key-import ... +``` + +### How do I check if there are new commits for VCS packages? + +Normally the service handles VCS packages correctly, but it requires additional dependencies: + +```shell +pacman -S breezy darcs mercurial subversion +``` + +### I would like to remove package because it is no longer needed/moved to official repositories + +```shell +sudo -u ahriman ahriman package-remove ahriman +``` + +Also, there is command `repo-remove-unknown` which checks packages in AUR and local storage and removes ones which have been removed. + +Remove commands also remove any package files (patches, caches etc). + +### There is new major release of %library-name%, how do I rebuild packages? + +TL;DR + +```shell +sudo -u ahriman ahriman repo-rebuild --depends-on python +``` + +You can even rebuild the whole repository (which is particular useful in case if you would like to change packager) if you do not supply `--depends-on` option. + +However, note that you do not need to rebuild repository in case if you just changed signing option, just use `repo-sign` command instead. + +### Hmm, I have packages built, but how can I use it? + +Add the following lines to your `pacman.conf`: + +```ini +[repository] +Server = file:///var/lib/ahriman/repository/x86_64 +``` + +(You might need to add `SigLevel` option according to the pacman documentation.) + +## Remote synchronization + +### Wait I would like to use the repository from another server + +There are several choices: + +1. Easy and cheap, just share your local files through the internet, e.g. for `nginx`: + + ``` + server { + location /x86_64 { + root /var/lib/ahriman/repository/x86_64; + autoindex on; + } + } + ``` + +2. You can also upload your packages using `rsync` to any available server. In order to use it you would need to configure ahriman first: + + ```ini + [upload] + target = rsync + + [rsync] + remote = 192.168.0.1:/srv/repo + ``` + + After that just add `/srv/repo` to the `pacman.conf` as usual. You can also upload to S3 (e.g. `Server = https://s3.eu-central-1.amazonaws.com/repository/x86_64`) or to Github (e.g. `Server = https://github.com/ahriman/repository/releases/download/x86_64`). + +### How do I configure S3? + +1. Install dependencies: + + ```shell + pacman -S python-boto3 + ``` + +3. Create a bucket. +4. Create user with write access to the bucket: + + ``` + { + "Version": "2012-10-17", + "Statement": [ + { + "Sid": "ListObjectsInBucket", + "Effect": "Allow", + "Action": [ + "s3:ListBucket" + ], + "Resource": [ + "arn:aws:s3:::repository" + ] + }, + { + "Sid": "AllObjectActions", + "Effect": "Allow", + "Action": "s3:*Object", + "Resource": [ + "arn:aws:s3:::repository/*" + ] + } + ] + } + ``` + +5. Create an API key for the user and store it. +6. Configure the service as following: + + ```ini + [upload] + target = s3 + + [s3] + access_key = ... + bucket = repository + region = eu-central-1 + secret_key = ... + ``` + +### How do I configure Github? + +1. Create a repository. +2. [Create API key](https://github.com/settings/tokens) with scope `public_repo`. +3. Configure the service as following: + + ```ini + [upload] + target = github + + [github] + api_key = ... + owner = ahriman + repository = repository + ``` + +## Reporting + +### I would like to get report to email + +1. Install dependencies: + + ```shell + yay -S python-jinja + ``` + +2. Configure the service: + + ```ini + [report] + target = email + + [email] + host = smtp.example.com + link_path = http://example.com/x86_64 + password = ... + port = 465 + receivers = me@example.com + sender = me@example.com + user = me@example.com + ``` + +### I'm using synchronization to S3 and would like to generate index page + +1. Install dependencies: + + ```shell + yay -S python-jinja + ``` + +2. Configure the service: + + ```ini + [report] + target = html + + [html] + path = /var/lib/ahriman/repository/x86_64/index.html + link_path = http://example.com/x86_64 + ``` + +After these steps `index.html` file will be automatically synced to S3 + +## Web service + +### Readme mentions web interface, how do I use it? + +1. Install dependencies: + + ```shell + yay -S python-aiohttp python-aiohttp-jinja2 + ``` + +2. Configure service: + + ```ini + [web] + port = 8080 + ``` + +3. Start the web service `systemctl enable --now ahriman-web@x86_64`. + +### I would like to limit user access to the status page + +1. Install dependencies 😊: + + ```shell + yay -S python-aiohttp-security python-aiohttp-session python-cryptography + ``` + +2. Configure the service to enable authorization: + + ```ini + [auth] + target = configuration + ``` + +3. Create user for the service: + + ```shell + sudo -u ahriman ahriman user-add --as-service -r write api + ``` + + This command will ask for the password, just type it in stdin; _do not_ leave the field blank, user will not be able to authorize. + +4. Create end-user `sudo -u ahriman ahriman user-add -r write my-first-user` with password. +5. Restart web service `systemctl restart ahriman-web@x86_64`. + +### I would like to use OAuth + +1. Create OAuth web application, download its `client_id` and `client_secret`. +2. Guess what? Install dependencies: + + ```shell + yay -S python-aiohttp-security python-aiohttp-session python-cryptography python-aioauth-client + ``` + +3. Configure the service: + + ```ini + [auth] + target = oauth + client_id = ... + client_secret = ... + + [web] + address = https://example.com + ``` + + Configure `oauth_provider` and `oauth_scopes` in case if you would like to use different from Google provider. Scope must grant access to user email. `web.address` is required to make callback URL available from internet. + +4. Create service user: + + ```shell + sudo -u ahriman ahriman user-add --as-service -r write api + ``` + +5. Create end-user `sudo -u ahriman ahriman user-add -r write my-first-user`. When it will ask for the password leave it blank. +6. Restart web service `systemctl restart ahriman-web@x86_64`. + +## Other topics + +### How does it differ from %another-manager%? + +Short answer - I do not know. + +#### [archrepo2](https://github.com/lilydjwg/archrepo2) + +Don't know, haven't tried it. But it lacks of documentation at least. + +* Web interface. +* No synchronization and reporting. +* `archrepo2` actively uses direct shell calls and `yaourt` components. +* It has constantly running process instead of timer process (it is not pro or con). + +#### [repo-scripts](https://github.com/arcan1s/repo-scripts) + +Though originally I've created ahriman by trying to improve the project, it still lacks a lot of features: + +* Web interface. +* Better reporting with template support. +* Synchronization features (there was only `rsync` based). +* Local packages and patches support. +* No dependency management. +* And so on. + +`repo-scripts` also have bad architecture and bad quality code and uses out-of-dated `yaourt` and `package-query`. + +### I would like to check service logs + +By default, the service writes logs to `/dev/log` which can be accessed by using `journalctl` command (logs are written to the journal of the user under which command is run). + +You can also edit configuration and forward logs to `stderr`, just change `handlers` value, e.g.: + +```shell +sed -i 's/handlers = syslog_handler/handlers = console_handler/g' /etc/ahriman.ini.d/logging.ini +``` + +You can even configure logging as you wish, but kindly refer to python `logging` module configuration. + +### Html customization + +It is possible to customize html templates. In order to do so, create files somewhere (refer to Jinja2 documentation and the service source code for available parameters) and put `template_path` to configuration pointing to this directory. + +### I did not find my question + +[Create an issue](https://github.com/arcan1s/ahriman/issues) with type **Question**. diff --git a/docs/setup.md b/docs/setup.md index c03c3f98..48a29c27 100644 --- a/docs/setup.md +++ b/docs/setup.md @@ -59,7 +59,7 @@ 6. Add packages by using `ahriman package-add {package}` command: ```shell - sudo -u ahriman ahriman -a x86_64 package-add yay --now + sudo -u ahriman ahriman -a x86_64 package-add ahriman --now ``` ## User creation diff --git a/package/archlinux/PKGBUILD b/package/archlinux/PKGBUILD index 757f533c..83ba8b06 100644 --- a/package/archlinux/PKGBUILD +++ b/package/archlinux/PKGBUILD @@ -11,7 +11,6 @@ depends=('devtools' 'git' 'pyalpm' 'python-aur' 'python-passlib' 'python-srcinfo makedepends=('python-pip') optdepends=('breezy: -bzr packages support' 'darcs: -darcs packages support' - 'gnupg: package and repository sign' 'mercurial: -hg packages support' 'python-aioauth-client: web server with OAuth2 authorization' 'python-aiohttp: web server' diff --git a/setup.py b/setup.py index d25443e8..3c81a41b 100644 --- a/setup.py +++ b/setup.py @@ -17,7 +17,7 @@ setup( description="ArcH Linux ReposItory MANager", - author="arcanis", + author="ahriman team", author_email="", url="https://github.com/arcan1s/ahriman", diff --git a/src/ahriman/application/ahriman.py b/src/ahriman/application/ahriman.py index 4f5f303b..6d1695d6 100644 --- a/src/ahriman/application/ahriman.py +++ b/src/ahriman/application/ahriman.py @@ -56,15 +56,12 @@ def _parser() -> argparse.ArgumentParser: action="append") parser.add_argument("-c", "--configuration", help="configuration path", type=Path, default=Path("/etc/ahriman.ini")) parser.add_argument("--force", help="force run, remove file lock", action="store_true") - parser.add_argument( - "-l", - "--lock", - help="lock file", - type=Path, - default=Path(tempfile.gettempdir()) / "ahriman.lock") + parser.add_argument("-l", "--lock", help="lock file", type=Path, + default=Path(tempfile.gettempdir()) / "ahriman.lock") parser.add_argument("--no-report", help="force disable reporting to web service", action="store_true") parser.add_argument("-q", "--quiet", help="force disable any logging", action="store_true") - parser.add_argument("--unsafe", help="allow to run ahriman as non-ahriman user", action="store_true") + parser.add_argument("--unsafe", help="allow to run ahriman as non-ahriman user. Some actions might be unavailable", + action="store_true") parser.add_argument("-v", "--version", action="version", version=version.__version__) subparsers = parser.add_subparsers(title="command", help="command to run", dest="command", required=True) @@ -117,7 +114,7 @@ def _set_key_import_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("key-import", help="import PGP key", - description="import PGP key from public sources to repository user", + description="import PGP key from public sources to the repository user", epilog="By default ahriman runs build process with package sources validation " "(in case if signature and keys are available in PKGBUILD). This process will " "fail in case if key is not known for build user. This subcommand can be used " @@ -135,7 +132,8 @@ def _set_package_add_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("package-add", aliases=["add"], help="add package", description="add package", + parser = root.add_parser("package-add", aliases=["add", "package-update"], help="add package", + description="add existing or new package to the build queue", epilog="This subcommand should be used for new package addition. It also supports flag " "--now in case if you would like to build the package immediately. " "You can add new package from one of supported sources: " @@ -161,8 +159,8 @@ def _set_package_remove_parser(root: SubParserAction) -> argparse.ArgumentParser :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("package-remove", aliases=["remove"], help="remove package", description="remove package", - formatter_class=_formatter) + parser = root.add_parser("package-remove", aliases=["remove"], help="remove package", + description="remove package from the repository", formatter_class=_formatter) parser.add_argument("package", help="package name or base", nargs="+") parser.set_defaults(handler=handlers.Remove) return parser @@ -227,7 +225,7 @@ def _set_patch_add_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("patch-add", help="patches control", description="create/update for sources", + parser = root.add_parser("patch-add", help="add patch set", description="create or update source patches", epilog="In order to add a patch set for the package you will need to clone " "the AUR package manually, add required changes (e.g. external patches, " "edit PKGBUILD) and run command, e.g. `ahriman patch path/to/directory`. " @@ -247,8 +245,8 @@ def _set_patch_list_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("patch-list", help="patches control", description="list available patches for the package", - formatter_class=_formatter) + parser = root.add_parser("patch-list", help="list patch sets", + description="list available patches for the package", formatter_class=_formatter) parser.add_argument("package", help="package base") parser.set_defaults(handler=handlers.Patch, action=Action.List, architecture=[""], lock=None, no_report=True) return parser @@ -260,7 +258,7 @@ def _set_patch_remove_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("patch-remove", help="patches control", description="remove patches for the package", + parser = root.add_parser("patch-remove", help="remove patch set", description="remove patches for the package", formatter_class=_formatter) parser.add_argument("package", help="package base") parser.set_defaults(handler=handlers.Patch, action=Action.Remove, architecture=[""], lock=None, no_report=True) @@ -274,7 +272,7 @@ def _set_repo_check_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-check", aliases=["check"], help="check for updates", - description="check for updates. Same as update --dry-run --no-manual", + description="check for packages updates. Same as update --dry-run --no-manual", formatter_class=_formatter) parser.add_argument("package", help="filter check by package base", nargs="*") parser.add_argument("--no-vcs", help="do not check VCS packages", action="store_true") @@ -289,7 +287,7 @@ def _set_repo_clean_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-clean", aliases=["clean"], help="clean local caches", - description="clear local caches", + description="remove local caches", epilog="The subcommand clears every temporary directories (builds, caches etc). Normally " "you should not run this command manually. Also in case if you are going to clear " "the chroot directories you will need root privileges.", @@ -310,7 +308,7 @@ def _set_repo_config_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-config", aliases=["config"], help="dump configuration", - description="dump configuration for specified architecture", + description="dump configuration for the specified architecture", formatter_class=_formatter) parser.set_defaults(handler=handlers.Dump, lock=None, no_report=True, quiet=True, unsafe=True) return parser @@ -336,7 +334,7 @@ def _set_repo_rebuild_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-rebuild", aliases=["rebuild"], help="rebuild repository", - description="rebuild whole repository", formatter_class=_formatter) + description="force rebuild whole repository", formatter_class=_formatter) parser.add_argument("--depends-on", help="only rebuild packages that depend on specified package", action="append") parser.set_defaults(handler=handlers.Rebuild) return parser @@ -349,7 +347,7 @@ def _set_repo_remove_unknown_parser(root: SubParserAction) -> argparse.ArgumentP :return: created argument parser """ parser = root.add_parser("repo-remove-unknown", aliases=["remove-unknown"], help="remove unknown packages", - description="remove packages which are missing in AUR", + description="remove packages which are missing in AUR and do not have local PKGBUILDs", formatter_class=_formatter) parser.add_argument("--dry-run", help="just perform check for packages without removal", action="store_true") parser.set_defaults(handler=handlers.RemoveUnknown) @@ -362,7 +360,8 @@ def _set_repo_report_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("repo-report", aliases=["report"], help="generate report", description="generate report", + parser = root.add_parser("repo-report", aliases=["report"], help="generate report", + description="generate repository report according to current settings", epilog="Create and/or update repository report as configured.", formatter_class=_formatter) parser.add_argument("target", help="target to generate report", nargs="*") @@ -401,7 +400,7 @@ def _set_repo_sign_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-sign", aliases=["sign"], help="sign packages", - description="(re-)sign packages and repository database", + description="(re-)sign packages and repository database according to current settings", epilog="Sign repository and/or packages as configured.", formatter_class=_formatter) parser.add_argument("package", help="sign only specified packages", nargs="*") @@ -416,7 +415,7 @@ def _set_repo_sync_parser(root: SubParserAction) -> argparse.ArgumentParser: :return: created argument parser """ parser = root.add_parser("repo-sync", aliases=["sync"], help="sync repository", - description="sync packages to remote server", + description="sync repository files to remote server according to current settings", epilog="Synchronize the repository to remote services as configured.", formatter_class=_formatter) parser.add_argument("target", help="target to sync", nargs="*") @@ -430,7 +429,8 @@ def _set_repo_update_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("repo-update", aliases=["update"], help="update packages", description="run updates", + parser = root.add_parser("repo-update", aliases=["update"], help="update packages", + description="check for packages updates and run build process if requested", formatter_class=_formatter) parser.add_argument("package", help="filter check by package base", nargs="*") parser.add_argument("--dry-run", help="just perform check for updates, same as check command", action="store_true") @@ -447,7 +447,7 @@ def _set_user_add_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("user-add", help="create or update user for web services", + parser = root.add_parser("user-add", help="create or update user", description="update user for web services with the given password and role. " "In case if password was not entered it will be asked interactively", formatter_class=_formatter) @@ -470,8 +470,8 @@ def _set_user_remove_parser(root: SubParserAction) -> argparse.ArgumentParser: :param root: subparsers for the commands :return: created argument parser """ - parser = root.add_parser("user-remove", help="remove user for web services", - description="remove user from the user mapping and write the configuration", + parser = root.add_parser("user-remove", help="remove user", + description="remove user from the user mapping and update the configuration", formatter_class=_formatter) parser.add_argument("username", help="username for web service") parser.add_argument("--no-reload", help="do not reload authentication module", action="store_true") diff --git a/src/ahriman/core/auth/oauth.py b/src/ahriman/core/auth/oauth.py index 2450d06b..eb0167e0 100644 --- a/src/ahriman/core/auth/oauth.py +++ b/src/ahriman/core/auth/oauth.py @@ -104,7 +104,6 @@ class OAuth(Mapping): access_token, _ = await client.get_access_token(code, redirect_uri=self.redirect_uri) client.access_token = access_token - print(f"HEEELOOOO {client}") user, _ = await client.user_info() username: str = user.email # type: ignore return username diff --git a/src/ahriman/core/exceptions.py b/src/ahriman/core/exceptions.py index 8bd982a4..ac1a38cd 100644 --- a/src/ahriman/core/exceptions.py +++ b/src/ahriman/core/exceptions.py @@ -42,7 +42,8 @@ class DuplicateRun(RuntimeError): """ default constructor """ - RuntimeError.__init__(self, "Another application instance is run") + RuntimeError.__init__( + self, "Another application instance is run. This error can be suppressed by using --force flag.") class DuplicateUser(ValueError):