Comments (18)
This problem is extremely infuriating. No matter what I do, I cannot make carto use http
instead of https
.
from cartodb.
Can't figure it out. I resorted to a global s/https/http search-replace but that obviously broke just about everything. Help! I'd love to start work on Carto but this is a huge blocker right now... Thanks
from cartodb.
Set up on CartoDB on another machine (Ubuntu 12.04 fresh install) and having the same issue. Does anyone have any ideas for a fix?
from cartodb.
i had to change some of the map.js functions to force them to use http
from cartodb.
I tried messing in there as well but I always ended up breaking other things. Do you know specifically what you changed?
And I'm just as interested as to why the tile_protocol
property as no effect. Seems like a bug.
from cartodb.
i know, it a pain in the ass, but i changed lib/assets/javascripts/cdb/src/geo/common.js and added
opts.tiler_protocol= "http"; after line55
https://github.com/CartoDB/cartodb.js/blob/develop/src/geo/common.js#L55 and also changed line 128 to return http
from cartodb.
Ok thanks, I'll try that. Do you know where opts.tiler_protocol
is set initially?
from cartodb.
Ok I was able to make it work by hacking common.js. Thanks for the tip.
Now of course, I ran into another ignoring-my-configuration issue...
from cartodb.
This also worked for me. Thanks!
from cartodb.
we internally work with http for development is as easy as change the configuration in config/app_config.yml
from cartodb.
Look at the other comments! Changing app_config does NOT work!
from cartodb.
@tkwebb this is my app_config.yml, to develop I use a checkout of cartodb code without any modification (i've removed some keys). Once you have it in config folder, restart the app (the rails app and the importer) and create/import a new table
defaults: &defaults
debug_assets: true
mandatory_keys: [layer_opts, tile_host, tile_port, sql_api_domain, sql_api_endpoint, sql_api_port, varnish_management, redis]
session_domain: '.localhost.lan'
secret_token: 'XXXXXXXXXX'
account_host: 'localhost:3000'
account_path: '/account'
tile_protocol: 'http'
tile_host: 'localhost.lan'
tile_port: '8181'
sql_api_protocol: 'http'
sql_api_domain: 'localhost.lan'
sql_api_endpoint: '/api/v1/sql'
sql_api_port: 8080
api_requests_service_url: ''
developers_host: 'http://developers.localhost.lan:3000'
varnish_management:
critical: true
host: '127.0.0.1'
port: 6082
purge_command: 'url.purge'
retries: 5
timeout: 5
redis:
host: '127.0.0.1'
port: 6379
superadmin:
username: "superadmin"
password: "asdasd"
layer_opts:
public_opts: ["type", "active", "query", "opacity", "auto_bound",
"interactivity", "debug", "visible", "tiler_domain",
"tiler_port", "tiler_protocol", "sql_domain", "sql_port",
"sql_protocol", "extra_params", "cdn_url", "table_name",
"user_name", "style_version"]
default_tile_styles:
point: "{\n marker-fill: #FF6600;\n marker-opacity: 0.9;\n marker-width: 12;\n marker-line-color: white;\n marker-line-width: 3;\n marker-line-opacity: 0.9;\n marker-placement: point;\n marker-type: ellipse;\n marker-allow-overlap: true;\n}"
geometry: "{\n // points\n [mapnik-geometry-type=1] {\n marker-fill: #FF6600;\n marker-opacity: 1;\n marker-width: 16;\n marker-line-color: white;\n marker-line-width: 3;\n marker-line-opacity: 0.9;\n marker-placement: point;\n marker-type: ellipse;marker-allow-overlap: true;\n }\n\n //lines\n [mapnik-geometry-type=2] {\n line-color:#FF6600; \n line-width:1; \n line-opacity: 0.7;\n }\n\n //polygons\n [mapnik-geometry-type=3] {\n polygon-fill:#FF6600;\n polygon-opacity: 0.7;\n line-opacity:1;\n line-color: #FFFFFF;\n }\n }"
polygon: "{\n polygon-fill:#FF6600;\n polygon-opacity: 0.7;\n line-opacity:1;\n line-color: #FFFFFF;\n}"
multipolygon: "{\n polygon-fill:#FF6600;\n polygon-opacity: 0.7;\n line-opacity:1;\n line-color: #FFFFFF;\n}"
multilinestring: "{\n line-color:#FF6600;\n line-width:1;\n line-opacity: 0.7;\n}"
data:
kind: "carto"
options:
query: ""
opacity: 0.99
auto_bound: false
interactivity: "cartodb_id"
debug: false
visible: true
tiler_protocol: 'http'
tiler_domain: 'localhost.lan'
tiler_port: '8181'
sql_domain: "localhost.lan"
sql_port: "8080"
sql_protocol: "http"
extra_params: { cache_policy: 'persist' }
cdn_url: ""
tile_style_history: []
style_version: "2.1.1"
infowindow:
template_name: "table/views/infowindow_light"
background:
kind: "background"
options: { color: '#ffffff' }
base:
kind: "tiled"
options:
visible: true
type: "Tiled"
urlTemplate: "http://a.tiles.mapbox.com/v3/mapbox.mapbox-streets/{z}/{x}/{y}.png"
name: 'Streets (Mapbox)'
className: "mapbox_streets"
attribution: "Mapbox <a href='http://mapbox.com/about/maps' target='_blank'>Terms & Feedback</a>"
gmaps:
kind: "gmapsbase"
options:
base_type: "roadmap"
style: ""
cartodb_com_hosted: true
cartodb_central_domain_name: 'cartodb.com'
aws:
s3:
access_key_id: "test"
secret_access_key: "test"
assets:
s3_bucket_name: "tests"
max_file_size: 10485760 # 10.megabytes
development:
<<: *defaults
varnish_management:
critical: false
host: '127.0.0.1'
port: 6082
purge_command: 'url.purge'
retries: 5
timeout: 5
test:
<<: *defaults
from cartodb.
I wouldn't have filed this bug if it were that easy. I've already tried that. Changing the setting it to http
has no effect, thus my filing of this bug. Why doesn't it work for the other two posters in this thread either?
The only way to make it use http
is to follow the instructions in this comment: #48 (comment)
from cartodb.
have you tried exactly the steps i described?
be careful because there are two places where http should be set and also you need to restart and create new tables. If you change the config file but you try to open tables already imported that is NOT going to work.
And believe me, we do NOT do any hack in cartodb.js to develop and I do develop using http
from cartodb.
Yes. I've also tried re-installing the entire database, clearing the cache,
clearing redis, and even clearing out my entire installation several times.
It does not work. For the third time: Look at the comments in this issue!
I'm not the only one with this problem. I'm glad it works for you, but it doesn't work for any of us.
On Mon, Dec 17, 2012 at 10:24 AM, javi santana [email protected]:
have you tried exactly the steps i described?
be careful because there are two places where http should be set and also
you need to restart and create new tables. If you change the config file
but you try to open tables already imported that is NOT going to work.And believe me, we do NOT do any hack in cartodb.js to develop and I do
develop using http—
Reply to this email directly or view it on GitHubhttps://github.com//issues/48#issuecomment-11445767.
from cartodb.
i already read the comments and the solution is there.
Do the following:
- import a table with data (for example erupean_countries from common data in dashboard)
- when the table is loaded the browser requests the layers in a request like http://development.localhost.lan:3000/api/v1/maps/123/layers
could you please paste me the json returned
this is what I get
{
total_entries: 2,
layers: [
{
options: {
style: null,
base_type: "roadmap"
},
kind: "gmapsbase",
infowindow: null,
id: 404,
order: 0
},
{
options: {
attribution: "CartoDB <a href='http://cartodb.com/attributions' target='_blank'>attribution</a>",
type: "CartoDB",
active: true,
query: null,
opacity: 0.99,
auto_bound: false,
interactivity: "cartodb_id",
interaction: true,
debug: false,
tiler_domain: "localhost.lan",
tiler_port: "8181",
tiler_protocol: "http",
sql_domain: "cartodb.com",
sql_port: "80",
sql_protocol: "http",
extra_params: {
cache_policy: "persist",
cache_buster: 1355741577109
},
cdn_url: "",
visible: true,
tile_style_history: [
....
from cartodb.
@javisantana I noticed that in the app_config.yml you not only have tiler_protocol in the top section, but also in the data section as:
data:
kind: "carto"
options:
query: ""
opacity: 0.99
auto_bound: false
interactivity: "cartodb_id"
debug: false
visible: true
tiler_protocol: 'http'
tiler_domain: 'localhost.lan'
tiler_port: '8181'
sql_domain: "localhost.lan"
sql_port: "8080"
sql_protocol: "http"
extra_params: { cache_policy: 'persist' }
cdn_url: ""
tile_style_history: []
style_version: "2.1.1"
infowindow:
template_name: "table/views/infowindow_light"
How do these work together with the tiler_protocol in the default section? Should we change all of them? What about tiler_domain? It is "cartodb.com" in the original app_config.yml.
from cartodb.
@zqshen you should change in all the places and all the variables you need to fit your system config (tiler_protocol, tiler_domain, tiler_port and sql variables if you need). The variables should be the same in the top section and in the data section
We are working to remove those duplicities
from cartodb.
Related Issues (20)
- Browser cache HOT 1
- rake tasks failing with invalid reference to Organization model
- clone with inaccessible submodule fails the clone process (cartodb-private) HOT 7
- Error "Validation failed: Grants can only grant table permissions you have" when creating API Key
- Trouble getting active_support to connect to db HOT 1
- Styling by value : all attributes
- Compilation error when installing python requirements, succeeds without explicit csvkit version
- nokogiri requires Ruby version < 3.1.dev, >= 2.5 HOT 5
- Loading shapefiles from zip and create map undefined method NilClass
- Cannot export data
- Stored Cross-site scripting on Maps HOT 6
- Problem with CARTO login
- Quota Exceeded By Error
- create_dev_user aborted
- submodule `cartodb-private` is missing HOT 1
- Incompatible with Firefox 100 HOT 2
- CARTO API IMPORT PROBLEMS HOT 1
- Problems with Carto API import HOT 2
- Bug in french region translation
- Potential bug in new-dashboard add-on
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cartodb.