Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
354c2693
Commit
354c2693
authored
Feb 18, 2020
by
Craig Gomes
Committed by
Marcel Amirault
Feb 18, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding directions on how to connect to gdk db with vscode
parent
654d4496
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
0 deletions
+24
-0
doc/development/database_debugging.md
doc/development/database_debugging.md
+24
-0
No files found.
doc/development/database_debugging.md
View file @
354c2693
...
@@ -52,6 +52,30 @@ bundle exec rails db RAILS_ENV=development
...
@@ -52,6 +52,30 @@ bundle exec rails db RAILS_ENV=development
-
`SELECT * FROM schema_migrations WHERE version = '20170926203418';`
: Check if a migration was run
-
`SELECT * FROM schema_migrations WHERE version = '20170926203418';`
: Check if a migration was run
-
`DELETE FROM schema_migrations WHERE version = '20170926203418';`
: Manually remove a migration
-
`DELETE FROM schema_migrations WHERE version = '20170926203418';`
: Manually remove a migration
## Access the GDK database with Visual Studio Code
Use these instructions for exploring the GitLab database while developing with the GDK:
1.
Install or open
[
Visual Studio Code
](
https://code.visualstudio.com/download
)
.
1.
Install the
[
PostgreSQL VSCode Extension
](
https://marketplace.visualstudio.com/items?itemName=ckolkman.vscode-postgres
)
by Chris Kolkman.
1.
In Visual Studio Code click on the PostgreSQL Explorer button in the left toolbar.
1.
In the top bar of the new window, click on the
`+`
to
**Add Database Connection**
, and follow the prompts to fill in the details:
1.
**Hostname**
: the path to the PostgreSQL folder in your GDK directory (for example
`/dev/gitlab-development-kit/postgresql`
).
1.
**PostgreSQL user to authenticate as**
: usually your local username, unless otherwise specified during PostgreSQL installation.
1.
**Password of the PostgreSQL user**
: the password you set when installing PostgreSQL.
1.
**Port number to connect to**
:
`5432`
(default).
1.
**Use an ssl connection?**
This depends on your installation. Options are:
-
**Use Secure Connection**
-
**Standard Connection**
(default)
1.
**(Optional) The database to connect to**
:
`gitlabhq_development`
.
1.
**The display name for the database connection**
:
`gitlabhq_development`
.
Your database connection should now be displayed in the PostgreSQL Explorer pane and
you can explore the
`gitlabhq_development`
database. If you cannot connect, ensure
that GDK is running. For further instructions on how to use the PostgreSQL Explorer
Extension for Visual Studio Code, read the
[
usage section
](
https://marketplace.visualstudio.com/items?itemName=ckolkman.vscode-postgres#usage
)
of the extension documentation.
## FAQ
## FAQ
### `ActiveRecord::PendingMigrationError` with Spring
### `ActiveRecord::PendingMigrationError` with Spring
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment