diff --git a/docs/reference/production-systems.md b/docs/reference/production-systems.md index 881cff981..b590a4e89 100644 --- a/docs/reference/production-systems.md +++ b/docs/reference/production-systems.md @@ -4,7 +4,7 @@ This page is mostly intended for DWWW-members, since they have access to the fol ## Deploy pipeline -The website is deployed with a pipeline that goes through Jenkins, this is because root does not want an ssh key to the production server on github. +The website is deployed with a pipeline that goes through Jenkins, this is because we do not want an ssh key to the production server on github. Jenkins can be accessed on [jenkins.dsek.se](https://jenkins.dsek.se), those with access can log in using the same credentials as on [dsek.se](https://dsek.se). When logged in select the view `Dsek Web` and the pipeline `Deploy_web` is the one deploying the website. ### How it works @@ -31,7 +31,21 @@ Host *.blossom IdentityFile /path/to/identityfile ``` -and use `ssh web-beta.blossom` +and use `ssh web-beta.blossom`. It is recommended to use an ssh-key by specifying an IdentityFile (created with for example `ssh-keygen`) and adding your public key to your profile in [ipa.dsek.se](https://ipa.dsek.se). + +### Debugging production database + +An easy way to debug something in the production database is to use an ssh-tunnel which allows you to view the database with any database tool you want. Make sure to **never** run `pnpm seed` or similar destructive commands when having a tunnel open. You can open the tunnel with the following command: + +```bash +ssh -N stil-id@web-beta -J stil-id@hyacinth.blossom.dsek.se -L 5432:localhost:5432 +``` + +or, if you have the config above: + +```bash +ssh -N web-beta.blossom -L 5432:localhost:5432 +``` ### Logs