Joan (discussió | contribucions)
Cap resum de modificació
Marcb (discussió | contribucions)
Cap resum de modificació
 
(4 revisions intermèdies per 2 usuaris que no es mostren)
Línia 2: Línia 2:
[[Category:Devel]]
[[Category:Devel]]
[[Category:tinki]]
[[Category:tinki]]
= tinki-team =


To install and run the stack, execute <code>docker-compose up -d</code> from the project folder. In a similar fashion, use <code>docker-compose down</code> to halt the services. To backup the whole stack use the <code>backup-all.sh</code> script.
[[Fitxer:devel-setup.png]]


<pre>ssh user@fedora-atomic.cadt.com -p 2222
= tinki-team-build =
cd /home/tinki-team
docker-compose up -d
bash ./backup-all.sh</pre>
Inside the container server, the stack should be located at <code>/home/tinki-team</code> holding a <code>docker-compose.yml</code> manifest with the following services:


* Artifactory HTTP: http://fedora-atomic.cadt.com:8103
Inside the container server, the stack should be located at <code>/srv/data/tinki-team-build</code> holding a <code>docker-compose.yml</code> manifest with the following services described below. To install and run the stack, execute <code>docker-compose up -d</code> from the project folder. In a similar fashion, use <code>docker-compose down</code> to halt the services. To backup the whole stack use the <code>backup-all.sh</code> script. To backup a particular service run the <code>backup.sh</code> script from its folder, if present.
* Gitlab HTTP: http://fedora-atomic.cadt.com:8101
* Gitlab SSH: http://fedora-atomic.cadt.com:22
* Jenkins HTTP: http://fedora-atomic.cadt.com:8080
* Jira HTTP: http://fedora-atomic.cadt.com:8102


[[Fitxer:devel-setup.png]]
* Docker registry, at <code>docker-reg.cadt.com</code>.
* Gitlab, at <code>git.cadt.com</code>.
* Jenkins, at <code>jenkins.cadt.com</code>.
* Jira, at <code>jira.cadt.com</code>.
* NPM, at <code>npm.cadt.com</code>.


== Artifactory ==
== Docker Registry ==


The Artifactory service exposes its web interface on '''port 8103'''. A full system backup can be done via the service's API. Backup settings need to be [https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ExportSystemSettingsExample retrieved] and sent back via [https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ExportSystem POST], as explained in the official guide. Similarly, to restore the system, [https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ImportSystemSettingsExample retrieve] the restoration settings and send them back via [https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-FullSystemImport POST], as shown in Artifactory's API guide. The current backup script will save the copy inside the container's <code>/tmp/backup</code> folder, and sync it with the host <code>/srv/data/artifactory</code>. Logs can be found on <code>/opt/jfrog/artifactory/logs</code> and are linked to the host's <code>/srv/log/artifactory</code> folder.
The Docker Registry service exposes '''port 5000'''. This service is not backed up, as it holds and serves compiled Docker images from Gitlab via Jenkins.


<pre>bash ./artifactory/backup.sh</pre>
== Gitlab ==
== Gitlab ==


