centos/debian配置gitlab 7.1x来搭建自建的git仓库.

本文介绍如何在CentOS/Debian环境下配置GitLab 7.1x来搭建自建的Git仓库。包括下载安装、配置步骤及注意事项等关键信息。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

centos/debian配置gitlab 7.1x来搭建自建的git仓库.

前言:因为公司的某些历史原因, 有大量的代码还在csv/svn上. 新来的项目不得不走这个,同时,github的enterprise 2500$/y/10p的价格对于多变的项目和人员也不合适. 也为了让某些不习惯使用linux的开发使用上git, 就放弃了之前的gitolite server, 进而采用gitlab来搭建.

www.gitlab.com 是gitlab的仓库, 以前的历史版本, 需要先配置gitolite, 然后配server端来支持web功能. 新的已经实现一键包了.

-下载

使用https://about.gitlab.com/downloads/ 来选择对应的版本
wget 后直接运行一键脚本就可以了.

这个官方的版本非常不友好, 一键装完, 什么都没配置. 配了半天, 发现repo的地址还是domain.com…

gitlab也支持分开安装, 你自己指定server, 数据库这些, 如果一个一个装, 7个流程走下来, 也太过繁琐. 所以我们换一个公司出的,bitnami出的一键包.

地址在https://bitnami.com/stack/gitlab/installer

可以根据系统来选择是32还是64bit的, 推荐用recommended的版本.

下载到服务器后, 先去检查下服务器的80端口是否给占用. 停掉nginx or apache/httpd
把它们转到808x. 我这里要用一个完整的域名来使用gitlab,
e.g:http://dev.domain.org

安装前, 删除掉已经有的git帐号, 和git的home目录. 保证系统干净.


[root@fca-vm-demo-opt]# wget https://downloads.bitnami.com/files/stacks/gitlab/7.11.4-0/bitnami-gitlab-7.11.4-0-linux-x64-installer.run
--2015-06-09 19:31:19--  https://downloads.bitnami.com/files/stacks/gitlab/7.11.4-0/bitnami-gitlab-7.11.4-0-linux-x64-installer.run
Resolving downloads.bitnami.com... 216.235.167.23
Connecting to downloads.bitnami.com|216.235.167.23|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 311542012 (297M) [application/x-makeself]
Saving to: “bitnami-gitlab-7.11.4-0-linux-x64-installer.run”

100%[===========================================================================================================================================================>] 311,542,012 2.06M/s   in 2m 40s  

2015-06-09 19:34:05 (1.86 MB/s) - “bitnami-gitlab-7.11.4-0-linux-x64-installer.run” saved [311542012/311542012]

[root@fca-vm-demo-opt]# chmod a+x bitnami-gitlab-7.11.4-0-linux-x64-installer.run 

[root@fca-vm-demo-opt]# ./bitnami-gitlab-7.11.4-0-linux-x64-installer.run 
The installer detects that exists a 'git' user in the system. This installer will change the configuration for this user. Do you want to continue the installation? [y/N]: y

The installer detects that exists a 'gitlab_ci' user in the system. This installer will change the configuration for this user. Do you want to continue the installation? [y/N]: y

----------------------------------------------------------------------------
Welcome to the Bitnami Gitlab Stack Setup Wizard.

----------------------------------------------------------------------------
Select the components you want to install; clear the components you do not want 
to install. Click Next when you are ready to continue.

PhpPgAdmin [Y/n] :Y 

GitLab : Y (Cannot be edited)

GitLab CI [Y/n] :Y

Is the selection above correct? [Y/n]: Y

----------------------------------------------------------------------------
Installation folder

Please, choose a folder to install Bitnami Gitlab Stack

Select a folder [/opt/gitlab-7.11.4-0]: /opt/bitnami

----------------------------------------------------------------------------
Create Admin account

Bitnami Gitlab Stack admin user creation

Email Address [user@example.com]: rainysia@gmail.com

Login [user]:  rainysia

Password :
Please confirm your password :

----------------------------------------------------------------------------
Hostname that will be used to create internal URLs. If this value is incorrect, 
you may be unable to access your Gitlab installation from other computers. It is 
advisable to use a Domain instead of an IP address for compatibility with 
different browsers.

Domain [127.0.0.1]:  dev.domain.org
Do you want to configure mail support? [y/N]: N

----------------------------------------------------------------------------
Setup is now ready to begin installing Bitnami Gitlab Stack on your computer.

Do you want to continue? [Y/n]: Y

----------------------------------------------------------------------------
Please wait while Setup installs Bitnami Gitlab Stack on your computer.

 Installing
 0% ______________ 50% ______________ 100%
 #########################################

----------------------------------------------------------------------------
Setup has finished installing Bitnami Gitlab Stack on your computer.

Info: To access the Bitnami Gitlab Stack, go to
http://dev.domain.org:80 from your browser.
Press [Enter] to continue:


这样就装好了. 中间容易出问题的地方, git本来的帐号, 各个gitlab和git的home目录, 以及/var/opt下的gitlab目录, 我这里没有设置mail server

使用很简单了

有几个使用的说明,

  1. gitlab不支持initial repo, 所以你需要先用一个https://的git仓库来导入.
  2. 配置ssh key后, 是在 /profile这里面的/profile/key e.g:http://dev.domain.org/profile/keys
  3. 保证你要使用仓库的用户的ssh key是id_ras.pub key
  4. 拉取的时候直接用 git@dev.domain.org:username/project_name.git ,如果是read, 可以走http.
  5. 因为这里为没有走其它端口或者2级,3级域名, 所以需要走其他端口的, 需要在域名那里重配. 整个gitlab都在/opt/下, 里面的apps是应用,ctlscript.sh是配置重置重启shell

