umap-project / umap

uMap lets you create maps with OpenStreetMap layers in a minute and embed them in your site.
https://umap-project.org
Other
1.19k stars 226 forks source link

404 on static files 0.3.x #30

Closed yohanboniface closed 9 years ago

yohanboniface commented 11 years ago

Originally reported by: Igor Támara (BitBucket: ikks, GitHub: ikks)


Hi, when I try running the site of series 0.3.x The admin finds the static files ok, but static files on the root throw 404

http://localhost:8000/static/darline/src/css/core.css (404)

I followed the instructions on the main page, and I'm on changeset a36ab981d28d85f3937c08dc1de2fe4e2791d81d , I have a postgis database and created a licence via the admin, I added a tile layer using

http://b.tile.cloudmade.com/8ee2a50541944fb9bcedded5165f09d9

As template, I'm unsure if it's ok, would I be able to use a mapbox one? If it's possible, what would be the way of doing it?

My local.py is:

from umap.settings.base import *   # pylint: disable=W0614,W0401

SECRET_KEY = 'my super hyper secret is safe'

DEBUG = True  # False in production
TEMPLATE_DEBUG = DEBUG

ADMINS = (
    ('You', 'your@email'),
)
MANAGERS = ADMINS

DATABASES = {
    'default': {
        'ENGINE': 'django.contrib.gis.db.backends.postgis',
        'NAME': 'umap',
        'HOST': 'localhost',
        'USER': 'django',
        'PASSWORD': 'django',
    }
}

WSGI_APPLICATION = 'umap.wsgi.application'

COMPRESS_ENABLED = False  #  True in production
COMPRESS_OFFLINE = True

LANGUAGE_CODE = 'en'
LANGUAGES = (
    ('en', 'English'),
    ('fr', u'Francais'),
    ('it', u'Italiano'),
    ('pt', u'Portuguese'),
    ('nl', u'Dutch'),
)

AUTHENTICATION_BACKENDS = (
    # 'social_auth.backends.contrib.github.GithubBackend',
    # 'social_auth.backends.contrib.bitbucket.BitbucketBackend',
    # 'social_auth.backends.twitter.TwitterBackend',
    # 'umap.osm_backend.OSMBackend',
    'django.contrib.auth.backends.ModelBackend',
)
GITHUB_APP_ID = 'xxx'
GITHUB_API_SECRET = 'xxx'
BITBUCKET_CONSUMER_KEY = 'xxx'
BITBUCKET_CONSUMER_SECRET = 'xxx'
# We need email to associate with other Oauth providers
GITHUB_AUTH_EXTRA_ARGUMENTS = {"scope": "user:email"}
TWITTER_CONSUMER_KEY = "xxx"
TWITTER_CONSUMER_SECRET = "xxx"
OSM_CONSUMER_KEY = 'xxx'
OSM_CONSUMER_SECRET = 'xxx'
UMAP_DEMO_PK = 34  # Pk of a Map instance
LEAFLET_STORAGE_ALLOW_ANONYMOUS = True
UMAP_DEMO_SITE = False

Would I be running 0.4 series? if so, how can I do it?


yohanboniface commented 11 years ago

Original comment by Yohan Boniface (BitBucket: yohanboniface, GitHub: yohanboniface):


Hi @ikks sorry for my late answer, I don't know why Bitbucket doesn't send me email notifications for new issues :/

Have you run "git submodule init" ?

yohanboniface commented 11 years ago

Original comment by Igor Támara (BitBucket: ikks, GitHub: ikks):


Hi @yohanboniface , yep I run it, I ended copying files to static, in the other hand, how is the syntax of the tile template? The map does not show any tile at all :( , should I be better jumping in 0.4.x series better to find things that maybe need some more docs so others can get in umap ? ;)

Is it ok to take latest? I would be happy writing docs for the project, is it ok if I work with sphinx on it?

yohanboniface commented 11 years ago

Original comment by Yohan Boniface (BitBucket: yohanboniface, GitHub: yohanboniface):


Of course, if you have time to work on a doc, it's awesome! And sphinx is perfect, indeed.

About the template URL, here is an example: http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png

You have some doc here: http://www.thunderforest.com/tutorials/tile-format/

BTW, at this time, I encourage you to switch to the 0.4, yes, to get the latest features.

yohanboniface commented 11 years ago

Original comment by Igor Támara (BitBucket: ikks, GitHub: ikks):


Hi, Thank you for the guidance :) , still on 0.4.x series I copied manually the static darline files. I havent' started with the documentation yet.

I tried

:::shell
  git submodule init
yohanboniface commented 11 years ago

Original comment by Yohan Boniface (BitBucket: yohanboniface, GitHub: yohanboniface):


humm, git submodule init should do the job, no need to do it by hand.

What the extact error you have, now?

yohanboniface commented 10 years ago

Original comment by Yohan Boniface (BitBucket: yohanboniface, GitHub: yohanboniface):


I guess I can close here.