The Gitlab service exposes its web interface on '''port 8101''', and also '''port 22''' for Git's SSH operations. Backup information can be found in their [https://docs.gitlab.com/ce/raketasks/backup_restore.html#creating-a-backup-of-the-gitlab-system official guide], mainly done by the service's backup creation Rake task. Configuration files should also be copied along, these include <code>/etc/gitlab/gitlab.rb</code>, <code>/etc/gitlab/gitlab-secrets.json</code> and <code>/var/opt/gitlab/config/secrets.yml</code>, as shown in the [https://docs.gitlab.com/ce/raketasks/backup_restore.html#storing-configuration-files same guide]. To restore the service follow the commands described in the [https://docs.gitlab.com/ce/raketasks/backup_restore.html#restore restoration section]. The current backup script will save the copy in the container's <code>/var/opt/gitlab</code> folder, and sync it with the host's <code>/srv/data/gitlab/data</code>. Logs can be found on <code>/var/log/gitlab</code> and are linked to the host's <code>/srv/log/gitlab</code> folder.
The Gitlab service exposes its web interface on '''port 8101''' and its SSH access through '''port 22'''. Backup is mainly done by a Rake task, as stated in the [https://docs.gitlab.com/ce/raketasks/backup_restore.html#creating-a-backup-of-the-gitlab-system official guide]. The following folders are mapped to the host in order to backup configuration files and logs, according to the [https://docs.gitlab.com/ce/raketasks/backup_restore.html#storing-configuration-files same guide]. Restoration can be found in another section of the [https://docs.gitlab.com/ce/raketasks/backup_restore.html#restore same document].
 
* <code>/var/opt/gitlab</code> to <code>/srv/data/gitlab/data</code>.
* <code>/etc/gitlab</code> to <code>/srv/data/gitlab/cfg</code>.
* <code>/var/log/gitlab</code> to <code>/srv/log/gitlab</code>.


<pre>bash ./gitlab/backup.sh</pre>
== Jenkins ==
== Jenkins ==


The Jenkins service exposes its web interface on '''port 8080'''. Jenkins is fairly simple to backup and there is no script, simply copy the <code>/var/jenkins_home</code> folder into the desired location. Restoration is done by replacing the target folder with the backup. Jenkins home folder is synced with the host's <code>/srv/data/jenkins</code> location. Logs can be found on <code>/var/jenkins_home/logs</code> and are linked to the host's <code>/srv/log/jenkins</code> folder. General information can be found in the official [https://wiki.jenkins.io/display/JENKINS/Administering+Jenkins administration guide].
The Jenkins service exposes its web interface on '''port 8080'''. It is fairly simple to backup and the process is described in its [https://wiki.jenkins.io/display/JENKINS/Administering+Jenkins administration guide]. The following folders are mapped to the host in order to backup configuration files and logs.
 
* <code>/var/jenkins_home</code> to <code>/srv/data/jenkins</code>.
* <code>/var/jenkins_home/logs</code> to <code>/srv/log/jenkins</code>.


== Jira ==
== Jira ==


The Jira service exposes its web interface on '''port 8102'''. According to the information present in their [https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html official guide], the current backup script will save the dump inside the host's <code>/srv/data/jira/db</code> folder. Its home folder can be found at the container's <code>/opt/jira</code> and is mapped to the host's <code>/srv/data/jira/data</code> folder. Logs can be found on <code>/opt/jira/log</code> and are linked to the host's <code>/srv/log/jira</code> folder.
The Jira service exposes its web interface on '''port 8102'''. According to the information present in their [https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html official guide], the current backup script will save the dump inside the host's <code>/srv/data/jira/db</code> folder. The following folders are mapped to the host in order to backup configuration files and logs.
 
<pre>bash ./jira/backup.sh</pre>


-----
* <code>/opt/jira</code> to <code>/srv/data/jira/data</code>.
* <code>/opt/jira/log</code> to <code>/srv/log/jira</code>.


== References ==
== References ==


* JFrog Artifactory User Guide. Export System Settings Example [online]. Available at https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ExportSystemSettingsExample (Accessed 16 March 2018).
* JFrog Artifactory User Guide. Export System [online]. Available at https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ExportSystem (Accessed 16 March 2018).
* JFrog Artifactory User Guide. Import System Settings Example [online]. Available at https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-ImportSystemSettingsExample (Accessed 16 March 2018).
* JFrog Artifactory User Guide. Full System Import [online]. Available at https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API#ArtifactoryRESTAPI-FullSystemImport (Accessed 16 March 2018).
* Backing up and restoring GitLab. Creating a backup of the GitLab system [online]. Available at https://docs.gitlab.com/ce/raketasks/backup_restore.html#creating-a-backup-of-the-gitlab-system (Accessed 16 March 2018).
* Backing up and restoring GitLab. Creating a backup of the GitLab system [online]. Available at https://docs.gitlab.com/ce/raketasks/backup_restore.html#creating-a-backup-of-the-gitlab-system (Accessed 16 March 2018).
* Backing up and restoring GitLab. Storing configuration files [online]. Available at https://docs.gitlab.com/ce/raketasks/backup_restore.html#storing-configuration-files (Accessed 16 March 2018).
* Backing up and restoring GitLab. Storing configuration files [online]. Available at https://docs.gitlab.com/ce/raketasks/backup_restore.html#storing-configuration-files (Accessed 16 March 2018).
Línia 53: Línia 48:
* Jenkins Wiki. Administering Jenkins [online]. Available at https://wiki.jenkins.io/display/JENKINS/Administering+Jenkins (Accessed 16 March 2018).
* Jenkins Wiki. Administering Jenkins [online]. Available at https://wiki.jenkins.io/display/JENKINS/Administering+Jenkins (Accessed 16 March 2018).
* Atlassian Documentation. Backing up data [online]. Available at https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html (Accessed 16 March 2018).
* Atlassian Documentation. Backing up data [online]. Available at https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html (Accessed 16 March 2018).
Servidors i serveis de desenvolupament:

Revisió de 12:51, 22 març 2018


tinki-team-build

Inside the container server, the stack should be located at /srv/data/tinki-team-build holding a docker-compose.yml manifest with the following services described below. To install and run the stack, execute docker-compose up -d from the project folder. In a similar fashion, use docker-compose down to halt the services. To backup the whole stack use the backup-all.sh script. To backup a particular service run the backup.sh script from its folder, if present.

  • Docker registry, at docker-reg.cadt.com.
  • Gitlab, at git.cadt.com.
  • Jenkins, at jenkins.cadt.com.
  • Jira, at jira.cadt.com.
  • NPM, at npm.cadt.com.

Docker Registry

The Docker Registry service exposes port 5000. This service is not backed up, as it holds and serves compiled Docker images from Gitlab via Jenkins.

Gitlab

The Gitlab service exposes its web interface on port 8101 and its SSH access through port 22. Backup is mainly done by a Rake task, as stated in the official guide. The following folders are mapped to the host in order to backup configuration files and logs, according to the same guide. Restoration can be found in another section of the same document.

  • /var/opt/gitlab to /srv/data/gitlab/data.
  • /etc/gitlab to /srv/data/gitlab/cfg.
  • /var/log/gitlab to /srv/log/gitlab.

Jenkins

The Jenkins service exposes its web interface on port 8080. It is fairly simple to backup and the process is described in its administration guide. The following folders are mapped to the host in order to backup configuration files and logs.

  • /var/jenkins_home to /srv/data/jenkins.
  • /var/jenkins_home/logs to /srv/log/jenkins.

Jira

The Jira service exposes its web interface on port 8102. According to the information present in their official guide, the current backup script will save the dump inside the host's /srv/data/jira/db folder. The following folders are mapped to the host in order to backup configuration files and logs.

  • /opt/jira to /srv/data/jira/data.
  • /opt/jira/log to /srv/log/jira.

References