오픈소스용 사내 IP관리 시스템 설치 및 가이드 입니다.
1. Locale 설정
sudo vi /etc/enviroment 에서
LC_ALL=en_US.utf-8
LANG=en_US.utf-8
변경 후 저장
2. Aphache, MySQL, PHP stack Package 설치
- sudo yum -y install httpd mariadb-server php php-cli php-gd php-common php-ldap php-pdo php-pear php-snmp php-xml php-mysql php-mbstring git
※ API crypt method 이용 시
- sudo yum -y install epel-release
- sudo yum -y install php-mycrypt
epel-release 가 설치되지 않았을 경우 php-mycrypt 설치 오류 발생
3. Apache webserver 설정 변경
- sudo vi /etc/httpd/conf/httpd.conf
- DocumentRoot "/webapp" 등으로 이름 변경
- <Directory "/var/www/html"> 를 <Directory "/webapp"> 으로 변경
※ httpd, mariadb 시작
- sudo systemctl start httpd
- sudo systemctl enable httpd
- sudo systemctl start mariadb
- sudo systemctl enable mariadb
4. iptables 설정
- sudo vi /etc/sysconfig/iptables 수정
"-A INPUT -s [source Network] -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT"
" -A INPUT -s [source Network] -p tcp -m state --state NEW -m tcp --dport 443 -j ACCEPT"
접속하려는 IP대역(네트워크) 에서 80,443 Port 허용
※ seLinux상에서 firewall 정책이 복잡하고 보안 정책 상 막히는 부분이 많으므로 firewalld 중지 후 iptables설치
* firewalld 중지
- sudo systemctl stop firewalld
- sudo systemctl disable firewalld
* iptables 설치
- sudo yum -y install iptables
5. PHPipam 설치
- cd /var/www/html
- git clone https://github.com/phpipam/phpipam.git
- cd phpipam
- sudo cp config.dist.php config.php 기본 config파일 복사해서 config.php 파일 생성
- sudo cp -R /var/www/html/phpipam /webapp/ipam
- cd /webapp/ipam
- sudo vi config.php 파일 내에 define ('BASE', "/ipam/"); 으로 수정 (Default는 phpipam)
6. http://ip_address/ipam 으로 이동
- Automatic database installation을 누르고 데이터베이스 설치
- DB 설치가 완료되면 phpipam은 /webapp/ipam/config.php 파일에 입력된 사용자이름/암호를 사용하여 DB에 엑세스(Root 암호는 저장되지 않음)
참조 : https://phpipam.net/news/phpipam-installation-on-centos-7/
phpIPAM installation on CentOS 7
How to install phpipam on CentOS 7 linux.
phpipam.net
'리눅스 > CentOS' 카테고리의 다른 글
[Filebrowser] 사내 파일공유 시스템 (1) | 2019.10.17 |
---|---|
[CentOS] 원격 접속 설정 (0) | 2019.10.17 |