I want to pass values of environment variables to Maven via the command line. How to do?
Attempts:
-
mvn liquibase:update -Dliquibase.url=$DB_URL
: Maven runs, but the value is not passed -
mvn liquibase:update -Dliquibase.url=${DB_URL}
: Maven runs, but the value is not passed -
mvn liquibase:update -Dliquibase.url=${env.DB_URL}
: bash error:
-bash: -Dliquibase.url = $ {env.DB_URL}: bad substitution