Deploy Ghost in a Spot Namespace on RSaaS from your browser

28. Juni 2020 Digitalisierung

  • Photo by Karim MANJRA on Unsplash

    In my previous post Spot Namespaces on RSaaS was introduced.

    In this post I’m going to show you how you can run ghost, a headless CMS or your own apps in a namespace by defining the proper requests and limits in the deployment manifest file of ghost or your own app on RSaaS.

    After you’re logged into Rancher you’ll have access to your project on your assigned Kubernetes cluster in form of <user-id>-project-spot-namespace:

    Click on the project and in the navigation menu bar click on Namespaces and in the top right side click on the blue button “Add Namespace”:

    Please provide you user id or any other name as you’d like for the namespace, if a namespace like my-namespace exists, you’ll get a warning notice from the system and you should provide another name. We recommend to provide your user-id as the namespace name. In our next release we’ll create the namespace with your user-id for you.

    Add Namespace

    Now that we have created a namespace, we’re ready to deploy our Ghost app.

    First you need to select the cluster and click on the “Launch kubectl” button:

    With that we’ll have Shell access to the cluster in our browser:

    With the following kubectl command, you can switch to your namespace:

    kubectl config set-context --current --namespace <your namespace>

    And deploy Ghost like this:

    kubectl create -f

    Please note in the spec part of the manifest we’re setting the limits for CPU and Memory in the resources part of our ghost image, unless you’ll not be able to deploy the app.

    - image: ghost:latest
    imagePullPolicy: IfNotPresent
    name: ghost
    memory: 512Mi
    cpu: 500m
    memory: 256Mi

    To see if our deployment was successful, we can run:

    kubectl get deployment

    Now we can create a L7 Ingress to ghost easily in Rancher by selecting Resources → Workloads → Add ingress.

    In this example we’re going to tell Rancher to generate a hostname for us:

    After couple of seconds the L7 ghost ingress is ready to go, click on the link and enjoy:


    If you have any questions, we’d love to welcome you to our Kubernauts Slack channel and be of help.

    We’re hiring!

    We love people who love building things, New Things!
    If you wish to work on New Things, please do visit our job offerings page.

    Deploy Ghost in a Spot Namespace on RSaaS from your browser was originally published in Kubernauts on Medium, where people are continuing the conversation by highlighting and responding to this story.

    Mehr zu Kubernetes Services, Kubernetes Training und Rancher dedicated as a Service lesen unter—-d831ce817894—4