為什麼 gitolite 的預選會失敗?

為什麼 gitolite 的預選會失敗?

我正在 Debian Squeeze 盒子上安裝 gitolite,並使用以下預置:

gitolite        gitolite/gituser        string  git
gitolite        gitolite/adminkey       string  ssh-rsa AAAAB3ECT
gitolite        gitolite/gitdir         string  /var/lib/git

安裝時:

# debconf-set-selections /var/cache/debconf/gitolite.preseed
# apt-get install gitolite
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  git-daemon-run gitweb
The following NEW packages will be installed:
  gitolite
0 upgraded, 1 newly installed, 0 to remove and 26 not upgraded.
Need to get 0 B/114 kB of archives.
After this operation, 348 kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously deselected package gitolite.
(Reading database ... 24715 files and directories currently installed.)
Unpacking gitolite (from .../gitolite_1.5.4-2+squeeze1_all.deb) ...
Setting up gitolite (1.5.4-2+squeeze1) ...
adduser: The home dir must be an absolute path.
dpkg: error processing gitolite (--configure):
 subprocess installed post-installation script returned error exit status 1
configured to not write apport reports
                                      Errors were encountered while processing:
 gitolite
E: Sub-process /usr/bin/dpkg returned an error code (1)

為什麼?預種子是從手動配置的安裝中提取的,根據這裡並且在另一台機器上沒有問題地存在。

答案1

的格式debconf-set-selections應該是:

gitolite gitolite/gituser string  git

請注意,我只使用一個空白作為分隔符號。

來自 debconf-set-selections 的人:

所有其他行設定一個問題的值,並且應包含四個值,每個值由一個空格字符

相關內容