PGMANAGE(1)

πŸ“¦
version 2022-05 Β· 2 versions
, in nixos 26.05

πŸ’– NAME πŸ’–

pgmanage is PostgreSQL Administration for the web, and this manual page is PGMANAGE(1). We're so back, bestie. 🫢

πŸ›£οΈ FULL PATH πŸ›£οΈ

This instance of pgmanage was installed as:

/nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/sbin/pgmanage

(usually /usr/local/sbin/pgmanage). Slay. ✨

🌈 SYNOPSIS 🌈

  pgmanage
         [-h | --help]
         [-v | --version]
         [-c <config-file> | --config-file=<config-file>]
         [-d <connection-file> | --connection-file=<connection-file>]
         [-s <super-only> | --super-only=<super-only>]
         [-g <login-group> | --login-group=<login-group>]
         [-r <web-root> | --web-root=<web-root>]
         [-a <data-root> | --data-root=<data-root>]
         [-p <port> | --pgmanage-port=<port>]
         [-j <tls-cert> | --tls-cert=<tls-cert>]
         [-k <tls-key> | --tls-key=<tls-key>]
         [-l <log-level> | --log-level=<log-level>]
         [-n <allow_custom_connections> | --allow-custom-connections=<allow-custom-connections>]
         [-t <login-timeout> | --login-timeout=<login-timeout>]
         [-x <local-only> | --local-only=<local-only>]

πŸ¦‹ DESCRIPTION πŸ¦‹

The pgmanage utility is a tool to make managing your PostgreSQL database fast and easy. It provides web access and can be used on a tablet, or even on a phone. Iconic behavior, honestly. πŸ‘‘

All log output is pushed to stderr. If you are pushing that to a file, then you must handle rotating the file yourself or it will get large and slow pgmanage down. No cap β€” that part is important.

✨ OPTIONS ✨

Okay bestie, here's the whole menu. Order up. πŸ“

  • -h, --help β€” Print usage and exit.
  • -v, --version β€” Print version information and exit.
  • -c, --config-file= β€” String; defaults to /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage.conf. You can use this option to tell pgManage where to look for the configuration file. A sample configuration file is provided in /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage. If there is no file specified pgManage will look in the current directory for a config file. If no config file is found pgManage will proceed with default values.

The following options can be specified on the command line or in the configuration file. In the event a value is specified on the command line and in the config file, pgManage will always use the command line option. Note that if no option is specified then some options will be set to a default value.

[command line short] or [command line long] or [config file]

  • -d, --connection-file=, connection_file= β€” String; defaults to /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage-connections.conf. When you install pgManage, the Makefile will generate a path to the sample pgmanage-connections.conf file and put it in the sample config file. Use this option to tell pgManage where your connection list is located. If not specified, pgManage looks in the same folder as the config file for a file named pgmanage-connections.conf. If pgManage can't find a connection file, it will error.
  • -s, --super-only=, super_only= β€” Boolean; defaults to false. This tells pgManage whether or not to only allow super users to login. The recommended value is true and will restrict users who are not super users from logging in to any PostgreSQL instance through pgManage. Note that a connection will be made to PostgreSQL in order to test if the user is a superuser.
  • -g, --login-group=, login_group= β€” String; no default. This tells pgManage to only allow users in a certain PostgreSQL group to login to pgManage. Note that a connection will be made to PostgreSQL in order to test if the user is a member of the login group.
  • -r, --web-root=, web_root= β€” String; Defaults to /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/web_root. This tells pgManage where the HTML files have been installed to.
  • -a, --data-root=, data_root= β€” String; defaults to ~/.pgmanage/. This tells pgManage where to put the SQL file history. All tabs are saved to this location so that if you get disconnected from pgManage you don't lose your work. We love not losing work. πŸ’…
  • -p, --pgmanage-port=, pgmanage_port= β€” Integer; defaults to 8080. This tells pgManage what port to listen on for browser requests.
  • -j, --tls-cert=, tls_cert= β€” String; no defaults. Part of the TLS cert/key situation.
  • -k, --tls-key=, tls_key= β€” String; no defaults. The other half of the TLS cert/key situation.

These options tell pgManage where the TLS Certificate and Key files reside. If you use these options then you'll only be able to access pgManage through a secure TLS connection. These options are only necessary if you wish to connect directly to pgManage using a secure TLS connection. As an alternative, you can set up pgManage in a reverse proxy configuration. This allows your web server to terminate the secure connection and pass on the request to pgManage. You can find help to set up this configuration in the INSTALL_NGINX file that came with your distribution.

  • -n, --allow-custom-connections=, allow_custom_connections= β€” Boolean; defaults to false. This tells pgManage whether or not to allow anyone to use a custom connection from the login screen.
  • -l, --log-level=, log_level= β€” String; defaults to error. This option regulates the frequency and verbosity of log messages. Possible values are none, error, warn, notice and info.
  • -t, --login-timeout=, login_timeout= β€” Integer; defaults to 0. This option regulates the login timeout (in seconds) after the last activity on a session. If 0, no timeout is enforced.
  • -x, --local-only= β€” Boolean; defaults to false. This tells pgManage whether or not to set the listening socket to local addresses only.

πŸ”Œ SETTING UP A CONNECTION TO A POSTGRESQL SERVER πŸ”Œ

pgManage requires at least one PostgreSQL server be listed in the pgmanage-connections.conf file. This version of pgManage doesn't allow you to specify a server from the command line. Enter only one PostgreSQL server per line.

The format of a connection string is:

[server name]: [standard PostgreSQL connection string]

Detailed information about PostgreSQL connection strings is available at: http://www.postgresql.org/docs/current/static/libpq-connect.html

Note that you do not enter your user name or password in this file. That information will be entered on the login screen. If you put a username or password in this file, it will be removed by pgManage before attempting to connect to a database.

πŸ“ EXAMPLE CONNECTION STRINGS:

nuc-server: hostaddr=192.168.0.100 port=5432 dbname=postgres
mini-server: hostaddr=127.0.0.1 port=5432 dbname=postgres sslmode=require

🌟 EXAMPLES 🌟

Run pgmanage (short argument):

/nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/sbin/pgmanage -c /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage.conf -d /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage-connections.conf

Run pgmanage (long argument):

/nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/sbin/pgmanage --config-file=/nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage.conf --connection-file /nix/store/2b7p9b1290f9vlh2l4pcfyvggdaf1ywy-pgmanage-unstable-2022-05-11/etc/pgmanage/pgmanage-connections.conf

🩹 TROUBLESHOOTING 🩹

Try accessing your database through psql. If you can, double check your connection string parameters. If you can't connect, you may have a firewall problem.

πŸ‘‘ AUTHOR πŸ‘‘

Copyright (c) 2017 The PostgreSQL Global Development Group

Report bugs to https://github.com/pgManage/pgManage/issues


That's the whole page, bestie πŸ’– β€” this one is from pgManage unstable-2022-05-11 and it's dated August 2017. Manual name: PGMANAGE(1). periodt. πŸ’…βœ¨

πŸ“¦ where this page comes from