1
votes

I am using ember-cli and everything is working using the default built in server. I need to deploy to tomcat under an application context.

In config/environment.js, I have set

baseURL: '/myapp/ember/',

I can navigate to http://localhost:8085/myap/ember/index.html and can see all the ember log messages but I get the following.

Error: Assertion Failed: Error: Assertion Failed: The URL '/index.html' did not match any routes in your application

If I go to http://localhost:8085/myap/ember/ I get a 404

If I go to http://localhost:8085/myap/ember/index.html#/ I get a 404

In ember inspector I can see the index route url is set to /myapp/ember/ but if I go to this url without specifying index.html I get a 404.

I seems that it thinks that index.html is a route for some reason. How do I fix this?

1
Did you ever find an answer to your question? You probably should post it and mark it accepted if so, so that future people with this problem can find the answer.ArtOfWarfare

1 Answers

2
votes

Turns out I had to set the locationType to 'hash' in config/environment.js

module.exports = function(environment) {
  var ENV = {
    environment: environment,
    baseURL: '/',
    locationType: 'hash', //auto
    EmberENV: {
      FEATURES: {
        // Here you can enable experimental features on an ember canary build
        // e.g. 'with-controller': true
      }
    },

   ...