title: Problem running basic Spring Boot application
body: <p>I have been working through an introductory <a href="https://spring.io/guides/gs/spring-boot/#scratch" rel="nofollow noreferrer">Spring Boot tutorial</a>.</p>
  
  <p>I have gotten as far as running</p>
  
  <p><code>./mvnw spring-boot:run</code></p>
  
  <p>From the project directory.</p>
  
  <p>Which generates the output:</p>
  
  <pre><code>Let's inspect the beans provided by Spring Boot:
  application
  beanNameHandlerMapping
  defaultServletHandlerMapping
  dispatcherServlet
  embeddedServletContainerCustomizerBeanPostProcessor
  handlerExceptionResolver
  helloController
  httpRequestHandlerAdapter
  messageSource
  mvcContentNegotiationManager
  mvcConversionService
  mvcValidator
  org.springframework.boot.autoconfigure.MessageSourceAutoConfiguration
  org.springframework.boot.autoconfigure.PropertyPlaceholderAutoConfiguration
  org.springframework.boot.autoconfigure.web.EmbeddedServletContainerAutoConfiguration
  org.springframework.boot.autoconfigure.web.EmbeddedServletContainerAutoConfiguration$DispatcherServletConfiguration
  org.springframework.boot.autoconfigure.web.EmbeddedServletContainerAutoConfiguration$EmbeddedTomcat
  org.springframework.boot.autoconfigure.web.ServerPropertiesAutoConfiguration
  org.springframework.boot.context.embedded.properties.ServerProperties
  org.springframework.context.annotation.ConfigurationClassPostProcessor.enhancedConfigurationProcessor
  org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor
  org.springframework.context.annotation.internalAutowiredAnnotationProcessor
  org.springframework.context.annotation.internalCommonAnnotationProcessor
  org.springframework.context.annotation.internalConfigurationAnnotationProcessor
  org.springframework.context.annotation.internalRequiredAnnotationProcessor
  org.springframework.web.servlet.config.annotation.DelegatingWebMvcConfiguration
  propertySourcesBinder
  propertySourcesPlaceholderConfigurer
  requestMappingHandlerAdapter
  requestMappingHandlerMapping
  resourceHandlerMapping
  simpleControllerHandlerAdapter
  tomcatEmbeddedServletContainerFactory
  viewControllerHandlerMapping
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD SUCCESS
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time:  4.530 s
  [INFO] Finished at: 2020-01-18T14:29:53-04:00
  [INFO] ------------------------------------------------------------------------
  </code></pre>
  
  <p>But when I run <code>$ curl localhost:8080</code>
  from a seperate terminal window
  instead of the expected:</p>
  
  <p><code>Greetings from Spring Boot!</code></p>
  
  <p>I get:
  <code>curl: (7) Failed to connect to localhost port 8080: Connection refused</code></p>
  
  <p>Here is my pom.xml file:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
      &lt;parent&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
          &lt;version&gt;2.2.3.RELEASE&lt;/version&gt;
          &lt;relativePath/&gt; &lt;!-- lookup parent from repository --&gt;
      &lt;/parent&gt;
      &lt;groupId&gt;com.example&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot&lt;/artifactId&gt;
      &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
      &lt;name&gt;spring-boot&lt;/name&gt;
      &lt;description&gt;Demo project for Spring Boot&lt;/description&gt;
  
      &lt;properties&gt;
          &lt;java.version&gt;1.8&lt;/java.version&gt;
      &lt;/properties&gt;
  
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-webmvc&lt;/artifactId&gt;
              &lt;version&gt;4.1.6.RELEASE&lt;/version&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-test&lt;/artifactId&gt;
              &lt;scope&gt;test&lt;/scope&gt;
              &lt;exclusions&gt;
                  &lt;exclusion&gt;
                      &lt;groupId&gt;org.junit.vintage&lt;/groupId&gt;
                      &lt;artifactId&gt;junit-vintage-engine&lt;/artifactId&gt;
                  &lt;/exclusion&gt;
              &lt;/exclusions&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-actuator&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
  
      &lt;/dependencies&gt;
  
  
  
      &lt;build&gt;
          &lt;plugins&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                  &lt;artifactId&gt;spring-boot-maven-plugin&lt;/artifactId&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/build&gt;
  
  &lt;/project&gt;
  </code></pre>
  
  <p>Any help or insight would be greatly appreacted. </p>
  
  <p>Thank you</p>