Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Containers in OpenStack

You're reading from   Containers in OpenStack Leverage OpenStack services to make the most of Docker, Kubernetes and Mesos

Arrow left icon
Product type Paperback
Published in Dec 2017
Publisher Packt
ISBN-13 9781788394383
Length 176 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (2):
Arrow left icon
 Kumar Singh Kumar Singh
Author Profile Icon Kumar Singh
Kumar Singh
 Kumari Kumari
Author Profile Icon Kumari
Kumari
Arrow right icon
View More author details
Toc

Table of Contents (17) Chapters Close

Title Page
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Customer Feedback
Preface
1. Working with Containers 2. Working with Container Orchestration Engines FREE CHAPTER 3. OpenStack Architecture 4. Containerization in OpenStack 5. Magnum – COE Management in OpenStack 6. Zun – Container Management in OpenStack 7. Kuryr – Container Plugin for OpenStack Networking 8. Murano – Containerized Application Deployment on OpenStack 9. Kolla – Containerized Deployment of OpenStack 10. Best Practices for Containers and OpenStack

Kubernetes hands-on


We learned how to install the Kubernetes cluster in the previous section. Now, let's create a more complex example with Kubernetes. In this application, we will deploy an application running a WordPress site and MySQL database using official Docker images.

  1. Create a persistent volume. Both WordPress and MySQL will use this volume to store data. We will create two local persistent volumes of size 5 GB each. Copy the following content to the volumes.yaml file:
apiVersion: v1kind: PersistentVolumemetadata:  name: pv-1  labels:    type: localspec:  capacity:    storage: 5Gi  accessModes:    - ReadWriteOnce  hostPath:    path: /tmp/data/pv-1  storageClassName: slow ---apiVersion: v1kind: PersistentVolumemetadata:  name: pv-2  labels:    type: localspec:  capacity:    storage: 5Gi  accessModes:    - ReadWriteOnce  hostPath:    path: /tmp/data/pv-2  storageClassName: slow 
  1. Now, create the volume by running the following command:
        $ kubectl create -f volumes.yaml         persistentvolume...
You have been reading a chapter from
Containers in OpenStack
Published in: Dec 2017
Publisher: Packt
ISBN-13: 9781788394383
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at £13.99/month. Cancel anytime
Visually different images