1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

feat(PostgreSQL): Postgress connection string feature for local and server connection string

This feature is based on this [issue](https://github.com/Fabio286/antares/issues/193)  I tested with the following posgress connection strings postgresql://postgres:pgpassword@127.0.0.1:5432/my_local_databse?connection=local postgres://serveruser:serverpass@test.db.elephantsql.com/my_remote_databse?connection=server  postgres://serveruser:serverpass@test.db.elephantsql.com:5432/my_remote_databse postgresql://postgres:pgpassword@127.0.0.1:5432/my_local_databse.

The connection string decoder is loaded before "test-connection", "check-connection", and "connect"
This commit is contained in:
Topollo
2022-03-06 02:20:10 +02:00
committed by Fabio Di Stasio
parent 763be8532d
commit 6305752ad1
8 changed files with 162 additions and 16 deletions

View File

@ -45,6 +45,19 @@
>
</div>
</div>
<div v-if="connection.client === 'pg'" class="form-group columns">
<div class="column col-4 col-sm-12">
<label class="form-label">{{ $t('word.connectionString') }}</label>
</div>
<div class="column col-8 col-sm-12">
<input
ref="pgString"
v-model="connection.pgConnString"
class="form-input"
type="text"
>
</div>
</div>
<div class="form-group columns">
<div class="column col-4 col-sm-12">
<label class="form-label">{{ $t('word.client') }}</label>
@ -412,7 +425,8 @@ export default {
sshUser: '',
sshPass: '',
sshKey: '',
sshPort: 22
sshPort: 22,
pgConnString: ''
},
isConnecting: false,
isTesting: false,