접근
- Zipline URL을 여세요:
https://<SERVER-IP> - 설정 페이지로 리디렉션되며, 기본 최고 관리자 사용자 이름과 비밀번호를 구성할 수 있습니다.
중요한 파일 및 디렉토리
- 설치 경로:
/root/zipline - Compose 파일:
/root/zipline/docker-compose.yml - 환경 파일:
/root/zipline/.env - 업로드 디렉터리:
/root/zipline/uploads - 공개 파일:
/root/zipline/public - 테마 디렉터리:
/root/zipline/themes - PostgreSQL 볼륨:
/var/lib/docker/volumes/zipline_pgdata/_data - Nginx 설정:
/etc/nginx/sites-available/zipline.conf - SSL 인증서:
/etc/nginx/ssl/zipline.crt - SSL 개인 키:
/etc/nginx/ssl/zipline.key
Docker 관리
상태 보기:
cd /root/zipline
docker compose ps
로그 보기:
cd /root/zipline
docker compose logs -f
서비스 재시작:
cd /root/zipline
docker compose restart
서비스 중지:
cd /root/zipline
docker compose down
서비스 시작:
cd /root/zipline
docker compose up -d
NGINX 관리
테스트 구성:
nginx -t
NGINX 재시작:
systemctl restart nginx
NGINX 리로드:
systemctl reload nginx
NGINX 상태 확인:
systemctl status nginx
도메인으로 SSL 활성화
1. 도메인을 서버 IP로 지정하세요.
2. Certbot 설치:
apt install -y certbot python3-certbot-nginx
3. 다음 명령을 실행하여 유효한 Let's Encrypt 인증서를 생성합니다:
certbot certonly --nginx --non-interactive --agree-tos --email [email protected] -d yourdomain.com
4. Nginx 설정에서 SSL 경로 교체:
vim /etc/nginx/sites-available/zipline.conf
# Before:
# ssl_certificate /etc/nginx/ssl/zipline.crt;
# ssl_certificate_key /etc/nginx/ssl/zipline.key;
# After:
# ssl_certificate /etc/letsencrypt/live/yourdomain.com/fullchain.pem;
# ssl_certificate_key /etc/letsencrypt/live/yourdomain.com/privkey.pem;
5. Nginx 설정을 편집하여 두 곳의 server_name _; 도메인으로 (server_name <yourdomain.com>) HTTP (포트 80)와 HTTPS (포트 443) 블록 모두:
vim /etc/nginx/sites-available/zipline.conf
# Before:
server_name: _;
# After:
server_name: yourdomain.com;
6. 변경 사항을 적용하려면 Nginx를 다시 로드합니다:
systemctl reload nginx
7. 브라우저를 열고 방문: https://yourdomain.com
Zipline 업데이트
Zipline을 업데이트하려면 다음 명령만 실행하면 됩니다:
docker compose pull
docker compose up -d
이렇게 하면 최신 Zipline 이미지를 받아 서버를 재시작합니다.
참고
- Zipline은 HTTPS가 활성화된 Nginx 뒤에서 실행됩니다.
- 업로드된 파일 저장 위치:
/root/zipline/uploads. - 공개 자산 저장 위치:
/root/zipline/public. - 사용자 지정 테마 저장 위치:
/root/zipline/themes. - 데이터베이스 자격 증명과 애플리케이션 시크릿 저장 위치:
/root/zipline/.env.