mirror of
https://github.com/ansible/awx.git
synced 2024-10-31 23:51:09 +03:00
Merge pull request #3720 from shanemcd/memcache-config
Fix memcached configuration in local Docker installs Reviewed-by: https://github.com/softwarefactory-project-zuul[bot]
This commit is contained in:
commit
15ef095366
@ -99,16 +99,4 @@ CHANNEL_LAYERS = {
|
||||
'CONFIG': {'url': BROKER_URL}}
|
||||
}
|
||||
|
||||
|
||||
CACHES = {
|
||||
'default': {
|
||||
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
|
||||
'LOCATION': '{}:{}'.format(os.getenv("MEMCACHED_HOST", None),
|
||||
os.getenv("MEMCACHED_PORT", "11211"))
|
||||
},
|
||||
'ephemeral': {
|
||||
'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
|
||||
},
|
||||
}
|
||||
|
||||
USE_X_FORWARDED_PORT = True
|
||||
|
@ -5,9 +5,14 @@ rabbitmq_version: "3.7.4"
|
||||
rabbitmq_image: "ansible/awx_rabbitmq:{{rabbitmq_version}}"
|
||||
rabbitmq_default_vhost: "awx"
|
||||
rabbitmq_erlang_cookie: "cookiemonster"
|
||||
rabbitmq_host: "rabbitmq"
|
||||
rabbitmq_port: "5672"
|
||||
rabbitmq_user: "guest"
|
||||
rabbitmq_password: "guest"
|
||||
|
||||
postgresql_version: "9.6"
|
||||
postgresql_image: "postgres:{{postgresql_version}}"
|
||||
|
||||
memcached_host: "memcached"
|
||||
memcached_port: "11211"
|
||||
|
||||
|
@ -20,10 +20,12 @@
|
||||
content: "{{ secret_key }}"
|
||||
dest: "{{ docker_compose_dir }}/SECRET_KEY"
|
||||
mode: 0600
|
||||
register: awx_secret_key
|
||||
|
||||
- name: Start the containers
|
||||
docker_service:
|
||||
project_src: "{{ docker_compose_dir }}"
|
||||
restarted: "{{ awx_compose_config is changed or awx_secret_key is changed }}"
|
||||
register: awx_compose_start
|
||||
|
||||
- name: Update CA trust in awx_web container
|
||||
|
@ -9,11 +9,12 @@ DATABASES = {
|
||||
'PORT': "{{ pg_port }}",
|
||||
}
|
||||
}
|
||||
|
||||
BROKER_URL = 'amqp://{}:{}@{}:{}/{}'.format(
|
||||
"{{ rabbitmq_user }}",
|
||||
"{{ rabbitmq_password }}",
|
||||
"rabbitmq",
|
||||
"5672",
|
||||
"{{ rabbitmq_host }}",
|
||||
"{{ rabbitmq_port }}",
|
||||
"awx")
|
||||
|
||||
CHANNEL_LAYERS = {
|
||||
@ -21,3 +22,13 @@ CHANNEL_LAYERS = {
|
||||
'ROUTING': 'awx.main.routing.channel_routing',
|
||||
'CONFIG': {'url': BROKER_URL}}
|
||||
}
|
||||
|
||||
CACHES = {
|
||||
'default': {
|
||||
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
|
||||
'LOCATION': '{}:{}'.format("{{ memcached_host }}", "{{ memcached_port }}")
|
||||
},
|
||||
'ephemeral': {
|
||||
'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
|
||||
},
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user