1
0
mirror of https://github.com/docker/docs.git synced 2026-11-03 11:12:47 +03:00

Merge pull request #380 from orchardup/use-hostname-for-redis-on-home-page-example

Use hostname on home page example
This commit is contained in:
Aanand Prasad
2014-08-06 16:11:44 -07:00

View File

@@ -59,10 +59,7 @@ from flask import Flask
from redis import Redis
import os
app = Flask(__name__)
redis = Redis(
host=os.environ.get('REDIS_1_PORT_6379_TCP_ADDR'),
port=int(os.environ.get('REDIS_1_PORT_6379_TCP_PORT'))
)
redis = Redis(host="redis_1", port=6379)
@app.route('/')
def hello():