These are chat archives for spring-cloud/spring-cloud

29th
Jul 2015
Sergei Egorov
@bsideup
Jul 29 2015 09:05

Hi

I'm running Spring Cloud Eureka on Cloud Foundry, but it fails with:

Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardContext[]] ... Caused by: java.lang.NoSuchMethodError: javax.servlet.ServletContext.addFilter(Ljava/lang/String;Ljavax/servlet/Filter;)Ljavax/servlet/FilterRegistration$Dynamic;

Any ideas why?

Dave Syer
@dsyer
Jul 29 2015 09:19
Wrong version of Tomcat?
You have a dodgy servlet API jar in there anyway
Sergei Egorov
@bsideup
Jul 29 2015 09:22
hmm...... eureka.jar was created with "spring jar eureka.jar eureka.groovy"
Dave Syer
@dsyer
Jul 29 2015 09:24
What do you get from spring version?
And what do you have in $SPRING_HOME/lib?
Sergei Egorov
@bsideup
Jul 29 2015 09:25
it was 1.2.3, I will try to update to the latest and re-assemble jar
Dave Syer
@dsyer
Jul 29 2015 09:26
Spring cloud cli 1.0.3?
Sergei Egorov
@bsideup
Jul 29 2015 09:28

Now - yes :)

Ok, update to Spring CLI 1.2.5 and Cloud CLI 1.0.3 solved this issue

Dave Syer
@dsyer
Jul 29 2015 09:29
Good
Sergei Egorov
@bsideup
Jul 29 2015 14:40

Can't connect Spring Cloud config with private GitHub repository and 2F auth. I use link like:

https://user:TOKEN@github.com/org/repo.git

Is it supported?

Dave Syer
@dsyer
Jul 29 2015 14:41
2F obviously not - you need a user interface don't you?
Sergei Egorov
@bsideup
Jul 29 2015 14:42
No. GitHub allows you to generate tokens and you can use them instead of passwords
so local "git clone" works with such URL
Dave Syer
@dsyer
Jul 29 2015 14:43
It's not really "2 factor" then is it?
As far as I know that works
It's JGit
So look at what is supported there
Sergei Egorov
@bsideup
Jul 29 2015 14:47

http://www.codeaffine.com/2014/12/09/jgit-authentication/

Please note one thing if you are accessing a GitHub repository through HTTPS with an OAuth access token. The token does not need to be specified in the URL but only given as a user name.

Can we support it?
Unfortunately Spring Cloud Config Broker on Cloud Foundry is not supporting key-based auth :(
Dave Syer
@dsyer
Jul 29 2015 14:50
You have to ask the team that built it.
I think they do support authentication.
It would have to be set up as part of the installation though
Sergei Egorov
@bsideup
Jul 29 2015 14:51
about support - I meant support in Spring Cloud Config Server.
Looks like small change is required to make SCCS work with GitHub + Oauth tokens
Dave Syer
@dsyer
Jul 29 2015 14:52
If you deploy the config server yourself I expect you can configure the URL?
Sergei Egorov
@bsideup
Jul 29 2015 14:52
@dsyer ok, forget about CF. Clean Spring Cloud Config Server. Git repository. Support for OAuth token like it's described in article above :)
Dave Syer
@dsyer
Jul 29 2015 14:53
There's a username and password in the config properties
I expect it works
Sergei Egorov
@bsideup
Jul 29 2015 14:54
ok, I will try it