linuxbashairflow

Understand the value of the enviroment variabe?


this line is assigned to an enviroment variable:

postgresql+psycopg2://airflow:airflow@postgres/airflow

And I do not really understand what it's mean.


Solution

  • My guess is that that is an SQLAlchemy database URL; see https://docs.sqlalchemy.org/en/20/core/engines.html

    According to the above page generic syntax is:

    dialect+driver://username:password@host:port/database
    

    So for "postgresql+psycopg2://airflow:airflow@postgres/airflow"

    (The hostname "postgres" is not qualified, so it would presumably be resolved in your "local" DNS resolver.)


    I searched it up in the bash documentation, but still cannot understand it correctly. What is the meaning of plus (+) in this case?

    You were looking in the wrong place. The correct place to look would be the documentation for the product that you are attempting to install / configure.

    A + in an environment variable's value has no special significance to bash.