5 upstream |
5 upstream |
6 |
6 |
7 It also includes a change to use the standard Solaris tr(1) rather than |
7 It also includes a change to use the standard Solaris tr(1) rather than |
8 GNU sed. |
8 GNU sed. |
9 |
9 |
10 --- keystone-2015.1.2/tools/sample_data.sh.~2~ 2016-02-07 01:41:04.218073379 -0800 |
10 --- keystone-9.1.0/tools/sample_data.sh.~1~ 2016-07-05 08:27:02.000000000 -0700 |
11 +++ keystone-2015.1.2/tools/sample_data.sh 2016-02-07 01:44:19.119595020 -0800 |
11 +++ keystone-9.1.0/tools/sample_data.sh 2016-08-24 02:06:51.106133355 -0700 |
12 @@ -23,8 +23,8 @@ |
12 @@ -23,8 +23,8 @@ |
13 # API. It will get the admin_token (OS_TOKEN) and admin_port from |
13 # API. It will get the admin_token (OS_TOKEN) and admin_port from |
14 # keystone.conf if available. |
14 # keystone.conf if available. |
15 # |
15 # |
16 -# Disable creation of endpoints by setting DISABLE_ENDPOINTS environment variable. |
16 -# Disable creation of endpoints by setting DISABLE_ENDPOINTS environment variable. |
18 +# Disable creation of endpoints by setting DISABLE_ENDPOINTS environment |
18 +# Disable creation of endpoints by setting DISABLE_ENDPOINTS environment |
19 +# variable. Use this with the Catalog Templated backend. |
19 +# variable. Use this with the Catalog Templated backend. |
20 # |
20 # |
21 # A EC2-compatible credential is created for the admin user and |
21 # A EC2-compatible credential is created for the admin user and |
22 # placed in etc/ec2rc. |
22 # placed in etc/ec2rc. |
23 @@ -37,11 +37,15 @@ |
23 @@ -33,15 +33,19 @@ |
24 # service ec2 admin |
24 # ------------------------------------------------------- |
25 # service swift admin |
25 # demo admin admin |
26 # service neutron admin |
26 # service glance service |
|
27 -# service nova service |
|
28 +# service nova admin, service |
|
29 # service ec2 service |
|
30 # service swift service |
|
31 -# service neutron service |
27 - |
32 - |
28 -# By default, passwords used are those in the OpenStack Install and Deploy Manual. |
33 -# By default, passwords used are those in the OpenStack Install and Deploy Manual. |
29 -# One can override these (publicly known, and hence, insecure) passwords by setting the appropriate |
34 -# One can override these (publicly known, and hence, insecure) passwords by setting the appropriate |
30 -# environment variables. A common default password for all the services can be used by |
35 -# environment variables. A common default password for all the services can be used by |
31 -# setting the "SERVICE_PASSWORD" environment variable. |
36 -# setting the "SERVICE_PASSWORD" environment variable. |
32 +# service cinder admin |
37 +# service neutron admin, service |
33 +# service heat admin |
38 +# service cinder service |
34 +# service ironic admin |
39 +# service heat service |
|
40 +# service ironic service |
35 + |
41 + |
36 +# By default, passwords used are those in the OpenStack Install and Deploy |
42 +# By default, passwords used are those in the OpenStack Install and Deploy |
37 +# Manual. One can override these (publicly known, and hence, insecure) |
43 +# Manual. One can override these (publicly known, and hence, insecure) |
38 +# passwords by setting the appropriate environment variables. A common default |
44 +# passwords by setting the appropriate environment variables. A common default |
39 +# password for all the services can be used by setting the "SERVICE_PASSWORD" |
45 +# password for all the services can be used by setting the "SERVICE_PASSWORD" |
122 + CONFIG_ADMIN_PORT=$(tr -d '[\t ]' < $KEYSTONE_CONF | \ |
128 + CONFIG_ADMIN_PORT=$(tr -d '[\t ]' < $KEYSTONE_CONF | \ |
123 + grep ^\#admin_port= | cut -d'=' -f2) |
129 + grep ^\#admin_port= | cut -d'=' -f2) |
124 fi |
130 fi |
125 fi |
131 fi |
126 |
132 |
127 @@ -156,6 +204,29 @@ openstack role add --user neutron \ |
133 @@ -139,6 +187,10 @@ openstack user create nova --project ser |
|
134 |
|
135 openstack role add --user nova \ |
128 --project service \ |
136 --project service \ |
129 admin |
137 + admin |
|
138 + |
|
139 +openstack role add --user nova \ |
|
140 + --project service \ |
|
141 service |
|
142 |
|
143 openstack user create ec2 --project service \ |
|
144 @@ -160,8 +212,35 @@ openstack user create neutron --project |
|
145 |
|
146 openstack role add --user neutron \ |
|
147 --project service \ |
|
148 + admin |
|
149 + |
|
150 +openstack role add --user neutron \ |
|
151 + --project service \ |
|
152 service |
130 |
153 |
131 +openstack user create cinder --project service \ |
154 +openstack user create cinder --project service \ |
132 + --password "${CINDER_PASSWORD}" |
155 + --password "${CINDER_PASSWORD}" |
133 + |
156 + |
134 +openstack role add --user cinder \ |
157 +openstack role add --user cinder \ |
152 + admin |
175 + admin |
153 + |
176 + |
154 # |
177 # |
155 # Keystone service |
178 # Keystone service |
156 # |
179 # |
157 @@ -178,24 +249,32 @@ openstack service create --name=nova \ |
180 @@ -184,24 +263,32 @@ openstack service create --name=nova \ |
158 compute |
181 compute |
159 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
182 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
160 openstack endpoint create --region RegionOne \ |
183 openstack endpoint create --region RegionOne \ |
161 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8774/v2/\$(tenant_id)s" \ |
184 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8774/v2/\$(tenant_id)s" \ |
162 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8774/v2/\$(tenant_id)s" \ |
185 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8774/v2/\$(tenant_id)s" \ |
193 + --internalurl "http://$CINDER_INTERNAL_ADDRESS:8776/v2/\$(tenant_id)s" \ |
216 + --internalurl "http://$CINDER_INTERNAL_ADDRESS:8776/v2/\$(tenant_id)s" \ |
194 + cinderv2 |
217 + cinderv2 |
195 fi |
218 fi |
196 |
219 |
197 # |
220 # |
198 @@ -206,9 +285,9 @@ openstack service create --name=glance \ |
221 @@ -212,9 +299,9 @@ openstack service create --name=glance \ |
199 image |
222 image |
200 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
223 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
201 openstack endpoint create --region RegionOne \ |
224 openstack endpoint create --region RegionOne \ |
202 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:9292" \ |
225 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:9292" \ |
203 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:9292" \ |
226 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:9292" \ |
206 + --adminurl "http://$GLANCE_ADMIN_ADDRESS:9292" \ |
229 + --adminurl "http://$GLANCE_ADMIN_ADDRESS:9292" \ |
207 + --internalurl "http://$GLANCE_INTERNAL_ADDRESS:9292" \ |
230 + --internalurl "http://$GLANCE_INTERNAL_ADDRESS:9292" \ |
208 glance |
231 glance |
209 fi |
232 fi |
210 |
233 |
211 @@ -220,9 +299,9 @@ openstack service create --name=ec2 \ |
234 @@ -226,9 +313,9 @@ openstack service create --name=ec2 \ |
212 ec2 |
235 ec2 |
213 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
236 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
214 openstack endpoint create --region RegionOne \ |
237 openstack endpoint create --region RegionOne \ |
215 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8773/services/Cloud" \ |
238 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8773/services/Cloud" \ |
216 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8773/services/Admin" \ |
239 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8773/services/Admin" \ |
219 + --adminurl "http://$EC2_ADMIN_ADDRESS:8773/services/Admin" \ |
242 + --adminurl "http://$EC2_ADMIN_ADDRESS:8773/services/Admin" \ |
220 + --internalurl "http://$EC2_INTERNAL_ADDRESS:8773/services/Cloud" \ |
243 + --internalurl "http://$EC2_INTERNAL_ADDRESS:8773/services/Cloud" \ |
221 ec2 |
244 ec2 |
222 fi |
245 fi |
223 |
246 |
224 @@ -234,9 +313,11 @@ openstack service create --name=swift \ |
247 @@ -240,9 +327,11 @@ openstack service create --name=swift \ |
225 object-store |
248 object-store |
226 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
249 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
227 openstack endpoint create --region RegionOne \ |
250 openstack endpoint create --region RegionOne \ |
228 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8080/v1/AUTH_\$(tenant_id)s" \ |
251 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:8080/v1/AUTH_\$(tenant_id)s" \ |
229 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8080/v1" \ |
252 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:8080/v1" \ |
234 + --internalurl \ |
257 + --internalurl \ |
235 + "http://$SWIFT_INTERNAL_ADDRESS:8080/v1/AUTH_\$(tenant_id)s" \ |
258 + "http://$SWIFT_INTERNAL_ADDRESS:8080/v1/AUTH_\$(tenant_id)s" \ |
236 swift |
259 swift |
237 fi |
260 fi |
238 |
261 |
239 @@ -248,12 +329,48 @@ openstack service create --name=neutron |
262 @@ -254,12 +343,48 @@ openstack service create --name=neutron |
240 network |
263 network |
241 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
264 if [[ -z "$DISABLE_ENDPOINTS" ]]; then |
242 openstack endpoint create --region RegionOne \ |
265 openstack endpoint create --region RegionOne \ |
243 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:9696" \ |
266 - --publicurl "http://$CONTROLLER_PUBLIC_ADDRESS:9696" \ |
244 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:9696" \ |
267 - --adminurl "http://$CONTROLLER_ADMIN_ADDRESS:9696" \ |