Problem while trying to run shinyproxy on Linux 2018.03 instance

Hey guys,

I tried to follow your amazing guide to get started with shinyproxy (https://www.shinyproxy.io/getting-started/).
I’m using an amazon Linux 2018.03 instance. I installed java first and my java version is:
openjdk version "1.8.0_222" OpenJDK Runtime Environment (build 1.8.0_222-b10) OpenJDK 64-Bit Server VM (build 25.222-b10, mixed mode)

And then we installed the docker by running sudo install docker and sudo service docker status returns docker (pid 2890) is running.... But on Amazon Linux server there is no /etc/systemd folder, so I can’t change the ExecStart= part.

And if I pull your demo image using sudo docker pull openanalytics/shinyproxy-demo and run java -jar shinyproxy-2.3.0.jar (where your default application.yml file is in the same folder, the only thing I changed was the port, from 8080 to 2555), this is the output on the console:

:: Spring Boot :: (v2.0.0.RELEASE)

2019-11-08 01:15:14.264  INFO 4539 --- [           main] e.o.c.ContainerProxyApplication          : Starting ContainerProxyApplication v0.8.3 on ip-10-0-0-32 with PID 4539 (/home/ec2-user/shinyproxy-2.3.0.jar started by root in /home/ec2-user)
2019-11-08 01:15:14.268  INFO 4539 --- [           main] e.o.c.ContainerProxyApplication          : No active profile set, falling back to default profiles: default
2019-11-08 01:15:14.319  INFO 4539 --- [           main] ConfigServletWebServerApplicationContext : Refreshing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@69d9c55: startup date [Fri Nov 08 01:15:14 UTC 2019]; root of context hierarchy
2019-11-08 01:15:15.346  INFO 4539 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2019-11-08 01:15:16.230  INFO 4539 --- [           main] org.xnio                                 : XNIO version 3.3.8.Final
2019-11-08 01:15:16.247  INFO 4539 --- [           main] org.xnio.nio                             : XNIO NIO Implementation Version 3.3.8.Final
2019-11-08 01:15:16.391  WARN 4539 --- [           main] io.undertow.websockets.jsr               : UT026009: XNIO worker was not set on WebSocketDeploymentInfo, the default worker will be used
2019-11-08 01:15:16.391  WARN 4539 --- [           main] io.undertow.websockets.jsr               : UT026010: Buffer pool was not set on WebSocketDeploymentInfo, the default pool will be used
2019-11-08 01:15:16.418  INFO 4539 --- [           main] io.undertow.servlet                      : Initializing Spring embedded WebApplicationContext
2019-11-08 01:15:16.418  INFO 4539 --- [           main] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 2099 ms
2019-11-08 01:15:16.582  INFO 4539 --- [           main] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'characterEncodingFilter' to: [/*]
2019-11-08 01:15:16.583  INFO 4539 --- [           main] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'requestContextFilter' to: [/*]
2019-11-08 01:15:16.584  INFO 4539 --- [           main] .s.DelegatingFilterProxyRegistrationBean : Mapping filter: 'springSecurityFilterChain' to: [/*]
2019-11-08 01:15:16.584  INFO 4539 --- [           main] o.s.boot.web.servlet.RegistrationBean    : Filter orderedHiddenHttpMethodFilter was not registered (disabled)
2019-11-08 01:15:16.584  INFO 4539 --- [           main] o.s.boot.web.servlet.RegistrationBean    : Filter orderedHttpPutFormContentFilter was not registered (disabled)
2019-11-08 01:15:16.584  INFO 4539 --- [           main] o.s.b.w.servlet.ServletRegistrationBean  : Servlet dispatcherServlet mapped to [/]
2019-11-08 01:15:16.839  INFO 4539 --- [           main] e.o.c.stat.StatCollectorRegistry         : Disabled. Usage statistics will not be processed.
2019-11-08 01:15:17.067  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/css/**'], []
2019-11-08 01:15:17.068  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/img/**'], []
2019-11-08 01:15:17.068  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/js/**'], []
2019-11-08 01:15:17.068  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/assets/**'], []
2019-11-08 01:15:17.068  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/webjars/**'], []
2019-11-08 01:15:17.204  INFO 4539 --- [           main] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: org.springframework.security.web.util.matcher.AnyRequestMatcher@1, [org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter@1530c739, org.springframework.security.web.context.SecurityContextPersistenceFilter@368247b9, org.springframework.security.web.header.HeaderWriterFilter@6c1a5b54, org.springframework.security.web.authentication.logout.LogoutFilter@63376bed, org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter@6e6f2380, org.springframework.security.web.authentication.www.BasicAuthenticationFilter@5b1669c0, org.springframework.security.web.savedrequest.RequestCacheAwareFilter@1a942c18, org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter@738dc9b, org.springframework.security.web.authentication.AnonymousAuthenticationFilter@78e4deb0, org.springframework.security.web.session.SessionManagementFilter@60099951, org.springframework.security.web.access.ExceptionTranslationFilter@45099dd3, org.springframework.security.web.access.intercept.FilterSecurityInterceptor@7526515b]
2019-11-08 01:15:17.247  WARN 4539 --- [           main] org.thymeleaf.templatemode.TemplateMode  : [THYMELEAF][main] Template Mode 'HTML5' is deprecated. Using Template Mode 'HTML' instead.
2019-11-08 01:15:17.628  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@69d9c55: startup date [Fri Nov 08 01:15:14 UTC 2019]; root of context hierarchy
2019-11-08 01:15:17.711  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/app/*],methods=[GET]}" onto public java.lang.String eu.openanalytics.shinyproxy.controllers.AppController.app(org.springframework.ui.ModelMap,javax.servlet.http.HttpServletRequest)
2019-11-08 01:15:17.713  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/app_direct/**]}" onto public void eu.openanalytics.shinyproxy.controllers.AppController.appDirect(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2019-11-08 01:15:17.713  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/app/*],methods=[POST]}" onto public java.util.Map<java.lang.String, java.lang.String> eu.openanalytics.shinyproxy.controllers.AppController.startApp(javax.servlet.http.HttpServletRequest)
2019-11-08 01:15:17.714  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/issue],methods=[POST]}" onto public java.lang.String eu.openanalytics.shinyproxy.controllers.IssueController.postIssue(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2019-11-08 01:15:17.715  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/admin]}" onto private java.lang.String eu.openanalytics.shinyproxy.controllers.AdminController.admin(org.springframework.ui.ModelMap,javax.servlet.http.HttpServletRequest)
2019-11-08 01:15:17.715  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/]}" onto private java.lang.Object eu.openanalytics.shinyproxy.controllers.IndexController.index(org.springframework.ui.ModelMap,javax.servlet.http.HttpServletRequest)
2019-11-08 01:15:17.717  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxy/{proxyId}],methods=[GET],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<eu.openanalytics.containerproxy.model.runtime.Proxy> eu.openanalytics.containerproxy.api.ProxyController.getProxy(java.lang.String)
2019-11-08 01:15:17.717  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxyspec],methods=[GET],produces=[application/json]}" onto public java.util.List<eu.openanalytics.containerproxy.model.spec.ProxySpec> eu.openanalytics.containerproxy.api.ProxyController.listProxySpecs()
2019-11-08 01:15:17.718  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxy],methods=[GET],produces=[application/json]}" onto public java.util.List<eu.openanalytics.containerproxy.model.runtime.Proxy> eu.openanalytics.containerproxy.api.ProxyController.listProxies()
2019-11-08 01:15:17.718  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxy/{proxyId}],methods=[DELETE],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<java.lang.String> eu.openanalytics.containerproxy.api.ProxyController.stopProxy(java.lang.String)
2019-11-08 01:15:17.719  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxyspec/{proxySpecId}],methods=[GET],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<eu.openanalytics.containerproxy.model.spec.ProxySpec> eu.openanalytics.containerproxy.api.ProxyController.getProxySpec(java.lang.String)
2019-11-08 01:15:17.719  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxy],methods=[POST],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<eu.openanalytics.containerproxy.model.runtime.Proxy> eu.openanalytics.containerproxy.api.ProxyController.startProxy(eu.openanalytics.containerproxy.model.spec.ProxySpec)
2019-11-08 01:15:17.720  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/proxy/{proxySpecId}],methods=[POST],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<eu.openanalytics.containerproxy.model.runtime.Proxy> eu.openanalytics.containerproxy.api.ProxyController.startProxy(java.lang.String,java.util.Set<eu.openanalytics.containerproxy.model.runtime.RuntimeSetting>)
2019-11-08 01:15:17.721  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/login],methods=[GET]}" onto public java.lang.Object eu.openanalytics.containerproxy.ui.LoginController.getLoginPage(java.util.Optional<java.lang.String>,org.springframework.ui.ModelMap,javax.servlet.http.HttpServletRequest)
2019-11-08 01:15:17.721  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/api/route/**]}" onto public void eu.openanalytics.containerproxy.api.ProxyRouteController.route(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2019-11-08 01:15:17.725  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],consumes=[application/json],produces=[application/json]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> eu.openanalytics.containerproxy.ui.ErrorController.error(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2019-11-08 01:15:17.725  INFO 4539 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public java.lang.String eu.openanalytics.containerproxy.ui.ErrorController.handleError(org.springframework.ui.ModelMap,javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2019-11-08 01:15:17.780  INFO 4539 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/assets/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2019-11-08 01:15:17.781  INFO 4539 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2019-11-08 01:15:17.781  INFO 4539 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2019-11-08 01:15:17.800  INFO 4539 --- [           main] .m.m.a.ExceptionHandlerExceptionResolver : Detected @ExceptionHandler methods in baseController.RestErrorHandler
2019-11-08 01:15:17.834  INFO 4539 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2019-11-08 01:15:17.951  INFO 4539 --- [           main] o.s.b.a.w.s.WelcomePageHandlerMapping    : Adding welcome page template: index
2019-11-08 01:15:18.059  INFO 4539 --- [           main] o.s.l.c.support.AbstractContextSource    : Property 'userDn' not set - anonymous context will be used for read-write operations
2019-11-08 01:15:18.230  INFO 4539 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Registering beans for JMX exposure on startup
2019-11-08 01:15:18.232  INFO 4539 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Bean with name 'dataSource' has been autodetected for JMX exposure
2019-11-08 01:15:18.237  INFO 4539 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Located MBean 'dataSource': registering with JMX server as MBean [com.zaxxer.hikari:name=dataSource,type=HikariDataSource]
2019-11-08 01:15:18.304  INFO 4539 --- [           main] o.s.b.w.e.u.UndertowServletWebServer     : Undertow started on port(s) 2555 (http) with context path ''
2019-11-08 01:15:18.307  INFO 4539 --- [           main] e.o.c.ContainerProxyApplication          : Started ContainerProxyApplication in 4.563 seconds (JVM running for 5.189)
^C2019-11-08 01:17:05.024  INFO 4539 --- [       Thread-2] ConfigServletWebServerApplicationContext : Closing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@69d9c55: startup date [Fri Nov 08 01:15:14 UTC 2019]; root of context hierarchy
2019-11-08 01:17:05.027  INFO 4539 --- [       Thread-2] o.s.j.e.a.AnnotationMBeanExporter        : Unregistering JMX-exposed beans on shutdown
2019-11-08 01:17:05.027  INFO 4539 --- [       Thread-2] o.s.j.e.a.AnnotationMBeanExporter        : Unregistering JMX-exposed beans

And I can’t access the shiny proxy by typing my server_IP:2555 in my browser (the port 2555 is open in my security group).

EDIT: I think I found the docker config file in /etc/sysconfig/docker and the content there is:

# The max number of open files for the daemon itself, and all
# running containers.  The default value of 1048576 mirrors the value
# used by the systemd service unit.
DAEMON_MAXFILES=1048576

# Additional startup options for the Docker daemon, for example:
# OPTIONS="--ip-forward=true --iptables=true"
# By default we limit the number of open files per container
OPTIONS="--default-ulimit nofile=1024:4096"

# How many seconds the sysvinit script waits for the pidfile to appear
# when starting the daemon.
DAEMON_PIDFILE_TIMEOUT=10

Thanks in advance,
Silvano