在Jenkins文件夹中的任何地方找不到config.xml [英] Can't find config.xml anywhere within Jenkins folder

查看:3500
本文介绍了在Jenkins文件夹中的任何地方找不到config.xml的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在Windows 8上下载并安装了Tomcat servlet ...

其中存在许多应用程序的.war文件.还有詹金斯.我能够启动它并通过它创建作业和插件.但是在安装Maven时,我给高级->插件-> HTTP代理输入了错误的凭据.也许这是阻止我登录并发出消息的原因:管理员缺少总体/读取权限.

我在詹金斯(Jenkins)和许多其他网站上进行了搜索;嘿已经提到要遵循以下步骤...

  1. 停止Jenkins(最简单的方法是杀死servlet容器.)
  2. 转到文件系统中的$JENKINS_HOME并找到config.xml文件.
  3. 在编辑器中打开此文件.
  4. 在此文件中查找<useSecurity>true</useSecurity>元素,然后将true替换为false
  5. 删除元素authorizationStrategysecurityRealm.
  6. 开始詹金斯

但是我到处搜索以在Windows上找到config.xml,但是找不到.在哪里?

解决方案

默认情况下,Jenkins主目录(JENKINS_HOME)设置为~/.jenkins,这是您可以在其中找到Jenkins XML配置文件的位置.

在Windows上,您的用户主目录位于C:\Users\USERNAME下(等效于%HOME%).该文件夹可能是隐藏的(因为其中有点),因此在浏览文件时,请确保程序显示隐藏的文件,或在路径/地址栏中键入直接路径.

这是Jenkins主文件夹中XML文件的简要结构:

JENKINS_HOME
 +- config.xml     (jenkins root configuration)
 +- *.xml          (other site-wide configuration files)
 +- jobs
     +- [JOBNAME]      (sub directory for each job)
         +- config.xml     (job configuration file)

请参阅:管理Jenkins-JENKINS_HOME目录

I have downloaded and installed Tomcat servlet on my Windows 8...

Inside which many application's .war files are present. Also Jenkins. I was able to start it and create jobs and plugins through it. But I gave a wrong credentials for Advanced -> plugin -> HTTP Proxy while installing Maven. Maybe this is what is blocking me to login and gives message: Admin Is Missing the Overall/Read Permission.

I searched in Jenkins and many other sites; hey had mentioned to follow these steps...

  1. Stop Jenkins (the easiest way to do this is to kill the servlet container.)
  2. Go to $JENKINS_HOME in the file system and find config.xml file.
  3. Open this file in the editor.
  4. Look for the <useSecurity>true</useSecurity> element in this file and replace true with false
  5. Remove the elements authorizationStrategy and securityRealm.
  6. Start Jenkins

But I searched everywhere to find the config.xml on Windows, but I can't find it. Where it is?

解决方案

By default Jenkins home directory (JENKINS_HOME) is set to ~/.jenkins, this is the location where you can find your Jenkins XML config file.

On Windows your user home directory is under C:\Users\USERNAME (equivalent to %HOME%). This folder may be hidden (since it has dot in it), so when browsing the files, make sure your program shows hidden files or type the direct path in your Path/Address bar.

Here is the brief structure of XML files within Jenkins home folder:

JENKINS_HOME
 +- config.xml     (jenkins root configuration)
 +- *.xml          (other site-wide configuration files)
 +- jobs
     +- [JOBNAME]      (sub directory for each job)
         +- config.xml     (job configuration file)

See: Administering Jenkins - JENKINS_HOME directory

这篇关于在Jenkins文件夹中的任何地方找不到config.xml的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