In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Version control (code management) tool
1 CVS
2 SVN centralized version control system
There is only one remote code base, and all programmers need to connect to the network to push the code to the server.
3 Gitlab distributed version control system
There is a remote code base, and every programmer can clone a local code base remotely and work offline. Of course, every programmer has limited permissions and can only clone parts of the code that have permission.
Installation configuration
Download gitlab-ce and upload it to the server
Yum-y install gitlab-ce-10.8.7-ce.0.el7.x86_64.rpm
Vim / etc/gitlab/gitlab.rb
External_url 'http://192.168.1.14' # external access address
Gitlab_rails ['smtp_enable'] = true # the purpose of configuring the mail service is to allow users who forget their passwords to reset their passwords themselves through their mailboxes
Gitlab_rails ['smtp_address'] = "smtp.163.com"
Gitlab_rails ['smtp_port'] = 25
Gitlab_rails ['smtp_user_name'] = "dongyali@163.com"
Gitlab_rails ['smtp_password'] = "aaaaaaaa"
Gitlab_rails ['smtp_authentication'] = "login"
Gitlab_rails ['smtp_enable_starttls_auto'] = true
Gitlab_rails ['smtp_tls'] = false
Gitlab_rails ['gitlab_email_from'] =' dongyali521521@163.com'
Gitlab_rails ['smtp_domain'] = "163.com"
User ['git_user_email'] = "dongyali521521@163.com"
Gitlab-ctl reconfigure
Gitlab-ctl status
Grep "^ [a Merz]" / etc/gitlab/gitlab.rb
Http://192.168.1.14
Root needs to be configured with a password when logging in for the first time
Basic operation
Disable the account registration function:
Click the wrench icon-setting---sign up restrictions--- to cancel sing-up enabled
New user:
Click the wrench icon-new user. Mailbox is required to reset the password.
Create a new group:
Click the wrench icon-new group, create the group, click Add user (s) to the group, add the user to the group and grant the appropriate permissions
Administrators belong to each group by default
There are five types of permissions for users: guest,reporter,developer,maintainer,owner
Create a new project:
Click the wrench icon-new project. The project path needs to select root or a group.
Clone the code in http (username and password required)
Yum-y install git
View the clone address on gitlab:
Project---your project---project name---http mode
Git clone http://192.168.1.14/group1/project1.git
Cd project1/
Vim index.html
Git add.
Git config-global user.name "user1"
Git config-global user.email 465130613@qq.com
Git commit-m "xxxx"
Git config-global push.default simple
Git push
Secret-free cloning code with ssh method
Generate the key of the root user on the git client
Cd / root
Ssh-keygen
Cat / root/.ssh/id_rsa.pub
Configure the pub-key generated above on gitlab:
Click the projects---your projects---projects name--- gear icon settings
-repository---Deploy Keys--- enter key value-click Write access allowed
Rm-rf project1/ # deletes the previously cloned
Git clone git@192.168.1.15:group1/project1.git (input yes for the first time to pull)
Cd project1/
Vim index.html
Git add.
Git commit-m "11111"
Git push
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.