일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
- KB국민카드
- 킹북이초월
- 알리익스프레스
- 가상서버호스팅
- 스톤에이지
- 티스토리
- nginx
- jQuery
- KB증권
- 시놀로지
- 리눅스
- 아파치
- 램가스초월
- centos
- iptime
- 소비전력
- Linux
- Rocky
- 알뜰폰
- mysql
- proxmox
- PHP-FPM
- OpenWrt
- 자바스크립트
- php
- 윈도우10
- SKT
- 보르비스초월
- 복현오거리
- Apache
- Today
- Total
맛집 여행 캠핑 일상 생활
도커 php5.6 php7.4 php8.2 아파치 설치 방법입니다.하나의 이미지에 php+apache가 같이 있는 docker image입니다.docker-compose.ymlservices: php56: #image: php:5.6-apache container_name: php56-apache build: context: . dockerfile: ./Dockerfile-php56 ports: - "8156:80" volumes: - ./www:/var/www/html - ./httpd/logs:/etc/apache2/logs - ./httpd/conf/example.conf:/etc/apache2/sites-enable..
도커 허브에는 nginx + php-fpm이 같이 있는 이미지를 못찾겠네요~따로 따로 조합해서 사용하는 방법 말고 하나의 이미지에서 서비스하는 방법입니다.1. docker-compose.ymlservices: nginx: #image: nginx:latest container_name: nginx-php82 build: context: . dockerfile: ./Dockerfile-nginx restart: always ports: - "8080:80" volumes: - ./www:/var/www/html - ./nginx/logs:/var/log/nginx - ./nginx/conf:/etc/nginx/conf...
이것 저것 테스트 한다고 그런지는 모르겠는데 MariaDB가 저도 모르게 죽어있더군요~[root@localhost conf.d]# systemctl restart mariadbJob for mariadb.service failed because the control process exited with error code.See "systemctl status mariadb.service" and "journalctl -xeu mariadb.service" for details.[root@localhost conf.d]# systemctl status mariadb× mariadb.service - MariaDB 10.5 database server Loaded: loaded (/usr/lib/sy..
docker가 설치되어 있지 않다면 docker를 설치합니다.yum config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repoyum -y install docker-ce docker-ce-cli containerd.iosystemctl enable dockersystemctl start dockerdocker compose version 명령어로 버전명이 잘 나오는지 확인합니다.mkdir -p ~/docker/certbot/nginxcd ~/docker/certbotcat ~/docker/certbot/nginx/certbot.confserver { listen 80; server_name example...
duckdns.org 는 무료로 ddns 5개 subdomain을 사용할 수가 있습니다.한가지 아쉬운 점이 있다면 무료인증서 letsencrypt 툴인 certbot 으로는 webroot 방식으로만 가능한 것 같네요~1. Apachecat /etc/httpd/conf.d/certbot.conf ServerName example.duckdns.org DocumentRoot /var/www/certbot ErrorLog logs/certbot-error_log CustomLog logs/certbot-access_log vcommon Require all granted EOF2. NGINXcat /etc/nginx/conf.d/certbot.confserve..
PHP8.2 버전에서는 PHPExcel 이 엄청난 에러를 뿜어내는군요~php 8.x 버전에서는 PhpSpreadSheet 를 사용하면 되네요~먼저 /etc/php.ini 파일에서 allow_url_fopen 을 On 으로 되어 있어야 아래의 composer 가 실행이 됩니다.설치하려는 위치에서 아래 명령어로 설치하면 됩니다. cat /etc/php.ini | grep ^allow_url_fopensed -i 's/^allow_url_fopen\ =\ Off/allow_url_fopen = On/g' /etc/php.iniphp -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"php -r "if (hash_file('sha384',..
CentOS 7 지원 종료로 mirrorlist.centos.org 에서 패키지 검색이 안되는군요~지원이 종료되면서 vault.centos.org 으로 변경해줘야 하네요~yum 유틸을 괜히 업데이트 했나봅니다.서버 두군데가 CentOS 7 인데 한곳은 되고 한곳은 안됩니다~# nslookup mirrorlist.centos.org ;; Got SERVFAIL reply from 168.126.63.1, trying next server Server: 8.8.8.8 Address: 8.8.8.8#53 ** server can't find mirrorlist.centos.org.co.kr: SERVFAIL# nslookup mirrorlist.centos.org 168.126.6..
CentOS 7.x 버전에서는 Rocky 리눅스와 달리 yum install 로 설치를 지원하는 않는군요~yum install make gcc iptables-devel perl-Text-CSV_XS perl-App-cpanminus cpanm NetAddr::IP cpanm Getopt::Long wget mirror.koreaidc.com/iptables/xtables-addons-2.10.tar.gz tar xvfz xtables-addons-2.10.tar.gz cd xtables-addons-2.10 sed -i '/build_TARPIT=m/ s/^/#/' mconfig ./configure make && make install mkdir /usr/share/xt_geoip cd geoip ...
해외 IP 차단을 하려고 해도 수많은 아이피를 전부 iptables 로 차단하려면 수 만 줄이 넘어갑니다.한국 KR 이 아니면 차단하는게 간단해 보이네요~CentOS 7은 yum install 로 안되는데 rocky 9 은 쉽게 설치가 가능합니다.yum install https://download1.rpmfusion.org/free/el/rpmfusion-free-release-9.noarch.rpmyum install iptables-services iptables-devel xtables-addons perl-Text-CSV_XS perl-App-cpanminus cpanm Net::CIDR::Lite cpanm Text::CSV_XS mkdir /usr/share/xt_geoip /usr/libex..
sysctl.conf 에 net.ipv6.conf.all.disable_ipv6 = 1 넣어서 ipv6를 disable 시켰더니 잘되던 sendmail 이 안되는군요~sendmail: fatal: parameter inet_interfaces: no local interface found for ::1메일 발송을 실패하였습니다. # vi /etc/postfix/main.cf inet_interfaces = all #inet_interfaces = localhostinet_interfaces = localhost 주석 처리하고 inet_interfaces = all 로 하니 잘 됩니다.

리눅스에서 리눅스 또는 Proxmox 는 sshfs 로 mount 가 쉽게 되던데요~시놀로지는 그냥 쉽게 되는게 없군요~보안 방화벽에서 해당 포트도 열어줘도 안되고 한참을 헤매다가 성공한 뒤에 후기 남겨봅니다.# mkdir ~/synology # sshfs -oport=2222,reconnect userID@test-user.synology.me:/home ~/synology read: Connection reset by peer참고로 kex_exchange_identification: read: Connection reset by peer 에러는 접속 시도를 자주 했더니 해당 IP가 차단되어서 나오는 에러 로그입니다.시놀로지 제어판 . 보안 . 보호 . 허용/차단 목록에서 차단된 아이피를 삭제하면 됩니..
Synology DSM 6.x 버전과 DSM 7.x 버전이 설정 경로가 다르군요~WebStation 에서 가상호스트를 추가해서 테스트 하는데 index.html 에 있는 php 코드가 실행이 안되네요~apache, nginx 둘다 안됩니다.디폴트로 .html 도 작동하도록 해주면 좋겠지만 설정할때 마다 추가 설정을 해줘야 하네요~backend apache2.4 인 경우# find / -name httpd-vhost.conf/usr/local/etc/apache24/sites-enabled/httpd-vhost.conffind 명령어로 httpd-vhost.conf 파일을 찾습니다.# cat /usr/local/etc/apache24/sites-enabled/httpd-vhost.confInclude co..
시놀로지는 unzip 명령어가 없네요~대신에 7z 명령어로 압축을 풀 수가 있습니다.7z x -p비번 -o/압축풀디렉토리/ /압축파일.zipp7zip Version 9.20 (locale=en_US.utf8,Utf16=on,HugeFiles=on,2 CPUs)Usage: 7z [...] [...] [] a: Add files to archive b: Benchmark d: Delete files from archive e: Extract files from archive (without using directory names) l: List contents of archive t: Test integrity of archive u: Update files to archive ..
Proxmox 는 rc-local 데몬은 설치되어 있는데 /etc/rc.local 파일이 없군요~커스텀 스크립트를 만들어 놓고 부팅시 자동실행 되게 하는 방법입니다.cat /etc/rc.local#!/bin/bash/usr/local/bin/custom.shEOFchmod +x /etc/rc.localsystemctl enable rc-localsystemctl restart rc-local/etc/rc.local 파일을 만들어주면 되는 간단한 문제였네요~
라즈베리파이2 에 OpenWrt 를 설치했는데 루트 파티션이 SD Card 일부만 잡혀있네요~opkg updateopkg install fdisk lsblkopkg install parted losetup resize2fs부팅 후 opkg update 한 적이 없다면 한번은 update를 해줘야 하는 단점이 있습니다.root@OpenWrt:~# df -hFilesystem Size Used Available Use% Mounted on/dev/root 98.3M 20.3M 76.0M 21% /tmpfs 463.8M 1.0M 462.8M 0% /tmp/dev/mmcblk0p1 ..