gitlab

gitlab的搭建与使用(一)

冷暖自知 提交于 2019-12-10 20:42:21
yum install curl policycoreutils openssh-server openssh-clients postfix -y systemctl enable sshd systemctl start sshd systemctl enable postfix [root@xuegod63 ~]#systemctl start postfix [root@xuegod63 ~]# iptables -F #清空规则 [root@xuegod63 ~]# systemctl stop firewalld [root@xuegod63 ~]# systemctl disable firewalld [root@xuegod63 ~]#firewall-cmd --permanent --add-service=http [root@xuegod63 ~]#systemctl reload firewalld wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.2.3-ce.0.el7.x86_64.rpm rpm -ivh gitlab-ce-10.2.3-ce.0.el7.x86_64.rpm vim /etc/gitlab/gitlab.rb 改:13

GitLab cannot clone public repo without public key

好久不见. 提交于 2019-12-10 19:04:15
问题 Using GitLab 6.8.2. Can I clone public repository as anonymous? I have repo in my user namespace marked as public . I cannot clone it without public key saved in GitLab. For example: > ssh -T git@git.site.com Welcome to GitLab, Known Username! When doing it from account with stored public key in GitLab. But when doing same thing from user without any keys and GitLab account I have: > ssh -T git@git.site.com Permission denied (publickey). Detailed otput: > ssh -v git@git.site.com OpenSSH_5.9p1

GitLab: Is there a way to protect a branch from command line?

こ雲淡風輕ζ 提交于 2019-12-10 18:15:30
问题 Am aware of how its done from the GitLab UI (http://gitlabdomain.com/ProjectNamespace/Project/protected_branches), but is there a way to "Protect" a particular branch from the command line? 回答1: Sure, you need a third-party command-line tool for that though, or use the REST API directly yourself. Check http://www.rubydoc.info/gems/gitlab/frames which is listed on https://about.gitlab.com/applications/ 回答2: You cant protect branch from the command line. Git doesn't know how did you execute the

linux系统(centOS7.3)安装gitlab

被刻印的时光 ゝ 提交于 2019-12-10 18:02:29
简介 代码管理,感觉还是gitlab好用,搭建新的开发环境,需要搭建一个gitlab服务器,搭建成功了,做一下记录。 参考地址 一、搭建环境 1、安装所需依赖 yum install curl openssh-server openssh-clients postfix cronie 2、gitlab使用postfix发送邮件 service postfix start 3、设置postfix开机自启 chkconfig postfix on 二、安装gitlab 1、使用yum安装 创建/etc/yum.repos.d/下面创建gitlab_gitlab-ce.repo文件 touch gitlab_gitlab-ce.repo 编辑文件内容 [gitlab-ce] name=Gitlab CE Repository baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el$releasever/ gpgcheck=0 enabled=1 安装gitlab yum makecache #更新本地缓存,提高安装速度 yum install gitlab-ce #安装gitlab gitlab-ctl reconfigure #配置gitlab 2、rpm安装 下载rpm包 wget https://mirrors

GitLab self host SSL issues - validation failed for domain

℡╲_俬逩灬. 提交于 2019-12-10 17:35:41
问题 I am attempting to setup gitlab self host, which has been relatively easy, but have started to stumble at the let's encrypt setup part of the integration. There was an error running gitlab-ctl reconfigure: letsencrypt_certificate[gitlab.cloudcreations.co.uk] (letsencrypt::http_authorization line 3) had an error: RuntimeError: acme_certificate[staging] (/opt/gitlab/embedded/cookbooks/cache/cookbooks/letsencrypt/resources/certificate.rb line 20) had an error: RuntimeError: [gitlab

Gitlab docker not working if external_url is set

那年仲夏 提交于 2019-12-10 17:24:00
问题 I've been struggling for a while with a problem that I'm still unable to solve. Help would be much appreciated! What I did: 1) Install Gitlab-CE using the docker image (8.9.6-ce.0) on an Ubuntu 16.04.1 LTS virtual machine in my server following http://docs.gitlab.com/omnibus/docker/README.html 2) Setup a user locally and push some projects for a machine in the same LAN >> all working ok 3) Add a new mapping to my firewall to map gitlab-machine-ip:80 > example.org:8138 so that I can access

Gitlab docker and external_url

我与影子孤独终老i 提交于 2019-12-10 17:18:16
问题 Hello I installed latest gitlab using docker. I started the container with -p 10080:80 and 10022:22 I can browse gitlab and do what I need I can even git clone both http and ssh using ports 10080 and 10022 respectively. In the front end though the urls don't show with the appropriate ports. I changed the ssh_shell property. That works fine! For whatever reason any attempt to modify the external_url property doesn't work! I put "http://myhost:10080" But when I restart the container it doesn't

centos7安装docker部署gitlab

落花浮王杯 提交于 2019-12-10 17:16:32
使用VMware安装centos7,进入centos后,打开terminal。 1、VMware先设置好固定IP,用于后面gitlab的配置 2、输入su,进行登录root管理员账号进行操作,(输入设置好的root密码) 3、设置好阿里云的yum源,官方的源国内网速不行,会出现超时,然后安装docker。 参考教程: Centos7更新yum源下载docker 4、安装完docker之后,设置镜像源,国内访问外网速度堪忧。 修改或新增 /etc/sysconfig/docker,在OPTIONS变量后追加参数 --registry-mirror=https://docker.mirrors.ustc.edu.cn # vi /etc/sysconfig/docker OPTIONS='--selinux-enabled --log-driver=journald --registry-mirror=https://docker.mirrors.ustc.edu.cn' 5、修改之后重启docker service docker restart 6、找到相应gitlab,下载gitlab。默认使用官方的镜像 ①、查找镜像资源:docker search gitlab ②、安装gitlab。 docker pull gitlab/gitlab-ce 7、在本机准备gitlab工作目录

Exporting environment variables from one stage to the next in GitLab CI

情到浓时终转凉″ 提交于 2019-12-10 16:25:47
问题 Is there a way to export environment variables from one stage to the next in GitLab CI? I'm looking for something similar to the job artifacts feature, only for environment variables instead of files. Let's say I'm configuring the build in a configure stage and want to store the results as (secret, protected) environment variables for the next stages to use. I could safe the configuration in files and store them as job artifacts but I'm concerned about secrets beeing made available in files

gitlab-CI for a Haskell Stack project: How to cache built libraries?

試著忘記壹切 提交于 2019-12-10 16:06:09
问题 I'm using the following .gitlab-ci.yml file for setting up gitlab-CI for a Haskell Stack project created with stack new actividad3 --resolver=lts-14.6 . image: haskell:8.6.5 cache: paths: - .stack - .stack-work - target test: stage: test script: - ghc --version - stack --system-ghc build - stack test Building and testing the project last almost 5 minutes. Most of the time is spent building the hspec library. Is there any way to cache the used libraries between pipeline runs? Thanks in advance