# 워드프레스 500 Internal Server Error 해결 명령어 세트 # 주의: 아래 명령어에서 'yourdomain.com' 부분을 본인의 실제 도메인으로 모두 수정 후 사용하세요! # 1단계: 아파치 HTTPS 설정 파일 강제 생성 (루트 권한) # (이 명령어를 통째로 복사해서 터미널에 붙여넣으세요) sudo bash -c 'cat < /etc/apache2/sites-enabled/wordpress-https.conf ServerAdmin admin@example.com DocumentRoot /var/www/html SSLEngine on Options -Indexes AllowOverride All order deny,allow deny from all ServerName yourdomain.com SSLCertificateFile /etc/letsencrypt/live/yourdomain.com/fullchain.pem SSLCertificateKeyFile /etc/letsencrypt/live/yourdomain.com/privkey.pem Include /etc/letsencrypt/options-ssl-apache.conf EOF' # 2단계: .htaccess 파일 자동 생성 및 권한 설정 # (워드프레스 주소 변환 에러를 방지합니다) sudo bash -c 'cat < /var/www/html/.htaccess # BEGIN WordPress RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] # END WordPress EOF' sudo chown www-data:www-data /var/www/html/.htaccess sudo chmod 644 /var/www/html/.htaccess # 3단계: 주소 변환 모듈 활성화 및 서버 재시작 sudo a2enmod rewrite sudo systemctl restart apache2 # 완료되었습니다! 이제 블로그에 접속해서 확인해보세요.