Issue link: https://read.uberflip.com/i/1334488
Chapter 4 105 2. With the endpoints configured to point to our OpenStack Storage server, we can now set up the swift user, so our proxy server can authenticate with the OpenStack Identity server. # Get the service tenant ID SERVICE_TENANT_ID=$(keystone tenant-list | awk '/\ service\ / {print $2}') # Create the swift user keystone user-create --name swift --pass swift --tenant_id $SERVICE_TENANT_ID --email swift@localhost --enabled true # Get the swift user id USER_ID=$(keystone user-list | awk '/\ swift\ / {print $2}') # Get the admin role id ROLE_ID=$(keystone role-list | awk '/\ admin\ / {print $2}') # Assign the swift user admin role in service tenant keystone user-role-add --user $USER_ID --role $ROLE_ID --tenant_id $SERVICE_TENANT_ID 3. On the OpenStack Storage server (openstack2), we now install the Keystone Python libraries, so that OpenStack Identity Service can be used. This is done as follows: sudo apt-get update sudo apt-get install python-keystone 4. We can now edit the proxy server configuration, /etc/swift/proxy-server. conf, to utilize OpenStack Identity Server, as follows: [DEFAULT] bind_port = 443 cert_file = /etc/swift/cert.crt key_file = /etc/swift/cert.key user = swift log_facility = LOG_LOCAL1 [pipeline:main] pipeline = catch_errors healthcheck cache authtoken keystone proxy-server [app:proxy-server] use = egg:swift#proxy account_autocreate = true www.it-ebooks.info

