【问题标题】:Grails 2.3.6 Missing Repo IssueGrails 2.3.6 缺少回购问题
【发布时间】:2014-07-24 15:40:34
【问题描述】:

我的 Grails (2.3.6) 应用程序的BuildConfig.groovy

grails {
    project {
        dependency {
            resolution = {
                repositories {
                    inherits true

                    grailsHome()
                    mavenLocal()
                    mavenRepo "http://myartifactory01/myrepo"
                    grailsPlugins()
                    grailsCentral()
                    mavenCentral()
                }
                plugins {
                    compile ":myplugin:0.1"
                }
            }
        }
    }

    server {
        port {
            http = 4384
        }
    }
}

当我运行run-app 时,出现以下错误:

| Error Required Grails build dependencies were not found. This is normally
due to internet connectivity issues (such as a misconfigured proxy) or missing
repositories in grails-app/conf/BuildConfig.groovy. Please verify your
configuration to continue.

我已验证 URL 指向一个有效的(Artifactory)maven 存储库,其中存储了 myplugin 插件。我的BuildConfig 有问题吗?它是否缺少任何属性,或者是否有任何配置错误?

【问题讨论】:

标签: maven grails artifactory buildconfiguration


【解决方案1】:

自从使用 Maven 依赖解析器后,我需要在 grailsPlugins 之前添加我的 mavenRepo:

repositories {
    inherits true // Whether to inherit repository definitions from plugins

    //mavenRepo "http://myrepo:8081/artifactory/plugins-snapshot-local"
    mavenRepo "http://myrepo:8081/artifactory/plugins-release-local"

    grailsPlugins()
    grailsHome()
    mavenLocal()
    grailsCentral()
    mavenCentral()

    // uncomment these (or add new ones) to enable remote dependency resolution from public Maven repositories
    //mavenRepo "http://repository.codehaus.org"
    //mavenRepo "http://download.java.net/maven/2/"
    //mavenRepo "http://repository.jboss.com/maven2/"
}

【讨论】:

    【解决方案2】:

    由于某种原因需要添加build ":release:3.0.1"作为插件,我不喜欢Grails。

    【讨论】:

      猜你喜欢
      • 2016-10-16
      • 1970-01-01
      • 1970-01-01
      • 2011-06-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多