x

주요 장

  1. LimeSurvey Cloud vs LimeSurvey CE
  2. 빠른 시작 가이드 - LimeSurvey 3.0+
  3. 설치 - LimeSurvey CE
  4. 좋은 설문조사를 디자인하는 방법(가이드)
  5. 시작하기
  6. LimeSurvey 관리
  7. 설문조사 - 소개
  8. 설문조사 설정
  9. 설문조사 메뉴
  10. 설문 조사 구조
  11. 질문 - 소개
  12. 질문 그룹 - 소개
  13. 설문조사 관리
  14. 설문조사 도구 모음 옵션
  15. 다국어 설문조사
  16. ExpressionScript 엔진 - 빠른 시작 가이드
  17. 미분류 및 고급 기능
  18. 일반 FAQ
  19. 문제 해결
  20. 해결 방법
  21. 특허
  22. 버전 변경 로그
  23. 플러그인 - 고급
 Actions

LimeSurvey nginx 구성 예시

From LimeSurvey Manual

이 페이지는 기계 번역되었을 수 있으며 오류가 포함되어 있을 수 있습니다. 영어 원문 보기 · 이 번역 개선하기
This page is a translated version of the page LimeSurvey nginx example configuration and the translation is 100% complete.

LimeSurvey용 Nginx 구성 예시

다음은 nginx와 PHP-FPM으로 LimeSurvey를 실행하기 위한 구성 예시입니다. 서버 환경에 맞게 경로, 도메인 이름, PHP-FPM 소켓/포트 설정을 조정하십시오.

참고: 이 예시는 기본적인 구성입니다. 운영 환경에서 사용하기 전에 반드시 검토하고 사용자의 보안 요구 사항에 맞게 수정하십시오.

server {
    listen 80;
    server_name survey.example.com;
    # Redirect all HTTP traffic to HTTPS
    return 301 https://$host$request_uri;
}

server {
    listen 443 ssl http2;
    server_name survey.example.com;

root /var/www/limesurvey;
    index index.php;

# SSL certificates
    ssl_certificate     /etc/ssl/certs/survey.example.com.crt;
    ssl_certificate_key /etc/ssl/private/survey.example.com.key;

# Recommended SSL settings
    ssl_protocols TLSv1.2 TLSv1.3;
    ssl_prefer_server_ciphers on;

client_max_body_size 100M;

access_log /var/log/nginx/limesurvey_access.log;
    error_log  /var/log/nginx/limesurvey_error.log;

location / {
        index  index.html index.php;
        try_files $uri $uri/ /index.php?$args;
    }

location ~ \.php$ {
        include fastcgi_params;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_path_info;
    }

# Deny access to hidden files and sensitive directories
    location ~ /\.(?!well-known).* {
        deny all;
    }

location ~ ^/tmp/runtime/ {
        deny  all;
    }
location ~* /(application|protected|modules|locale|framework|vendor|tests|docs|db|application/config)/ {
        deny all;
    }

# Disallow uploaded potential executable files in upload directory
location ~* /upload/.*\.(pl|cgi|py|pyc|pyo|phtml|sh|lua|php|php3|php4|php5|php6|pcgi|pcgi3|pcgi4|pcgi5|pcgi6|icn)$ {
        return 444;
    }

#Disallow direct read user upload files
location ~ ^/upload/surveys/.*/fu_[a-z0-9]*$ {
        return 444;
    }

location ~* \.(log|sql|htaccess)$ {
        deny all;
    }

# Allow LimeSurvey to serve uploaded files and assets
    location /upload/ {
        try_files $uri $uri/ =404;
    }
}

주요 지시어 설명

  • fastcgi_pass: PHP 요청을 처리하는 PHP-FPM 소켓 또는 TCP 주소를 지정합니다. 사용 중인 PHP-FPM 풀 구성에 맞게 수정하십시오.
  • try_files: URL이 LimeSurvey의 프런트 컨트롤러(index.php)를 통해 올바르게 라우팅되도록 합니다.
  • client_max_body_size: 최대 업로드 크기를 늘립니다. 파일 업로드 질문이 포함된 설문조사에 유용합니다.
  • 거부 규칙(Deny rules): 구성 파일, 로그, 애플리케이션 디렉터리 등 외부에 공개되어서는 안 되는 항목에 대한 직접적인 웹 접근을 차단합니다.