Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connection string not being recognized #26

Open
stunney opened this issue Mar 18, 2022 · 2 comments
Open

connection string not being recognized #26

stunney opened this issue Mar 18, 2022 · 2 comments

Comments

@stunney
Copy link

stunney commented Mar 18, 2022

I have a secret in the following format as per all of the documentation

psql "host='mypostgresservername1.postgres.database.azure.com' port=5432 dbname='postgres' user='myuser@mypostgresservername1' password='&&&&&&&&&' sslmode=require"

My password contains and starts with special (non alpha-numeric) characters and might also end the same way.

I have verified through connecting via the command line and DBeaver that all values are correct.

I get the following ambiguous and frustrating error:

Error: Error occurred while running action:
Error: Please provide a valid connection string. A valid connection string is a series of keyword/value pairs separated by space. Spaces around the equal sign are optional. To write an empty value, or a value containing spaces, surround it with single quotes, e.g., keyword = 'a value'. Single quotes and backslashes within the value must be escaped with a backslash

No whitespace in any of my values, nor backslashes.

Please help. This is terrible.

@pk-ot
Copy link

pk-ot commented Jan 27, 2024

For me it started working once I used user='myuser' (without the server name).

@yuseow
Copy link

yuseow commented Feb 14, 2024

the way the documentation listed to store the whole connection string like so:
connection-string: ${{ secrets.AZURE_POSTGRESQL_CONNECTION_STRING }}

DOES NOT WORK AT ALL. this is how you need to put your connection string in the yaml file for it to work :/ separate the components and string it together like this:

connection-string: "psql host=${{secrets.AZURE_POSTGRES_SERVER_NAME}} port=5342 dbname=${{secrets.AZURE_POSTGRES_DB_NAME}} user=${{secrets.AZURE_POSTGRES_USERNAME}} password=${{secrets.AZURE_POSTGRES_PASSWORD}} sslmode=require"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants