在Arch Linux上使用Makepkg
在Arch Linux上使用Makepkg可以避免系统污染,确保仅安装必要的依赖关系。
TestLink是基于开源Web的测试管理执行系统。它使质量保证团队能够创建和管理他们的测试用例以及将它们组织到测试计划中。这些测试计划使团队成员能够执行测试用例并动态跟踪测试结果。
在本教程中,我们将1.9.16在CentOS 7上安装TestLink版本(撰写本文时的最新版本)。
我将CentOS 7服务器的主IP引用为203.0.113.1。
使用sudo用户通过SSH登录到服务器,以安装epel,更新系统并重新启动以应用更新。
sudo yum install epel-release -y
sudo yum update -y && sudo shutdown -r now
sudo yum install httpd -y
建议在生产环境中删除/禁用Apache默认欢迎页面。
sudo sed -i 's/^/#&/g' /etc/httpd/conf.d/welcome.conf
阻止Apache将Web目录文件列出给访问者:
sudo sed -i "s/Options Indexes FollowSymLinks/Options FollowSymLinks/" /etc/httpd/conf/httpd.conf
启动Apache服务,并使其在启动时自动启动
sudo systemctl start httpd.service
sudo systemctl enable httpd.service
根据TestLink 1.9.16的要求,您需要在系统上安装MariaDB 10.1或更高版本。
cat <<EOF | sudo tee -a /etc/yum.repos.d/MariaDB.repo
# MariaDB 10.1 CentOS repository list - created 2017-01-14 03:11 UTC
# http://downloads.mariadb.org/mariadb/repositories/
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.1/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
EOF
sudo yum install MariaDB-server MariaDB-client -y
sudo systemctl start mariadb.service
sudo systemctl enable mariadb.service
sudo /usr/bin/mysql_secure_installation
按照以下说明在屏幕上回答问题,并记住使用您自己的MariaDB root密码:
Enter按钮Yyour-root-passwordyour-root-passwordYYYY登录到MySQL shell root:
mysql -u root -p
键入您先前设置的MariaDB根密码,然后按Enter。
在MySQL Shell中,创建数据库testlink,数据库用户testlinkuser和数据库用户的密码yourpassword,如下所示。
注意:为了安全起见,请记住将示例密码替换为yourpassword您自己的密码。
CREATE DATABASE testlink;
CREATE USER 'testlinkuser'@'localhost' IDENTIFIED BY 'yourpassword';
GRANT ALL PRIVILEGES ON testlink.* TO 'testlinkuser'@'localhost' IDENTIFIED BY 'yourpassword' WITH GRANT OPTION;
FLUSH PRIVILEGES;
EXIT;
TestLink需要PHP 5.5或更高版本。为了获得更好的性能,我们将安装PHP 7.1和TestLink的所有必需扩展,如下所示:
sudo rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
sudo yum install mod_php71w php71w-mysqlnd php71w-common php71w-gd php71w-ldap php71w-cli php71w-mcrypt php71w-xml -y
我们将需要修改PHP设置以满足TestLink的要求,如下所示:
sudo cp /etc/php.ini /etc/php.ini.bak
sudo sed -i "s/session.gc_maxlifetime = 1440/session.gc_maxlifetime = 2880/" /etc/php.ini
sudo sed -i "s/max_execution_time = 30/max_execution_time = 120/" /etc/php.ini
/var/www/html目录:
cd
wget https://github.com/TestLinkOpenSourceTRMS/testlink-code/archive/1.9.16.tar.gz
sudo tar -zxvf 1.9.16.tar.gz -C /var/www/html
sudo chown -R apache:apache /var/www/html/testlink-code-1.9.16
sudo cp /var/www/html/testlink-code-1.9.16/custom_config.inc.php.example /var/www/html/testlink-code-1.9.16/custom_config.inc.php
使用vi文本编辑器打开此配置文件:
sudo vi /var/www/html/testlink-code-1.9.16/custom_config.inc.php
找到以下几行:
// $tlCfg->log_path = '/var/testlink-ga-testlink-code/logs/'; /* unix example */
// $g_repositoryPath = '/var/testlink-ga-testlink-code/upload_area/'; /* unix example */
替换为:
$tlCfg->log_path = '/var/www/html/testlink-code-1.9.16/logs/';
$g_repositoryPath = '/var/www/html/testlink-code-1.9.16/upload_area/';
保存并退出:
:wq!
cat <<EOF | sudo tee -a /etc/httpd/conf.d/testlink.conf
<VirtualHost *:80>
ServerAdmin admin@example.com
DocumentRoot /var/www/html/testlink-code-1.9.16/
ServerName testlink.example.com
ServerAlias www.testlink.example.com
<Directory /var/www/html/testlink-code-1.9.16/>
Options FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog /var/log/httpd/testlink.example.com-error_log
CustomLog /var/log/httpd/testlink.example.com-access_log common
</VirtualHost>
EOF
sudo systemctl restart httpd.service
sudo firewall-cmd --zone=public --permanent --add-service=http
sudo firewall-cmd --reload
http://203.0.113.1首次访问时,将显示TestLink安装向导。
在第一页上,单击New installation链接。
在Acceptance of License页面上,选中I agree to the terms set out in this license.,然后单击Continue按钮。
在Verification of System and configuration requirements页面上,确保满足所有要求(不包括Postgres和上的要求MSSQL),然后单击Continue按钮。
在Database Configuration页面上,提供如下数据库配置信息,然后单击Process TestLink Setup按钮以完成安装:
MySQL/MariaDB (5.6+ / 10.+)localhosttestlink<LEAVE IT EMPTY>root<your-MariaDB-root-password>testlinkuseryourpassword您可以将您的网络浏览器指向http://203.0.113.1开始使用TestLink,并且需要使用以下默认凭据登录:
adminadmin注意:请记住在登录后更改密码。
为了安全起见,apache安装后应限制用户的权限:
sudo chown -R root:root /var/www/html/testlink-code-1.9.16
sudo chown -R apache:apache /var/www/html/testlink-code-1.9.16/{gui,logs,upload_area}
sudo systemctl restart httpd.service
此外,您应该删除/var/www/html/testlink-code-1.9.16/install目录:
sudo rm -rf /var/www/html/testlink-code-1.9.16/install
而已。谢谢阅读。
在Arch Linux上使用Makepkg可以避免系统污染,确保仅安装必要的依赖关系。
快速学习如何在Ubuntu 16.04上安装OpenSIPS控制面板,为VoIP提供商提供支持的功能。
学习如何在Fedora 28上安装Akaunting,一款适合小型企业和自由职业者的开源会计软件。
使用其他系统?Mailtrain是一个基于Node.js和MySQL / MariaDB构建的开源自托管新闻通讯应用程序。
了解導致Minecraft延遲的原因和解決方案,包括優化伺服器性能和減少滯後的步驟。
勒索軟件攻擊呈上升趨勢,但人工智能能否幫助應對最新的計算機病毒?AI 是答案嗎?在這裡閱讀知道是 AI 布恩還是禍根
ReactOS,一個開源和免費的操作系統,這裡有最新版本。它能否滿足現代 Windows 用戶的需求並打倒微軟?讓我們更多地了解這種老式但更新的操作系統體驗。
Whatsapp 終於為 Mac 和 Windows 用戶推出了桌面應用程序。現在您可以輕鬆地從 Windows 或 Mac 訪問 Whatsapp。適用於 Windows 8+ 和 Mac OS 10.9+
閱讀本文以了解人工智能如何在小型公司中變得流行,以及它如何增加使它們成長並為競爭對手提供優勢的可能性。
最近,Apple 發布了 macOS Catalina 10.15.4 補充更新以修復問題,但似乎該更新引起了更多問題,導致 mac 機器變磚。閱讀這篇文章以了解更多信息