<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet href="https://v1sta.xyz/wp-content/plugins/pretty-rss-feeds/xslt/pretty-feed.xsl" type="text/xsl" media="screen" ?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:media="http://search.yahoo.com/mrss/">

<channel>
	<title>2023年5月5日 &#8211; 景の域</title>
	<atom:link href="https://v1sta.xyz/2023/05/05/feed/" rel="self" type="application/rss+xml" />
	<link>https://v1sta.xyz</link>
	<description>远景的幻想空间</description>
	<lastBuildDate>Sat, 04 Apr 2026 03:54:45 +0000</lastBuildDate>
	<language>zh-Hans</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.2</generator>

<image>
	<url>https://v1sta.xyz/wp-content/uploads/2026/03/V1sta-Orb-Output512-2-60x60.png</url>
	<title>2023年5月5日 &#8211; 景の域</title>
	<link>https://v1sta.xyz</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Proxmox VE仪表盘更换主题</title>
		<link>https://v1sta.xyz/tech/proxmox-theme/</link>
					<comments>https://v1sta.xyz/tech/proxmox-theme/#respond</comments>
		
		<dc:creator><![CDATA[域主 V1STA]]></dc:creator>
		<pubDate>Thu, 04 May 2023 18:49:29 +0000</pubDate>
				<category><![CDATA[技术]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[PVE]]></category>
		<guid isPermaLink="false">https://v1sta.xyz/?p=980</guid>

					<description><![CDATA[PVE用了很长时间了，但感觉默认的界面稍显枯燥了些。 其实PVE 7.4版就添加了暗色模式。后来发现可以更换官 &#8230; <a href="https://v1sta.xyz/tech/proxmox-theme/" class="more-link">继续阅读<span class="screen-reader-text">Proxmox VE仪表盘更换主题</span> <span class="meta-nav">&#8594;</span></a>]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">PVE用了很长时间了，但感觉默认的界面稍显枯燥了些。</p>



<p class="wp-block-paragraph">其实PVE 7.4版就添加了暗色模式。后来发现可以更换官方的其他主题，换换心情无妨。</p>



<span id="more-980"></span>



<h2 class="wp-block-heading">前言</h2>



<p class="wp-block-paragraph">本文基本参考了 Lunar Computer 的 Change the Theme of Proxmox VE</p>



<figure class="wp-block-mamaduka-bookmark-card is-style-horizontal"><a class="bookmark-card" href="https://lunar.computer/posts/themes-proxmox"><div class="bookmark-card__image"><img decoding="async" src="https://lunar.computer/img/theme-neptune.png"/></div><div class="bookmark-card__content"><div class="bookmark-card__title">Change the Theme of Proxmox VE :: LUNAR COMPUTER — Tech Blog and Tutorials</div><div class="bookmark-card__description">In this tutorial we’ll change the theme of Proxmox VE 6.0. There are six themes you can choose from (in the image below from top left to bottom right):
 theme-aria theme-classic theme-crisp (default theme) theme-gray theme-neptune theme-triton  Prepare Make sure you have a server running Proxmox VE 6.0. Then, make sure you have followed the steps in our previous article on how to make customizations to Proxmox VE 6.</div><div class="bookmark_card__meta"><img decoding="async" class="bookmark_card__meta-icon" src="https://lunar.computer/favicon.ico"/><span class="bookmark_card__meta-publisher">lunar.computer</span></div></div></a></figure>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph">PVE的主题是使用extjs框架构建的（也是NAS系统OMV5以前的界面框架），理论上可用大部分extjs</p>



<p class="wp-block-paragraph">但是经过我的测试，明确可用的只有以下六个主题，分别是：</p>



<ul class="wp-block-list">
<li><code>theme-aria</code></li>



<li><code>theme-classic</code></li>



<li><code>theme-crisp</code>（默认主题）</li>



<li><code>theme-gray</code></li>



<li><code>theme-neptune</code></li>



<li><code>theme-triton</code></li>
</ul>



<figure class="wp-block-image size-large"><a href="https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes.png" data-lbwps-width="3072" data-lbwps-height="1536" data-lbwps-srcsmall="https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-300x150.png"><img fetchpriority="high" decoding="async" width="1024" height="512" sizes="(max-width: 1024px) 100vw, 1024px" src="https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-1024x512.png" alt="" class="wp-image-987" srcset="https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-1024x512.png 1024w, https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-300x150.png 300w, https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-768x384.png 768w, https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-1536x768.png 1536w, https://v1sta.xyz/wp-content/uploads/2023/05/proxmox-themes-2048x1024.png 2048w" /></a></figure>



<p class="wp-block-paragraph">crisp是PVE的默认主题，和aria、neptune以及triton都是现代矢量化主题；classic和gray则是包含位图资源的经典主题（在高分屏下控件会部分模糊）。</p>



<p class="wp-block-paragraph">此外Neptune有大间距的触屏版本，另外还有一些共用名称前缀、但实际不可用的子主题；主题也可以和PVE的官方暗色模式共存，但只有现代矢量化的主题效果最好。</p>



<hr class="wp-block-separator has-alpha-channel-opacity"/>



<h2 class="wp-block-heading">步骤</h2>



<p class="wp-block-paragraph">首先打开终端，安装git，大部分情况下PVE默认是没有内置的，要使用apt安装：</p>



<pre class="wp-block-code"><code>apt install -y git</code></pre>



<p class="wp-block-paragraph">然后建立目录以拉取主题仓库，目录的位置可随意（以下以custom目录为例），但是需要记住目录的路径，在下文的脚本文件配置中会用到</p>



<pre class="wp-block-code"><code>mkdir /usr/share/custom/ &amp;&amp; cd /usr/share/custom/</code></pre>



<p class="wp-block-paragraph">使用git拉取主题仓库：</p>



<pre class="wp-block-code"><code>git clone git://git.proxmox.com/git/extjs.git</code></pre>



<p class="wp-block-paragraph">在上述建立的custom目录中创建 apply.sh 作为生效用的脚本文件，并通过echo输出命令：拷贝custom下extjs目录文件到pve的资源目录</p>



<pre class="wp-block-code"><code>touch /usr/share/custom/apply.sh
echo "cp -vrf /usr/share/custom/extjs/extjs/build/classic/{theme-aria,theme-classic-sandbox,theme-classic,theme-gray,theme-neptune-touch,theme-neptune,theme-neutral,theme-triton} /usr/share/javascript/extjs/" &gt;&gt; /usr/share/custom/apply.sh</code></pre>



<p class="wp-block-paragraph">并且使用正则替换 <code>/usr/share/pve-manager/index.html.tpl</code> 的主题名称（其中 <code>theme-crisp</code> 是默认/当前的主题，<code>theme-triton</code> 是想要换成的目标主题）</p>



<pre class="wp-block-code"><code>echo "sed -i.bak \"s/theme-crisp/theme-triton/g\" /usr/share/pve-manager/index.html.tpl" &gt;&gt; /usr/share/custom/apply.sh</code></pre>



<p class="wp-block-paragraph">（实际就是一行css link，需要改的地方也就两处，改错了完全可以开SCP用记事本修改html模板文件）</p>



<p class="wp-block-paragraph">最后用bash运行apply.sh</p>



<pre class="wp-block-code"><code>bash ./apply.sh</code></pre>



<h2 class="wp-block-heading">效果</h2>



<p class="wp-block-paragraph">默认的PVE界面：</p>



<figure class="wp-block-image size-large"><a href="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA.png" data-lbwps-width="1280" data-lbwps-height="689" data-lbwps-srcsmall="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA-300x161.png"><img decoding="async" width="1024" height="551" sizes="(max-width: 1024px) 100vw, 1024px" src="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA-1024x551.png" alt="" class="wp-image-984" srcset="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA-1024x551.png 1024w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA-300x161.png 300w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA-768x413.png 768w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_Zh32XXsSZA.png 1280w" /></a><figcaption class="wp-element-caption">生效前</figcaption></figure>



<p class="wp-block-paragraph">如果不出意外的话，打开web仪表盘后台会立即生效：</p>



<figure class="wp-block-image size-large"><a href="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn.png" data-lbwps-width="1280" data-lbwps-height="689" data-lbwps-srcsmall="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn-300x161.png"><img decoding="async" width="1024" height="551" sizes="(max-width: 1024px) 100vw, 1024px" src="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn-1024x551.png" alt="" class="wp-image-983" srcset="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn-1024x551.png 1024w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn-300x161.png 300w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn-768x413.png 768w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn.png 1280w" /></a><figcaption class="wp-element-caption">生效后</figcaption></figure>



<p class="wp-block-paragraph">或者面临的是完全没加载CSS的错误样式</p>



<figure class="wp-block-image size-large"><a href="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9.png" data-lbwps-width="1280" data-lbwps-height="689" data-lbwps-srcsmall="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9-300x161.png"><img loading="lazy" decoding="async" width="1024" height="551" sizes="auto, (max-width: 1024px) 100vw, 1024px" src="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9-1024x551.png" alt="" class="wp-image-981" srcset="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9-1024x551.png 1024w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9-300x161.png 300w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9-768x413.png 768w, https://v1sta.xyz/wp-content/uploads/2023/05/chrome_0ZG9hzO8M9.png 1280w" /></a><figcaption class="wp-element-caption">一个典型的错误例子</figcaption></figure>



<p class="wp-block-paragraph">如果出现没有加载CSS的错误，其实按照之前所说的，只要编辑 <code>/usr/share/pve-manager/index.html.tpl</code> 模板文件找到css link的那行就可以修复了，在目录下还有一个备份的bak文件可以复原么。</p>

<p><a href="https://v1sta.xyz/tech/proxmox-theme/" rel="nofollow">来源</a></p>]]></content:encoded>
					
					<wfw:commentRss>https://v1sta.xyz/tech/proxmox-theme/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<enclosure url="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn.png" length="68542" type="image/png"/><media:content url="https://v1sta.xyz/wp-content/uploads/2023/05/chrome_ZcZXqphpBn.png" width="1280" height="689" medium="image" type="image/png"/>	</item>
	</channel>
</rss>
