Glance registry finally working

This commit is contained in:
Przemyslaw Kaminski 2015-06-01 19:05:53 +02:00
parent 0937ad6840
commit abcd27d065
13 changed files with 23 additions and 12 deletions

View File

@ -7,6 +7,7 @@
keystone_port: {{ keystone_port }}
keystone_admin_user: {{ keystone_admin_user }}
keystone_admin_password: {{ keystone_admin_password }}
keystone_admin_port: {{ keystone_admin_port }}
keystone_admin_tenant: {{ keystone_admin_tenant }}
mysql_ip: {{ mysql_ip }}
mysql_db: {{ mysql_db }}

View File

@ -33,6 +33,9 @@ input:
keystone_admin_password:
schema: str!
value: password1234
keystone_admin_port:
schema: int!
value:
keystone_admin_tenant:
schema: str!
value: service_admins

View File

@ -1,4 +1,4 @@
export OS_TENANT_NAME={{ keystone_admin_tenant }}
export OS_USERNAME={{ keystone_admin_user }}
export OS_PASSWORD={{ keystone_admin_password }}
export OS_AUTH_URL=http://{{ keystone_ip }}:35357/v2.0
export OS_AUTH_URL=http://{{ keystone_ip }}:{{ keystone_admin_port }}/v2.0

View File

@ -67,7 +67,7 @@ paste.filter_factory = glance.api.middleware.context:UnauthenticatedContextMiddl
[filter:authtoken]
paste.filter_factory = keystonemiddleware.auth_token:filter_factory
identity_uri = http://{{ keystone_ip }}:35357
identity_uri = http://{{ keystone_ip }}:{{ keystone_admin_port }}
admin_user = {{ keystone_admin_user }}
admin_tenant_name = {{ keystone_admin_tenant }}
admin_password = {{ keystone_admin_password }}

View File

@ -15,11 +15,11 @@ image_cache_dir = /var/lib/glance/image-cache/
[database]
connection = mysql://{{ mysql_user }}:{{ mysql_password }}@{{ mysql_ip }}/{{ mysql_db }}
backend = sqlalchemy
backend = mysql
[keystone_authtoken]
auth_uri = http://{{ keystone_ip }}:{{ keystone_port }}/v2.0
identity_uri = http://{{ keystone_ip }}:35357
identity_uri = http://{{ keystone_ip }}:{{ keystone_admin_port }}
admin_tenant_name = {{ keystone_admin_tenant }}
admin_user = {{ keystone_admin_user }}
admin_password = {{ keystone_admin_password }}

View File

@ -24,7 +24,7 @@ paste.filter_factory = glance.api.middleware.context:UnauthenticatedContextMiddl
[filter:authtoken]
paste.filter_factory = keystonemiddleware.auth_token:filter_factory
identity_uri = http://{{ keystone_ip }}:35357
identity_uri = http://{{ keystone_ip }}:{{ keystone_admin_port }}
admin_user = {{ keystone_admin_user }}
admin_tenant_name = {{ keystone_admin_tenant }}
admin_password = {{ keystone_admin_password }}

View File

@ -7,12 +7,12 @@ api_limit_max = 1000
limit_param_default = 25
[database]
backend = sqlalchemy
backend = mysql
connection = mysql://{{ mysql_user }}:{{ mysql_password }}@{{ mysql_ip }}/{{ mysql_db }}
[keystone_authtoken]
auth_uri = http://{{ keystone_ip }}:{{ keystone_port }}/v2.0
identity_uri = http://{{ keystone_ip }}:35357
identity_uri = http://{{ keystone_ip }}:{{ keystone_admin_port }}
admin_tenant_name = {{ keystone_admin_tenant }}
admin_user = {{ keystone_admin_user }}
admin_password = {{ keystone_admin_password }}

View File

@ -3,7 +3,8 @@
sudo: yes
tasks:
- docker:
command: /bin/bash -c "glance-manage db_sync && /usr/bin/keystone-registry"
#command: /bin/bash -c "glance-manage db_sync && /usr/bin/glance-registry"
command: /usr/bin/glance-registry
name: {{ name }}
image: {{ image }}
state: running

View File

@ -1,5 +1,7 @@
- hosts: [{{ ip }}]
sudo: yes
tasks:
- name: install python-keystoneclient
shell: pip install python-keystoneclient
- name: keystone role
keystone_user: endpoint=http://{{keystone_host}}:{{keystone_port}}/v2.0/ token={{admin_token}} user={{user_name}} tenant={{tenant_name}} role={{role_name}} state=present

View File

@ -1 +1,5 @@
#todo
- hosts: [{{ ip }}]
sudo: yes
tasks:
- shell: echo 1

View File

@ -1,5 +1,7 @@
- hosts: [{{ ip }}]
sudo: yes
tasks:
- name: install python-keystoneclient
shell: pip install python-keystoneclient
- name: keystone tenant
keystone_user: endpoint=http://{{keystone_host}}:{{keystone_port}}/v2.0/ token={{admin_token}} tenant={{tenant_name}} state=present

View File

@ -3,4 +3,5 @@
tasks:
- name: install python-keystoneclient
shell: pip install python-keystoneclient
- name: keystone user
keystone_user: endpoint=http://{{ keystone_host }}:{{ keystone_port }}/v2.0/ token={{ admin_token }} user={{ user_name }} password={{ user_password }} tenant={{ tenant_name }} state=present

View File

@ -5,15 +5,12 @@ input:
keystone_host:
schema: str!
value:
keystone_admin_port:
keystone_port:
schema: int!
value:
admin_token:
schema: str!
value:
role_name:
schema: str!
value:
user_name:
schema: str!
value: