TrackIt is an amazing product to manage and optimize your cloud billing. However, some customers aren’t ready and still wants to have a hands-on the solution they’re using for security or management reasons.

replicated logo

We are going to show you how you can use Replicated to transform TrackIt into an on-premise product.

Logo_animation-24-small-161In today’s world, we tend to externalize our resources. The cloud is certainly the future, but some businesses are not ready to jump in for reasons such as highly sensitive data, lack of trust or simply lack the budget.
How do you sell your cloud-oriented product to those companies who don’t want to externalize their data? How do you achieve on-premise distribution of your product? Replicated is the solution!

Replicated wraps your containerized cloud application with Enterprise-grade features and deploys it behind your customer’s firewall into a corporate data center or into the private cloud.

Prerequisites

  • Sign up for a Replicated account (https://vendor.replicated.com/#/account/signup)
  • A test machine (to simulate client environment) with tcp port 9870 to 9880 opened

Create a new Replicated project

Create a new application

Replicated allows you to manage every aspect of your product from image hosting to licensing  and distribution. For now, click on create new app to start the journey of our on premise TrackIT.
You can now see a brand new dashboard for your project.
Screen Shot 2017 01 22 at 20.33.13

You will be able to manage 3 distributions channels: stable, beta, unstable. Let’s create our first release by clicking on Create Release.

Upload our images

With Replicated, you can use images that are hosted on the Docker Hub, but it also enables the capability to host them on Replicated repository. This is the solution we are going to use.

For TrackIT we have to upload 3 of our images: the api, the webui and the loadbalancer (not mandatory). The rest of them are publicly available on the Docker Hub.

First let’s log on repgistry:

docker login registry.replicated.com

We need to tag each of our images

docker tag f7aebeee3cf8 registry.replicated.com/msolution/trackit-api:latest
docker tag 9208bd226c4d registry.replicated.com/msolution/trackit-webui:latest
docker tag 9534122d0bc1 registry.replicated.com/msolution/trackit-loadbalancer:latest

And now, let’s push them all:

docker push registry.replicated.com/msolution/trackit-api:latest
docker push registry.replicated.com/msolution/trackit-webui:latest
docker push registry.replicated.com/msolution/trackit-loadbalancer:latest

Configure your application

Replicated uses yaml syntax and has a logic similar to a docker-compose, this is the configuration we will use for TrackIT:

---
replicated_api_version: "1.3.2"
name: "msolution"
properties:
 app_url: ""
 logo_url: http://www.replicated.com/images/logo.png
 console_title: Your App Name
backup:
 enabled: false
monitors:
 cpuacct: []
 memory: []
components:
 - name: mysql
   containers:
     - source: public
       image_name: mysql
       version: latest
       env_vars:
         - name: MYSQL_ROOT_PASSWORD
           static_val: "very_secret_password"
       volumes:
         - host_path: /trackit/mysql
           container_path: /var/lib/mysql
       ports:
          - private_port: "3306"
            public_port: "3306"
            port_type: "tcp"
            interface: "docker0"
            when: ""
 - name: api
   containers:
     - source: replicated
       image_name: trackit-api
       version: latest
   ports:
     - private_port: "5000"
       public_port: "5000"
       port_type: "tcp"
       interface: "docker0"
   env_vars:
     - name: DEBUG
       static_val: "true"
   volumes:
     - host_path: /trackit/log
       container_path: /root/log
   extra_hosts:
     - hostname: mysql
       address: '{{repl ThisHostInterfaceAddress "docker0"}}'
     - hostname: redis
       address: '{{repl ThisHostInterfaceAddress "docker0"}}'
     - hostname: es1
       address: '{{repl ThisHostInterfaceAddress "docker0"}}'
 - name: webui
   containers:
     - source: replicated
       image_name: trackit-webui
       version: latest
    ports:
      - private_port: "8000"
        public_port: "8000"
        port_type: "tcp"
        interface: "docker0"
 - name: es1
   containers:
      - source: public
        image_name: elasticsearch
        version: 1.5.2
   volumes:
     - host_path: /trackit/data/es1
       container_path: /media/es-data1
     - host_path: /trackit/conf/elasticsearch
       container_path: /var/log/elasticsearch
   ports:
     - private_port: "9200"
       public_port: "9200"
       port_type: "tcp"
       interface: "docker0"
       when: ""
     - private_port: "9300"
       public_port: "9300"
       port_type: "tcp"
       interface: "docker0"
       when: ""
 - name: redis
   containers:
     - source: public
       image_name: redis
       version: latest
   ports:
     - private_port: "6379"
       public_port: "6379"
       interface: "docker0"
       when: ""
 - name: loadbalancer
   containers:
     - source: replicated
       image_name: trackit-loadbalancer
       version: latest
   ports:
     - private_port: "80"
       public_port: "80"
       port_type: "tcp"
       when: ""
     - private_port: "81"
        public_port: "81"
        port_type: "tcp"
        when: ""
     - private_port: "443"
       public_port: "443"
       port_type: "tcp"
       when: ""
   extra_hosts:
     - hostname: api
       address: '{{repl ThisHostInterfaceAddress "docker0"}}'
     - hostname: webui
       address: '{{repl ThisHostInterfaceAddress "docker0"}}'
config: []

This configuration describes all the containers we have. We can create links between them, set env vars, etc. Everything like a docker-compose file.

Release your first version

Save this configuration and go back on the Release page. We now need to release our first version. For that click on Promote

replicated_2

This dialog gives you the choice between 3 release channels. We will choose unstable for our example. Click on Promote Release.

Manage licenses and clients

Now your solution is ready to be shipped on premise. The next phase is to create and manage licenses for our clients. Each client will have its own license, and Replicated allows you to manage very precisely those licenses: duration, release channel, what action to take after expiration, etc.

Let’s create a license for our fictive customer of TrackIT:

replicated_3

Download the .rli license file and we are ready to install it on our client infrastructure.

Deploy your solution in your client’s on-premise infrastructure

Install Replicated client

Once everything is set up, deploying your solution is very easy. You just need to install the replicated client, load the license and you’re all set!

Install replicated client in one command:

curl -sSL https://get.replicated.com/docker | sudo bash
It will prompt you some straightforward questions about your infrastructure (private ip, proxy, etc). Once it’s done, go on https://yourip:8800/

SSL Certificate

At first launch, you will need to provide a SSL certificate or chose to use a self-signed certificate. In our case we will choose this last option by providing a hostname and clicking Using Self-Signed Cert

replicated_4

Upload client license

Here we will need to upload the license file we previously created for our client. This file is unique for each client.

replicated_5

Secure with password and preflight checks

Choose a password for admin console and make sure all your preflight checks are ok (and correct them if not)

replicated_6

Enjoy!

Now you’re on the client dashboard and Replicated has already launched the last version of the release channel you’ve previously designated for your client.
Your solution is now available on premise, and if you go on http://yourip:8080/ You will see your TrackIT on premise instance. Congratulations!

Screen Shot 2017-01-25 at 14.20.28

About TrackIt

TrackIt, an Amazon Web Services Advanced Consulting Partner based in Marina del Rey, CA, offers a range of cloud management, consulting, and software development solutions. Their expertise includes Modern Software Development, DevOps, Infrastructure-As-Code, Serverless, CI/CD, and Containerization, with a focus on Media & Entertainment workflows, High-Performance Computing environments, and data storage.

TrackIt excels in cutting-edge software design, particularly in the areas of containerization, serverless architectures, and pipeline development. The company’s team of experts can help you design and deploy a custom solution tailored to your specific needs.

In addition to cloud management and modern software development services, TrackIt also provides an open-source AWS cost management tool to help users optimize their costs and resources on the platform. With its innovative approach and expertise, TrackIt is the ideal partner for organizations seeking to maximize the potential of their cloud infrastructure.

Logo1 colour RGB 7