Matteo Scandolo | eb0d11c | 2017-08-08 13:05:26 -0700 | [diff] [blame] | 1 | |
| 2 | # Copyright 2017-present Open Networking Foundation |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | |
| 16 | |
rdudyala | b086cf3 | 2016-08-11 00:07:45 -0400 | [diff] [blame] | 17 | set -x |
| 18 | export OS_TOKEN=ADMIN_TOKEN |
| 19 | export OS_URL=http://localhost:35357/v3 |
| 20 | export OS_IDENTITY_API_VERSION=3 |
| 21 | #Deleting services: |
| 22 | for i in $(openstack service list -f table -c ID); do openstack service delete $i; done |
| 23 | for i in $(openstack user list -f table -c ID); do openstack user delete $i; done |
| 24 | for i in $(openstack role list -f table -c ID); do openstack role delete $i; done |
| 25 | for i in $(openstack project list -f table -c ID); do openstack project delete $i; done |
| 26 | openstack service create --name keystone --description "OpenStack Identity" identity |
| 27 | openstack endpoint create --region RegionOne identity public http://localhost:5000/v3 |
| 28 | openstack endpoint create --region RegionOne identity internal http://localhost:5000/v3 |
| 29 | openstack endpoint create --region RegionOne identity admin http://localhost:35357/v3 |
| 30 | |
| 31 | openstack domain create --description "Default Domain" default |
| 32 | |
| 33 | openstack project create --domain default --description "Admin Project" admin |
| 34 | |
| 35 | openstack user create --domain default --password password admin |
| 36 | |
| 37 | openstack role create admin |
| 38 | openstack role add --project admin --user admin admin |
| 39 | |
| 40 | openstack project create --domain default --description "Service Project" service |
| 41 | openstack project create --domain default --description "Demo Project" demo |
| 42 | |
| 43 | openstack user create --domain default --password password demo |
| 44 | openstack role create user |
| 45 | openstack role add --project demo --user demo user |
| 46 | |
| 47 | openstack user create --domain default --password password ceilometer |
| 48 | openstack role add --project service --user ceilometer admin |
| 49 | |
| 50 | openstack service create --name ceilometer --description "Telemetry" metering |
| 51 | openstack endpoint create --region RegionOne metering public http://localhost:8777 |
| 52 | openstack endpoint create --region RegionOne metering internal http://localhost:8777 |
| 53 | openstack endpoint create --region RegionOne metering admin http://localhost:8777 |
| 54 | |
| 55 | openstack user list |
| 56 | openstack service list |