Jump to content

Navigation menu

Note: Currently new registrations are closed, if you want an account Contact us

Difference between revisions of "GitLab"

143 bytes added ,  09:13, 24 November 2022
(→‎Backup: update for postgresql 11)
 
(4 intermediate revisions by 2 users not shown)
Line 3: Line 3:
==Hosting==
==Hosting==


Sponsored by [http://about.gitlab.com GitLab Inc]. Hosted at gandi.net in France.
Sponsored by [https://www.infomaniak.com/en/about Infomaniak]. Hosted in Switzerland with infomaniak.com.
 
Previously sponsored by [http://about.gitlab.com GitLab Inc] (2016-2022)


==Setup==
==Setup==
Line 15: Line 17:
Letsencrypt domains:
Letsencrypt domains:


   letsencrypt --expand --webroot --webroot-path /usr/share/gitlab/public -d git.fosscommunity.in -d gitlabce.tk -d gitlab.debian.net -d wiki.fsci.org.in -d git.fsci.org.in  certonly
   letsencrypt --expand --webroot --webroot-path /usr/share/gitlab/public -d git.fosscommunity.in -d gitlab.debian.net -d wiki.fsci.org.in -d git.fsci.org.in  certonly


== Mail Server Setup ==
== Mail Server Setup ==
Line 29: Line 31:
==Maintenance==
==Maintenance==


Maintenance discussion at [https://www.loomio.org/g/Qu3O8mSf/fosscommunity-in-git-fosscommunity-in-maintainers this loomio subgroup] and [https://matrix.to/#/#git.fosscommunity.in:matrix.org this matrix chat room]
Maintenance discussion at [https://www.loomio.org/g/Qu3O8mSf/fosscommunity-in-git-fosscommunity-in-maintainers this loomio subgroup] and [https://matrix.to/#/#git.fosscommunity.in:matrix.org this matrix chat room]. Can also use the [https://git.fosscommunity.in/community/management/-/issues git tracker] for development issues.


* [https://git.fosscommunity.in/community/gitlab/ team repo with access details] (private)
* [https://git.fosscommunity.in/community/gitlab/ team repo with access details] (private)
If expecting service disruptions, downtime, or user-facing errors, consider adding an update to [[Status]]


==Gitlab QA - running tests==
==Gitlab QA - running tests==
Line 47: Line 51:
Backup server is provided by Manu (KVM virtual machine with 100 GB storage and 1 GB ram). Running on debian gnu/linux 10 buster.  
Backup server is provided by Manu (KVM virtual machine with 100 GB storage and 1 GB ram). Running on debian gnu/linux 10 buster.  


Documentation: https://linuxhint.com/setup_postgresql_replication/
Documentation: https://linuxhint.com/setup_postgresql_replication/ and https://www.percona.com/blog/2018/09/07/setting-up-streaming-replication-postgresql/


===Slave configuration: Step 1===
===Slave configuration: Step 1===
Line 134: Line 138:


  # systemctl restart postgresql
  # systemctl restart postgresql
Start the backup process,
psql -c "select pg_start_backup('initial_backup');"
rsync -cva -e 'ssh -p 12022' --inplace --exclude=*pg_xlog* /var/lib/postgresql/11/main/ 62.210.83.200:/var/lib/postgresql/11/main/
psql -c "select pg_stop_backup();"


Open 5432 port in the firewall
Open 5432 port in the firewall
Line 146: Line 144:


===Slave Configuration: Step 2===
===Slave Configuration: Step 2===
Create a recovery file called  recovery.conf and add following lines.
 
  standby_mode = 'on'
Copy data from master and create recovery.conf
primary_conninfo = 'host=213.167.243.152 port=5432 user=rep password=yourpassword'
  $ pg_basebackup -h git.fosscommunity.in -D /var/lib/postgresql/11/main/ -P -U rep --wal-method=fetch -R
  trigger_file = '/tmp/postgresql.trigger.5432'


Start the slave server
Start the slave server
Line 160: Line 157:


  $ ps -ef | grep sender
  $ ps -ef | grep sender
$ psql -c "select * from pg_stat_activity where usename='rep';"
On slave server,
On slave server,


2

edits