在Ubuntu 14.04(Plesk Onyx 17.5)上配置自定义子域名的YouTrack独立版
Alright, let's wrap up your standalone YouTrack setup on that Ubuntu 14.04 server with Plesk Onyx 17.5. You've already handled the file upload, subdomain creation, and initial config command—nice progress! Here's the step-by-step to get it fully operational:
1. 完成YouTrack配置并启动服务
First, let's make sure the initial configuration finishes properly and the service starts:
- Run the start command from your YouTrack directory:
./youtrack.sh start - Verify the service is running with:
You should see a "running" status if everything went right. If you noticed the./youtrack.sh statusbase-urlin your earlier output showedhttpinstead ofhttps, don't worry—we'll fix that in a later step.
2. 配置Plesk反向代理(关键步骤)
Since YouTrack is listening on port 1111, you need to set up Plesk to route traffic from your https://board.domain.de subdomain to that port. Here's how:
- Log into your Plesk panel and navigate to the board.domain.de subdomain management page.
- Go to Apache & nginx Settings (this is the section for custom server directives in Plesk Onyx).
- Scroll down to Additional nginx directives and paste this configuration:
location / { proxy_pass http://localhost:1111; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; } - Save the changes—Plesk will automatically reload nginx to apply the new rules.
3. 修正Base URL(确保HTTPS正常工作)
Your initial config included https://board.domain.de:2222 as the base URL, but since Plesk handles HTTPS on port 443, we need to update this to the correct, portless HTTPS address:
- From your YouTrack directory, re-run the configure command:
./youtrack.sh configure --listen-port 1111 --base-url https://board.domain.de - Restart YouTrack to apply the new base URL:
./youtrack.sh restart
4. 验证访问并完成初始化
Now it's time to check if everything works:
- Open your browser and go to
https://board.domain.de—you should land on YouTrack's initial setup wizard. - Follow the wizard to create your admin account, set up your organization, and configure basic settings.
- Test the instance by creating a sample project and submitting a test issue to confirm all features are functional.
5. 设置开机自启(推荐)
To make sure YouTrack starts automatically if your server reboots, set up a systemd service:
- Create a new service file with sudo privileges:
sudo nano /etc/systemd/system/youtrack.service - Paste the following content, replacing placeholders with your actual user and YouTrack directory path:
[Unit] Description=JetBrains YouTrack Service After=network.target [Service] Type=forking User=your-ssh-username # 替换为上传YouTrack文件的系统用户 WorkingDirectory=/path/to/your/youtrack-folder # 替换为YouTrack解压后的目录 ExecStart=/path/to/your/youtrack-folder/youtrack.sh start ExecStop=/path/to/your/youtrack-folder/youtrack.sh stop Restart=always [Install] WantedBy=multi-user.target - Save and exit the editor (Ctrl+O, Enter, then Ctrl+X).
- Reload systemd and enable the service:
sudo systemctl daemon-reload sudo systemctl enable youtrack - Start the service with:
sudo systemctl start youtrack - You can verify it's running with
sudo systemctl status youtrack.
内容的提问来源于stack exchange,提问作者Brotzka

