April 21, 2022 By Henrik Loeser 4 min read

How to organize security and compliance when migrating from IBM Cloud Foundry to IBM Cloud Code Engine.

Over the past year, I have moved most of my deployed solutions from IBM Cloud Foundry to IBM Cloud Code Engine. I shared my experience in a series of blog posts. In the first article, I talked about how to bind cloud services to the apps or microservices and what to consider in terms of code changes (if any). Then, I discussed various DevOps aspects and how to build, deploy and scale your app on Code Engine (and how it differs from Cloud Foundry)

Today, I am going to compare Cloud Foundry and Code Engine security and how to organize your project. I’ll also take a look at compliance topics and point out how Code Engine integrates with related standard components of IBM Cloud. The bottom line is that Code Engine is based on common container technology like IBM Cloud Kubernetes Service and integrates with standard security and compliance services of IBM Cloud. Thus, for me, there were no surprises when migrating solutions from Cloud Foundry to Code Engine.

Organize it: Moving from space to project

With Cloud Foundry, you have learned to organize resources in organizations and spaces and to assign roles to users (i.e., RBAC — role-based access control). With Code Engine, you can continue in a similar way:

The (regular) integration of Code Engine with IBM Cloud IAM provides the benefits of IBM Cloud identity and access management for all. Foremost, I would like to point out that you can (and should) use service IDs to decouple DevOps pipelines with Code Engine app deployments from personal accounts and user IDs. Access groups allow you to easily define a set of privileges once, then assign them by adding users, service IDs and trusted profiles to the access group.

The screenshot below shows the defined access policies within such an access group. That access group grants the necessary privileges to push a newly built container image to the private container registry and then update the deployed Code Engine app. The privileges are scoped to a Code Engine project, a specific resource group and region:

IAM access group to assign privileges for Code Engine and container operations.

Often, when following the 12-factor app and cloud-native approach, a solution consists of multiple microservices. Each microservice could be managed and deployed as app within the same Code Engine project. It allows you to share credentials for code repository, container registry access, and more. To tighten security, you should make use of the visibility settings for Code Engine apps. They allow you to do the following:

  • Make the app publicly accessible (e.g., the web app). 
  • Keep the app private to the IBM Cloud network (e.g., an app/microservice to be accessed from other compute options or cloud services).
  • Restrict access to the project itself. I recommend this for solution-internal microservices.

Using the org/space to resource group/project mapping and the related IAM roles and then adding network security on top, it is easy to keep or even enhance the security when moving from Cloud Foundry to Code Engine.

Control it: Utilize logging, monitoring and governance services

To control and govern my deployed apps on Code Engine, I used the IBM Cloud standard services. The Code Engine documentation provides details on each integration and how to get started:

Depending on the type of solution or app, you may want to utilize all or just few of them. To me, what made it simple was that they are standard services on IBM Cloud, and I use them independent of Code Engine:

IBM Log Analysis showing console output of a Code Engine app.

Conclusions

In my series of blog posts on migrating solutions from IBM Cloud Foundry to IBM Cloud Code Engine, I touched on service bindings and possibly required code changes and on building, deploying and scaling apps. Today, I discussed security and compliance topics, and how to organize privileges for your development project and make use of existing services to look into security, quality and performance issues.

I provided many links in this blog post. If you only want to bookmark few, I recommend these:

If you have feedback, suggestions, or questions about this post, please reach out to me on Twitter (@data_henrik) or LinkedIn

Was this article helpful?
YesNo

More from Cloud

How a US bank modernized its mainframe applications with IBM Consulting and Microsoft Azure

9 min read - As organizations strive to stay ahead of the curve in today's fast-paced digital landscape, mainframe application modernization has emerged as a critical component of any digital transformation strategy. In this blog, we'll discuss the example of a fictional US bank which embarked on a journey to modernize its mainframe applications. This strategic project has helped it to transform into a more modern, flexible and agile business. In looking at the ways in which it approached the problem, you’ll gain insights…

Attention new clients: exciting financial incentives for VMware Cloud Foundation on IBM Cloud

4 min read - New client specials: Get up to 50% off when you commit to a 1- or 3-year term contract on new VCF-as-a-Service offerings, plus an additional value of up to USD 200K in credits through 30 June 2025 when you migrate your VMware workloads to IBM Cloud®.1 Low starting prices: On-demand VCF-as-a-Service deployments begin under USD 200 per month.2 The IBM Cloud benefit: See the potential for a 201%3 return on investment (ROI) over 3 years with reduced downtime, cost and…

24 IBM offerings winning TrustRadius 2024 Top Rated Awards

2 min read - TrustRadius is a buyer intelligence platform for business technology. Comprehensive product information, in-depth customer insights and peer conversations enable buyers to make confident decisions. “Earning a Top Rated Award means the vendor has excellent customer satisfaction and proven credibility. It’s based entirely on reviews and customer sentiment,” said Becky Susko, TrustRadius, Marketing Program Manager of Awards. Top Rated Awards have to be earned: Gain 10+ new reviews in the past 12 months Earn a trScore of 7.5 or higher from…

IBM Newsletters

Get our newsletters and topic updates that deliver the latest thought leadership and insights on emerging trends.
Subscribe now More newsletters