key setting

user status

<think>好的,我需要帮助用户在麒麟操作系统的arm64架构下安装LibreOffice。首先,我要回顾用户提供的引用资料,看看有没有相关的安装步骤或者建议。 用户提到了引用[2],其中提到有适用于Linux AArch64的LibreOffice安装包,项目地址是gitcode.com。这可能是一个直接获取预编译包的方法。然后引用[4]详细描述了在银河麒麟v10系统上通过源码编译安装libreoffice7.1.8.1的步骤,包括解压源码、运行autogen.sh配置编译选项,并且排除了Java支持。此外,引用[3]提到在ARM架构服务器上适配安装,包括LibreOffice的编译和打包,可能涉及到依赖项的安装和配置。而引用[5]虽然主要是关于onlyoffice的docker部署,但可能间接说明在麒麟系统上部署办公软件的一些通用注意事项。 首先,用户可能希望直接安装预编译的包,这样更简单快捷。根据引用[2],可以建议用户访问提供的项目地址下载安装包,并按照其说明进行安装。如果预编译包可用,这将是最简便的方法。 如果预编译包不可用或版本不匹配,那么需要从源码编译安装。引用[4]中的步骤详细说明了如何解压源码、配置编译选项,并生成RPM包。用户需要安装必要的编译工具和依赖项,例如gcc、make、autoconf等。此外,配置选项中排除了Java支持,这可能减少了依赖项的数量,但用户如果需要Java功能,可能需要调整配置参数。 另外,需要注意麒麟系统可能基于不同的Linux发行版,比如Ubuntu或CentOS,这会影响包管理器的使用。如果是基于Debian的系统,可能需要使用apt安装依赖;如果是基于Red Hat的系统,则使用yum或dnf。用户需要根据系统类型安装相应的开发工具和。 可能遇到的问题包括依赖项缺失、配置选项错误或编译过程中的兼容性问题。需要确保所有必要的依赖都已正确安装,并且编译选项适合目标架构。此外,编译过程可能需要较长时间,尤其是在性能较低的设备上。 总结来说,安装步骤可能包括: 1. 尝试获取预编译的AArch64安装包。 2. 如果不可行,则下载源码并按照引用[4]的步骤进行编译安装。 3. 处理依赖项和系统特定的配置。 4. 解决可能出现的错误,如缺少配置参数不正确。 需要提醒用户在编译前更新系统并安装必要的开发工具,同时注意备份重要数据,以防安装过程中出现问题。</think>### 在麒麟操作系统 ARM64 架构下安装 LibreOffice 的步骤 #### 方法1:使用预编译安装包(推荐) 1. **获取预编译包** 访问引用[2]提供的项目地址(https://gitcode.com/open-source-toolkit/9fefd),下载适用于 ARM64 架构的 LibreOffice 安装包。 *注意:需确认包版本与系统兼容性。* 2. **安装依赖项** ```bash sudo apt update # 适用于基于Debian的系统(如银河麒麟v10) sudo apt install libgl1-mesa-dev libx11-dev libxt-dev libxext-dev ``` 3. **安装LibreOffice** 使用包管理器安装下载的 RPM 或 DEB 文件: ```bash sudo dpkg -i libreoffice*.deb # Debian系 # 或 sudo rpm -ivh libreoffice*.rpm # RedHat系 ``` --- #### 方法2:源码编译安装(适用于自定义需求) 1. **下载源码** 从官网或引用[4]获取源码包(如 `libreoffice-7.1.8.1.tar.xz`),上传到 `/root` 目录。 2. **解压并配置环境** ```bash sudo tar xf /root/libreoffice-7.1.8.1.tar.xz -C /opt cd /opt/libreoffice-7.1.8.1 ``` 3. **安装编译依赖** ```bash # 银河麒麟/Ubuntu系 sudo apt install build-essential automake autoconf libtool \ libcairo2-dev libgdk-pixbuf2.0-dev libicu-dev ``` 4. **配置编译选项** ```bash ./autogen.sh --without-java --without-junit \ --with-lang=zh-CN --disable-postgresql-sdbc \ --without-doxygen --with-package-format=rpm --enable-epm \ --srcdir=/opt/libreoffice-7.1.8.1 --enable-option-checking=fatal ``` *说明:`--without-java` 表示禁用Java支持,若需Java功能需安装JDK并移除该选项[^3][^4]。* 5. **编译并打包** ```bash make -j$(nproc) # 根据CPU核心数并行编译 make rpm # 生成RPM包 ``` 6. **安装生成的RPM包** ```bash sudo rpm -ivh ./workdir/installation/rpm_packages/*.rpm ``` --- #### 验证安装 ```bash libreoffice7.1 --version # 检查版本 ``` --- ### 常见问题解决 1. **依赖项缺失** 根据编译错误提示安装缺失的(如 `libpoppler-cpp-dev`)。 2. **内存不足导致编译失败** 增加交换空间或使用 `make -j2` 减少并行任务数。 3. **兼容性问题** 确保源码版本与系统内核及版本匹配,参考引用[4]的配置参数。 ---
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值