Command-line interface
Stash comes with a command-line interface (CLI) for administrative actions. It is documented below and is not to be confused with user CLIs that can be used to interact with a Stash instance.
stash --help
NAME:
stash - Beyond coding. We forge.
USAGE:
stash [global options] [command [command options]]
DESCRIPTION:
By default, stash will start serving using the web-server with no argument, which can alternatively be run by running the subcommand "web".
COMMANDS:
help, h Shows a list of commands or help for one command
web Start the Stash web server
serv (internal) Should only be called by SSH shell
hook (internal) Should only be called by Git
keys (internal) Should only be called by SSH server
dump Dump Stash files and database
admin Perform common administrative operations
migrate Migrate the database
doctor Diagnose and optionally fix problems, convert or re-create database tables
manager Manage the running stash process
embedded Extract embedded resources
migrate-storage Migrate the storage
dump-repo Dump the repository from git/github/gitea/gitlab
restore-repo Restore the repository from disk
actions Manage Stash Actions
cert Generate self-signed certificate
generate Generate Stash's secrets/keys/tokens
stash-cli Stash CLI
GLOBAL OPTIONS:
--version, -v print the version
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
--version, -v print the version
stash-cli
NAME:
stash stash-cli - Stash CLI
USAGE:
stash stash-cli [command [command options]]
COMMANDS:
actions Commands for managing Stash Actions
OPTIONS:
--help, -h show help
stash-cli actions
NAME:
stash stash-cli actions - Commands for managing Stash Actions
USAGE:
stash stash-cli actions [command [command options]]
COMMANDS:
generate-runner-token Generate a new token for a runner to use to register with the server
generate-secret Generate a secret suitable for input to the register subcommand
register Idempotent registration of a runner using a shared secret
OPTIONS:
--help, -h show help
stash-cli actions generate-runner-token
NAME:
stash stash-cli actions generate-runner-token - Generate a new token for a runner to use to register with the server
USAGE:
stash stash-cli actions generate-runner-token [options]
OPTIONS:
--scope string, -s string {owner}[/{repo}] - leave empty for a global runner
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
stash-cli actions generate-secret
NAME:
stash stash-cli actions generate-secret - Generate a secret suitable for input to the register subcommand
USAGE:
stash stash-cli actions generate-secret [options]
OPTIONS:
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
stash-cli actions register
NAME:
stash stash-cli actions register - Idempotent registration of a runner using a shared secret
USAGE:
stash stash-cli actions register [options]
OPTIONS:
--secret string the secret the runner will use to connect as a 40 character hexadecimal string
--secret-stdin string the secret the runner will use to connect as a 40 character hexadecimal string, read from stdin
--secret-file string path to the file containing the secret the runner will use to connect as a 40 character hexadecimal string
--scope string, -s string {owner}[/{repo}] - leave empty for a global runner
--labels string comma separated list of labels supported by the runner (e.g. docker,ubuntu-latest,self-hosted) (not required since v1.21)
--keep-labels do not affect the labels when updating an existing runner
--name string name of the runner (default runner) (default: "runner")
--version string version of the runner (not required since v1.21)
--ephemeral instruct Stash to permanently unregister this runner after it has run one job
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
web
NAME:
stash web - Start the Stash web server
USAGE:
stash web [options]
DESCRIPTION:
The Stash web server is the only thing you need to run,
and it takes care of all the other things for you
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--port string, -p string Temporary port number to prevent conflict (default: "3000")
--install-port string Temporary port number to run the install page on to prevent conflict (default: "3000")
--pid string, -P string Custom pid file path (default: "/run/gitea.pid")
--quiet, -q Only display Fatal logging errors until logging is set-up
--verbose Set initial logging to TRACE level until logging is properly set-up
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
dump
NAME:
stash dump - Dump Stash files and database
USAGE:
stash dump [options]
DESCRIPTION:
Dump compresses all related files and database into zip file.
It can be used for backup and capture Stash server image to send to maintainer
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--file string, -f string Name of the dump file which will be created. Supply '-' for stdout. See type for available types. (default: "stash-dump-<timestamp>.zip")
--verbose, -V Show process details
--quiet, -q Only display warnings and errors
--tempdir string, -t string Temporary dir path
--database string, -d string Specify the database SQL syntax: sqlite3, mysql, postgres
--skip-repository, -R Skip repositories
--skip-log, -L Skip logs
--skip-custom-dir Skip custom directory
--skip-lfs-data Skip LFS data
--skip-attachment-data Skip attachment data
--skip-package-data Skip package data
--skip-index Skip bleve index data
--skip-repo-archives Skip repository archives
--type value Dump output format: zip, tar, tar.sz, tar.gz, tar.xz, tar.bz2, tar.br, tar.lz4, tar.zst (default: zip)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin
NAME:
stash admin - Perform common administrative operations
USAGE:
stash admin [command [command options]]
COMMANDS:
user Modify users
repo-sync-releases Synchronize repository releases with tags
regenerate Regenerate specific files
auth Modify external auth providers
sendmail Send a message to all users
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
admin user
NAME:
stash admin user - Modify users
USAGE:
stash admin user [command [command options]]
COMMANDS:
create Create a new user in database
list List users
change-password Change a user's password
delete Delete specific user by id, name or email
generate-access-token Generate an access token for a specific user
create-authorized-integration
must-change-password Set the must change password flag for the provided users or all users
reset-mfa Remove all two-factor authentication configurations for a user
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
admin user create
NAME:
stash admin user create - Create a new user in database
USAGE:
stash admin user create [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Username. DEPRECATED: use username instead
--username string Username
--password string User password
--email string User email address
--admin User is an admin
--random-password Generate a random password for the user
--must-change-password Set this option to false to prevent forcing the user to change their password after initial login
--random-password-length int Length of the random password to be generated (default: 12)
--access-token Generate access token for the user
--access-token-name string Name of the generated access token (default: "gitea-admin")
--access-token-scopes string Scopes of the generated access token, comma separated. Examples: "all", "public-only,read:issue", "write:repository,write:user" (default: "all")
--restricted Make a restricted user account
--fullname string The full, human-readable name of the user
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user list
NAME:
stash admin user list - List users
USAGE:
stash admin user list [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--admin List only admin users
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user change-password
NAME:
stash admin user change-password - Change a user's password
USAGE:
stash admin user change-password [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--username string, -u string The user to change password for
--password string, -p string New password to set for user
--must-change-password User must change password
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user delete
NAME:
stash admin user delete - Delete specific user by id, name or email
USAGE:
stash admin user delete [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--id int ID of user of the user to delete (default: 0)
--username string, -u string Username of the user to delete
--email string, -e string Email of the user to delete
--purge Purge user, all their repositories, organizations and comments
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user generate-access-token
NAME:
stash admin user generate-access-token - Generate an access token for a specific user
USAGE:
stash admin user generate-access-token [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--username string, -u string Username
--token-name string, -t string Token name (default: "gitea-admin")
--raw Display only the token value
--scopes string Comma separated list of scopes to apply to access token, examples: "all", "public-only,read:issue", "write:repository,write:user" (default: "all")
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user create-authorized-integration
NAME:
stash admin user create-authorized-integration
USAGE:
stash admin user create-authorized-integration [options]
DESCRIPTION:
Creates an authorized integration. Authorized integrations allow Stash to
receive JWTs from external sources, validate their claims against
user-defined rules, and grant access to Stash's API on behalf of a user.
The issuer may be set to "urn:stash:authorized-integrations:actions"
to support JWTs from the local instance's Stash Actions, utilizing the
enable-openid-connect flag in a workflow.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--username string, -u string Username
--name string Name of the authorized integration for later identification
--description string Optional description for the authorized integration
--issuer string JWT issuer ('iss' claim), example: https://stash.example.org/api/actions
--claim-eq string=string [ --claim-eq string=string ] Zero-or-more claim equality checks, formatted as claim=value, example: "actor=someuser"
--claim-in string=string [ --claim-in string=string ] Zero-or-more claim equality in list checks, formatted as claim=value1,value2,... example: "actor=user1,user2"
--claim-glob string=string [ --claim-glob string=string ] Zero-or-more claim glob checks, formatted as claim=value, example: "sub=repo:stash/*:pull_request"
--claim-glob-in string=string [ --claim-glob-in string=string ] Zero-or-more claim glob in list checks, formatted as claim=va*ue1,va*ue2,... example: "sub=repo:*/*:pull_request,repo:*/*:refs:*"
--scope string [ --scope string ] One-or-more scopes to apply to access token, examples: "all", "read:issue", "write:repository" (default: "all")
--repo string [ --repo string ] Zero-or-more specific repositories that can be accessed, or "all" to allow access to all repositories, example: "owner1/repo1" (default: "all")
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user must-change-password
NAME:
stash admin user must-change-password - Set the must change password flag for the provided users or all users
USAGE:
stash admin user must-change-password [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--all, -A All users must change password, except those explicitly excluded with --exclude
--exclude string, -e string [ --exclude string, -e string ] Do not change the must-change-password flag for these users
--unset Instead of setting the must-change-password flag, unset it
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin user reset-mfa
NAME:
stash admin user reset-mfa - Remove all two-factor authentication configurations for a user
USAGE:
stash admin user reset-mfa [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--username string, -u string The user to update
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin repo-sync-releases
NAME:
stash admin repo-sync-releases - Synchronize repository releases with tags
USAGE:
stash admin repo-sync-releases [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin regenerate
NAME:
stash admin regenerate - Regenerate specific files
USAGE:
stash admin regenerate [command [command options]]
COMMANDS:
keys Regenerate authorized_keys file
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
admin auth
NAME:
stash admin auth - Modify external auth providers
USAGE:
stash admin auth [command [command options]]
COMMANDS:
add-oauth Add new Oauth authentication source
update-oauth Update existing Oauth authentication source
add-ldap Add new LDAP (via Bind DN) authentication source
update-ldap Update existing LDAP (via Bind DN) authentication source
add-ldap-simple Add new LDAP (simple auth) authentication source
update-ldap-simple Update existing LDAP (simple auth) authentication source
add-pam Add new PAM authentication source
update-pam Update existing PAM authentication source
add-smtp Add new SMTP authentication source
update-smtp Update existing SMTP authentication source
list List auth sources
delete Delete specific auth source
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
admin auth add-oauth
NAME:
stash admin auth add-oauth - Add new Oauth authentication source
USAGE:
stash admin auth add-oauth [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--provider string OAuth2 Provider
--key string Client ID (Key)
--secret string Client Secret
--auto-discover-url string OpenID Connect Auto Discovery URL (only required when using OpenID Connect as provider)
--use-custom-urls string Use custom URLs for GitLab/GitHub OAuth endpoints (default: "false")
--custom-tenant-id string Use custom Tenant ID for OAuth endpoints
--custom-auth-url string Use a custom Authorization URL (option for GitLab/GitHub)
--custom-token-url string Use a custom Token URL (option for GitLab/GitHub)
--custom-profile-url string Use a custom Profile URL (option for GitLab/GitHub)
--custom-email-url string Use a custom Email URL (option for GitHub)
--icon-url string Custom icon URL for OAuth2 login source
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--scopes string [ --scopes string ] Scopes to request when to authenticate against this OAuth2 source
--attribute-ssh-public-key string Claim name providing SSH public keys for this source
--required-claim-name string Claim name that has to be set to allow users to login with this source
--required-claim-value string Claim value that has to be set to allow users to login with this source
--group-claim-name string Claim name providing group names for this source
--admin-group string Group Claim value for administrator users
--restricted-group string Group Claim value for restricted users
--group-team-map string JSON mapping between groups and org teams
--group-team-map-removal Activate automatic team membership removal depending on groups
--dyn-group-maps string Dynamic mappings between groups and org teams
--dyn-group-maps-removal Activate automatic team membership removal of org teams not automatically added
--allow-username-change Allow users to change their username
--quota-group-claim-name string Claim name providing quota group names for this source
--quota-group-map string JSON mapping between groups and quota groups
--quota-group-map-removal Activate automatic quota group removal depending on groups
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth update-oauth
NAME:
stash admin auth update-oauth - Update existing Oauth authentication source
USAGE:
stash admin auth update-oauth [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--id int ID of authentication source (default: 0)
--provider string OAuth2 Provider
--key string Client ID (Key)
--secret string Client Secret
--auto-discover-url string OpenID Connect Auto Discovery URL (only required when using OpenID Connect as provider)
--use-custom-urls string Use custom URLs for GitLab/GitHub OAuth endpoints (default: "false")
--custom-tenant-id string Use custom Tenant ID for OAuth endpoints
--custom-auth-url string Use a custom Authorization URL (option for GitLab/GitHub)
--custom-token-url string Use a custom Token URL (option for GitLab/GitHub)
--custom-profile-url string Use a custom Profile URL (option for GitLab/GitHub)
--custom-email-url string Use a custom Email URL (option for GitHub)
--icon-url string Custom icon URL for OAuth2 login source
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--scopes string [ --scopes string ] Scopes to request when to authenticate against this OAuth2 source
--attribute-ssh-public-key string Claim name providing SSH public keys for this source
--required-claim-name string Claim name that has to be set to allow users to login with this source
--required-claim-value string Claim value that has to be set to allow users to login with this source
--group-claim-name string Claim name providing group names for this source
--admin-group string Group Claim value for administrator users
--restricted-group string Group Claim value for restricted users
--group-team-map string JSON mapping between groups and org teams
--group-team-map-removal Activate automatic team membership removal depending on groups
--dyn-group-maps string Dynamic mappings between groups and org teams
--dyn-group-maps-removal Activate automatic team membership removal of org teams not automatically added
--allow-username-change Allow users to change their username
--quota-group-claim-name string Claim name providing quota group names for this source
--quota-group-map string JSON mapping between groups and quota groups
--quota-group-map-removal Activate automatic quota group removal depending on groups
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth add-ldap
NAME:
stash admin auth add-ldap - Add new LDAP (via Bind DN) authentication source
USAGE:
stash admin auth add-ldap [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Authentication name.
--not-active Deactivate the authentication source.
--active Activate the authentication source.
--security-protocol string Security protocol name.
--skip-tls-verify Disable TLS verification.
--host string The address where the LDAP server can be reached.
--port int The port to use when connecting to the LDAP server. (default: 0)
--user-search-base string The LDAP base at which user accounts will be searched for.
--user-filter string An LDAP filter declaring how to find the user record that is attempting to authenticate.
--admin-filter string An LDAP filter specifying if a user should be given administrator privileges.
--restricted-filter string An LDAP filter specifying if a user should be given restricted status.
--allow-deactivate-all Allow empty search results to deactivate all users.
--username-attribute string The attribute of the user’s LDAP record containing the user name.
--firstname-attribute string The attribute of the user’s LDAP record containing the user’s first name.
--surname-attribute string The attribute of the user’s LDAP record containing the user’s surname.
--email-attribute string The attribute of the user’s LDAP record containing the user’s email address.
--public-ssh-key-attribute string The attribute of the user’s LDAP record containing the user’s public ssh key.
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--avatar-attribute string The attribute of the user’s LDAP record containing the user’s avatar.
--bind-dn string The DN to bind to the LDAP server with when searching for the user.
--bind-password string The password for the Bind DN, if any.
--attributes-in-bind Fetch attributes in bind DN context.
--synchronize-users Enable user synchronization.
--disable-synchronize-users Disable user synchronization.
--page-size uint Search page size. (default: 0)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth update-ldap
NAME:
stash admin auth update-ldap - Update existing LDAP (via Bind DN) authentication source
USAGE:
stash admin auth update-ldap [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--id int ID of authentication source (default: 0)
--name string Authentication name.
--not-active Deactivate the authentication source.
--active Activate the authentication source.
--security-protocol string Security protocol name.
--skip-tls-verify Disable TLS verification.
--host string The address where the LDAP server can be reached.
--port int The port to use when connecting to the LDAP server. (default: 0)
--user-search-base string The LDAP base at which user accounts will be searched for.
--user-filter string An LDAP filter declaring how to find the user record that is attempting to authenticate.
--admin-filter string An LDAP filter specifying if a user should be given administrator privileges.
--restricted-filter string An LDAP filter specifying if a user should be given restricted status.
--allow-deactivate-all Allow empty search results to deactivate all users.
--username-attribute string The attribute of the user’s LDAP record containing the user name.
--firstname-attribute string The attribute of the user’s LDAP record containing the user’s first name.
--surname-attribute string The attribute of the user’s LDAP record containing the user’s surname.
--email-attribute string The attribute of the user’s LDAP record containing the user’s email address.
--public-ssh-key-attribute string The attribute of the user’s LDAP record containing the user’s public ssh key.
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--avatar-attribute string The attribute of the user’s LDAP record containing the user’s avatar.
--bind-dn string The DN to bind to the LDAP server with when searching for the user.
--bind-password string The password for the Bind DN, if any.
--attributes-in-bind Fetch attributes in bind DN context.
--synchronize-users Enable user synchronization.
--disable-synchronize-users Disable user synchronization.
--page-size uint Search page size. (default: 0)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth add-ldap-simple
NAME:
stash admin auth add-ldap-simple - Add new LDAP (simple auth) authentication source
USAGE:
stash admin auth add-ldap-simple [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Authentication name.
--not-active Deactivate the authentication source.
--active Activate the authentication source.
--security-protocol string Security protocol name.
--skip-tls-verify Disable TLS verification.
--host string The address where the LDAP server can be reached.
--port int The port to use when connecting to the LDAP server. (default: 0)
--user-search-base string The LDAP base at which user accounts will be searched for.
--user-filter string An LDAP filter declaring how to find the user record that is attempting to authenticate.
--admin-filter string An LDAP filter specifying if a user should be given administrator privileges.
--restricted-filter string An LDAP filter specifying if a user should be given restricted status.
--allow-deactivate-all Allow empty search results to deactivate all users.
--username-attribute string The attribute of the user’s LDAP record containing the user name.
--firstname-attribute string The attribute of the user’s LDAP record containing the user’s first name.
--surname-attribute string The attribute of the user’s LDAP record containing the user’s surname.
--email-attribute string The attribute of the user’s LDAP record containing the user’s email address.
--public-ssh-key-attribute string The attribute of the user’s LDAP record containing the user’s public ssh key.
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--avatar-attribute string The attribute of the user’s LDAP record containing the user’s avatar.
--user-dn string The user's DN.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth update-ldap-simple
NAME:
stash admin auth update-ldap-simple - Update existing LDAP (simple auth) authentication source
USAGE:
stash admin auth update-ldap-simple [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--id int ID of authentication source (default: 0)
--name string Authentication name.
--not-active Deactivate the authentication source.
--active Activate the authentication source.
--security-protocol string Security protocol name.
--skip-tls-verify Disable TLS verification.
--host string The address where the LDAP server can be reached.
--port int The port to use when connecting to the LDAP server. (default: 0)
--user-search-base string The LDAP base at which user accounts will be searched for.
--user-filter string An LDAP filter declaring how to find the user record that is attempting to authenticate.
--admin-filter string An LDAP filter specifying if a user should be given administrator privileges.
--restricted-filter string An LDAP filter specifying if a user should be given restricted status.
--allow-deactivate-all Allow empty search results to deactivate all users.
--username-attribute string The attribute of the user’s LDAP record containing the user name.
--firstname-attribute string The attribute of the user’s LDAP record containing the user’s first name.
--surname-attribute string The attribute of the user’s LDAP record containing the user’s surname.
--email-attribute string The attribute of the user’s LDAP record containing the user’s email address.
--public-ssh-key-attribute string The attribute of the user’s LDAP record containing the user’s public ssh key.
--skip-local-2fa Set to true to skip local 2fa for users authenticated by this source
--avatar-attribute string The attribute of the user’s LDAP record containing the user’s avatar.
--user-dn string The user's DN.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth add-pam
NAME:
stash admin auth add-pam - Add new PAM authentication source
USAGE:
stash admin auth add-pam [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--service-name string PAM service name (default: "PLAIN")
--email-domain string PAM email domain
--skip-local-2fa Skip 2FA to log on.
--active This Authentication Source is Activated.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth update-pam
NAME:
stash admin auth update-pam - Update existing PAM authentication source
USAGE:
stash admin auth update-pam [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--id int ID of authentication source (default: 0)
--service-name string PAM service name (default: "PLAIN")
--email-domain string PAM email domain
--skip-local-2fa Skip 2FA to log on.
--active This Authentication Source is Activated.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth add-smtp
NAME:
stash admin auth add-smtp - Add new SMTP authentication source
USAGE:
stash admin auth add-smtp [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--auth-type string SMTP Authentication Type (PLAIN/LOGIN/CRAM-MD5) default PLAIN (default: "PLAIN")
--host string SMTP Host
--port int SMTP Port (default: 0)
--force-smtps SMTPS is always used on port 465. Set this to force SMTPS on other ports.
--skip-verify Skip TLS verify.
--helo-hostname string Hostname sent with HELO. Leave blank to send current hostname
--disable-helo Disable SMTP helo.
--allowed-domains string Leave empty to allow all domains. Separate multiple domains with a comma (',')
--skip-local-2fa Skip 2FA to log on.
--active This Authentication Source is Activated.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth update-smtp
NAME:
stash admin auth update-smtp - Update existing SMTP authentication source
USAGE:
stash admin auth update-smtp [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--name string Application Name
--id int ID of authentication source (default: 0)
--auth-type string SMTP Authentication Type (PLAIN/LOGIN/CRAM-MD5) default PLAIN (default: "PLAIN")
--host string SMTP Host
--port int SMTP Port (default: 0)
--force-smtps SMTPS is always used on port 465. Set this to force SMTPS on other ports.
--skip-verify Skip TLS verify.
--helo-hostname string Hostname sent with HELO. Leave blank to send current hostname
--disable-helo Disable SMTP helo.
--allowed-domains string Leave empty to allow all domains. Separate multiple domains with a comma (',')
--skip-local-2fa Skip 2FA to log on.
--active This Authentication Source is Activated.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth list
NAME:
stash admin auth list - List auth sources
USAGE:
stash admin auth list [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--min-width int Minimal cell width including any padding for the formatted table (default: 0)
--tab-width int width of tab characters in formatted table (equivalent number of spaces) (default: 8)
--padding int padding added to a cell before computing its width (default: 1)
--pad-char string ASCII char used for padding if padchar == '\\t', the Writer will assume that the width of a '\\t' in the formatted output is tabwidth, and cells are left-aligned independent of align_left (for correct-looking results, tabwidth must correspond to the tab width in the viewer displaying the result) (default: "\t")
--vertical-bars Set to true to print vertical bars between columns
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin auth delete
NAME:
stash admin auth delete - Delete specific auth source
USAGE:
stash admin auth delete [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--id int ID of authentication source (default: 0)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
admin sendmail
NAME:
stash admin sendmail - Send a message to all users
USAGE:
stash admin sendmail [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--title string a title of a message
--content string a content of a message
--force, -f A flag to bypass a confirmation step
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
migrate
NAME:
stash migrate - Migrate the database
USAGE:
stash migrate [options]
DESCRIPTION:
This is a command for migrating the database, so that you can run 'stash admin user create' before starting the server.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
keys
NAME:
stash keys - (internal) Should only be called by SSH server
USAGE:
stash keys [options]
DESCRIPTION:
Queries the Stash database to get the authorized command for a given ssh key fingerprint
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--expected string, -e string Expected user for whom provide key commands (default: "git")
--username string, -u string Username trying to log in by SSH
--type string, -t string Type of the SSH key provided to the SSH Server
--content string, -k string Base64 encoded content of the SSH key provided to the SSH Server
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
doctor
NAME:
stash doctor - Diagnose and optionally fix problems, convert or re-create database tables
USAGE:
stash doctor [command [command options]]
DESCRIPTION:
A command to diagnose problems with the current Stash instance according to the given configuration. Some problems can optionally be fixed by modifying the database or data storage.
COMMANDS:
check Diagnose and optionally fix problems
recreate-table Recreate tables from XORM definitions and copy the data.
convert Convert the database
avatar-strip-exif Strip EXIF metadata from all images in the avatar storage [unsupported]
cleanup-commit-status Cleanup extra records in commit_status table
avatar-resize Generate resized versions of user or repository avatars
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
doctor check
NAME:
stash doctor check - Diagnose and optionally fix problems
USAGE:
stash doctor check [options]
DESCRIPTION:
A command to diagnose problems with the current Stash instance according to the given configuration. Some problems can optionally be fixed by modifying the database or data storage.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--list List the available checks
--default Run the default checks (if neither --run or --all is set, this is the default behaviour)
--run string [ --run string ] Run the provided checks - (if --default is set, the default checks will also run)
--all Run all the available checks
--fix Automatically fix what we can
--log-file string Name of the log file (no verbose log output by default). Set to "-" to output to stdout
--color, -H Use color for outputted information
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
doctor recreate-table
NAME:
stash doctor recreate-table - Recreate tables from XORM definitions and copy the data.
USAGE:
stash doctor recreate-table [options] [TABLE]... : (TABLEs to recreate - leave blank for all)
DESCRIPTION:
The database definitions Stash uses change across versions, sometimes changing default values and leaving old unused columns.
This command will cause Xorm to recreate tables, copying over the data and deleting the old table.
You should back-up your database before doing this and ensure that your database is up-to-date first.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug Print SQL commands sent
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
doctor convert
NAME:
stash doctor convert - Convert the database
USAGE:
stash doctor convert [options]
DESCRIPTION:
A command to convert an existing MySQL database from utf8 to utf8mb4
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
doctor avatar-strip-exif
NAME:
stash doctor avatar-strip-exif - Strip EXIF metadata from all images in the avatar storage [unsupported]
USAGE:
stash doctor avatar-strip-exif [options]
DESCRIPTION:
Stripping EXIF metadata is not currently supported. The capability was
available in previous Stash releases, but has been removed. This command
may be re-enabled in the future if the capability can be supported again.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
doctor cleanup-commit-status
NAME:
stash doctor cleanup-commit-status - Cleanup extra records in commit_status table
USAGE:
stash doctor cleanup-commit-status [options]
DESCRIPTION:
Stash suffered from a bug which caused the creation of more entries in the
"commit_status" table than necessary. This operation removes the redundant
data caused by the bug. Removing this data is almost always safe.
These redundant records can be accessed by users through the API, making it
possible, but unlikely, that removing it could have an impact to
integrating services (API: /repos/{owner}/{repo}/commits/{ref}/statuses).
It is safe to run while Stash is online.
On very large Stash instances, the performance of operation will improve
if the buffer-size option is used with large values. Approximately 130 MB of
memory is required for every 100,000 records in the buffer.
Bug reference: https://gitstash.co/jcg/stash/issues/10671
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--verbose, -V Show process details
--dry-run Report statistics from the operation but do not modify the database
--buffer-size int Record count per query while iterating records; larger values are typically faster but use more memory (default: 100000)
--delete-chunk-size int Number of records to delete per DELETE query (default: 1000)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager
NAME:
stash manager - Manage the running stash process
USAGE:
stash manager [command [command options]]
DESCRIPTION:
This is a command for managing the running stash process
COMMANDS:
shutdown Gracefully shutdown the running process
restart Gracefully restart the running process - (not implemented for windows servers)
reload-templates Reload template files in the running process
flush-queues Flush queues in the running process
logging Adjust logging commands
processes Display running processes within the current process
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
manager shutdown
NAME:
stash manager shutdown - Gracefully shutdown the running process
USAGE:
stash manager shutdown [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager restart
NAME:
stash manager restart - Gracefully restart the running process - (not implemented for windows servers)
USAGE:
stash manager restart [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager reload-templates
NAME:
stash manager reload-templates - Reload template files in the running process
USAGE:
stash manager reload-templates [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager flush-queues
NAME:
stash manager flush-queues - Flush queues in the running process
USAGE:
stash manager flush-queues [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--timeout duration Timeout for the flushing process (default: 1m0s)
--non-blocking Set to true to not wait for flush to complete before returning
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging
NAME:
stash manager logging - Adjust logging commands
USAGE:
stash manager logging [command [command options]]
COMMANDS:
pause Pause logging (Stash will buffer logs up to a certain point and will drop them after that point)
resume Resume logging
release-and-reopen Cause Stash to release and re-open files used for logging
remove Remove a logger
add Add a logger
log-sql Set LogSQL
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
manager logging pause
NAME:
stash manager logging pause - Pause logging (Stash will buffer logs up to a certain point and will drop them after that point)
USAGE:
stash manager logging pause [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging resume
NAME:
stash manager logging resume - Resume logging
USAGE:
stash manager logging resume [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging release-and-reopen
NAME:
stash manager logging release-and-reopen - Cause Stash to release and re-open files used for logging
USAGE:
stash manager logging release-and-reopen [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging remove
NAME:
stash manager logging remove - Remove a logger
USAGE:
stash manager logging remove [options] [name] Name of logger to remove
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--logger string Logger name - will default to "default"
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging add
NAME:
stash manager logging add - Add a logger
USAGE:
stash manager logging add [command [command options]]
COMMANDS:
file Add a file logger
conn Add a net conn logger
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
manager logging add file
NAME:
stash manager logging add file - Add a file logger
USAGE:
stash manager logging add file [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--logger string Logger name - will default to "default"
--writer string Name of the log writer - will default to mode
--level string Logging level for the new logger
--stacktrace-level string, -L string Stacktrace logging level
--flags string, -F string Flags for the logger
--expression string, -e string Matching expression for the logger
--exclusion string, -x string Exclusion for the logger
--prefix string, -p string Prefix for the logger
--color Use color in the logs
--debug
--filename string, -f string Filename for the logger - this must be set.
--rotate, -r Rotate logs
--max-size int, -s int Maximum size in bytes before rotation (default: 0)
--daily, -d Rotate logs daily
--max-days int, -D int Maximum number of daily logs to keep (default: 0)
--compress, -z Compress rotated logs
--compression-level int, -Z int Compression level to use (default: 0)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging add conn
NAME:
stash manager logging add conn - Add a net conn logger
USAGE:
stash manager logging add conn [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--logger string Logger name - will default to "default"
--writer string Name of the log writer - will default to mode
--level string Logging level for the new logger
--stacktrace-level string, -L string Stacktrace logging level
--flags string, -F string Flags for the logger
--expression string, -e string Matching expression for the logger
--exclusion string, -x string Exclusion for the logger
--prefix string, -p string Prefix for the logger
--color Use color in the logs
--debug
--reconnect-on-message, -R Reconnect to host for every message
--reconnect, -r Reconnect to host when connection is dropped
--protocol string, -P string Set protocol to use: tcp, unix, or udp (defaults to tcp)
--address string, -a string Host address and port to connect to (defaults to :7020)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager logging log-sql
NAME:
stash manager logging log-sql - Set LogSQL
USAGE:
stash manager logging log-sql [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--off Switch off SQL logging
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
manager processes
NAME:
stash manager processes - Display running processes within the current process
USAGE:
stash manager processes [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--debug
--flat Show processes as flat table rather than as tree
--no-system Do not show system processes
--stacktraces Show stacktraces
--json Output as json
--cancel string Process PID to cancel. (Only available for non-system processes.)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
embedded
NAME:
stash embedded - Extract embedded resources
USAGE:
stash embedded [command [command options]]
DESCRIPTION:
A command for extracting embedded resources, like templates and images
COMMANDS:
list List files matching the given pattern
view View a file matching the given pattern
extract Extract resources
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--help, -h show help
embedded list
NAME:
stash embedded list - List files matching the given pattern
USAGE:
stash embedded list [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--include-vendored, --vendor Include files under public/vendor as well
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
embedded view
NAME:
stash embedded view - View a file matching the given pattern
USAGE:
stash embedded view [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--include-vendored, --vendor Include files under public/vendor as well
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
embedded extract
NAME:
stash embedded extract - Extract resources
USAGE:
stash embedded extract [options]
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--include-vendored, --vendor Include files under public/vendor as well
--overwrite Overwrite files if they already exist
--rename Rename files as {name}.bak if they already exist (overwrites previous .bak)
--custom Extract to the 'custom' directory as per app.ini
--destination string, --dest-dir string Extract to the specified directory
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
migrate-storage
NAME:
stash migrate-storage - Migrate the storage
USAGE:
stash migrate-storage [options]
DESCRIPTION:
Copies stored files from storage configured in app.ini to parameter-configured storage
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--type string, -t string Type of stored files to copy. Allowed types: 'attachments', 'lfs', 'avatars', 'repo-avatars', 'repo-archivers', 'packages', 'actions-log', 'actions-artifacts'
--storage string, -s string New storage type: local (default) or minio
--path string, -p string New storage placement if store is local (leave blank for default)
--minio-endpoint string Minio storage endpoint
--minio-access-key-id string Minio storage accessKeyID
--minio-secret-access-key string Minio storage secretAccessKey
--minio-bucket string Minio storage bucket
--minio-location string Minio storage location to create bucket
--minio-base-path string Minio storage base path on the bucket
--minio-use-ssl Enable SSL for minio
--minio-insecure-skip-verify Skip SSL verification
--minio-checksum-algorithm string Minio checksum algorithm (default/md5)
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
dump-repo
NAME:
stash dump-repo - Dump the repository from git/github/gitea/gitlab
USAGE:
stash dump-repo [options]
DESCRIPTION:
This is a command for dumping the repository data.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--git_service string Git service, git, github, gitea, gitlab. If clone_addr could be recognized, this could be ignored.
--repo_dir string, -r string Repository dir path to store the data (default: "./data")
--clone_addr string The URL will be clone, currently could be a git/github/gitea/gitlab http/https URL
--auth_username string The username to visit the clone_addr
--auth_password string The password to visit the clone_addr
--auth_token string The personal token to visit the clone_addr
--owner_name string The data will be stored on a directory with owner name if not empty
--repo_name string The data will be stored on a directory with repository name if not empty
--units string Which items will be migrated, one or more units should be separated as comma.
wiki, issues, labels, releases, release_assets, milestones, pull_requests, comments are allowed. Empty means all units.
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
restore-repo
NAME:
stash restore-repo - Restore the repository from disk
USAGE:
stash restore-repo [options]
DESCRIPTION:
This is a command for restoring the repository data.
OPTIONS:
--help, -h show help
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
--repo_dir string, -r string Repository dir path to restore from (default: "./data")
--owner_name string Restore destination owner name
--repo_name string Restore destination repository name
--units string Which items will be restored, one or more units should be separated as comma.
wiki, issues, labels, releases, release_assets, milestones, pull_requests, comments are allowed. Empty means all units.
--validation Sanity check the content of the files before trying to load them
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
cert
NAME:
stash cert - Generate self-signed certificate
USAGE:
stash cert [options]
DESCRIPTION:
Generate a self-signed X.509 certificate for a TLS server.
Outputs to 'cert.pem' and 'key.pem' and will overwrite existing files.
OPTIONS:
--host string Comma-separated hostnames and IPs to generate a certificate for
--ecdsa-curve string ECDSA curve to use to generate a key. Valid values are P224, P256, P384, P521
--rsa-bits int Size of RSA key to generate. Ignored if --ecdsa-curve is set (default: 3072)
--start-date string Creation date formatted as Jan 1 15:04:05 2011
--duration duration Duration that certificate is valid for (default: 8760h0m0s)
--ca whether this cert should be its own Certificate Authority
--help, -h show help
GLOBAL OPTIONS:
--custom-path string, -C string Set custom path (defaults to '{WorkPath}/custom')
--config string, -c string Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')
--work-path string, -w string Set Stash's working path (defaults to the directory of the Stash binary)
generate secret
NAME:
stash generate secret - Generate a secret token
USAGE:
stash generate secret [command [command options]]
COMMANDS:
INTERNAL_TOKEN Generate a new INTERNAL_TOKEN
JWT_SECRET, LFS_JWT_SECRET Generate a new JWT_SECRET
SECRET_KEY Generate a new SECRET_KEY
OPTIONS:
--help, -h show help