Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to run SAP UI5 application in Docker under Windows environment

2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

This article is aimed at readers who have some basic concepts of Docker technology, but do not have hands-on experience because there is no test environment.

Recently, Jerry has to build a variety of development environments because it wants to do a new SAP cloud product development, one of which is Docker.

Jerry's previous article briefly introduced Docker:

Newton standing on the shoulders of Giants: Kubernetes and SAP Kyma running SAP UI5 applications on Kubernetes (part 1) running SAP UI5 applications on Kubernetes (part two)

The example given at the time was to run a UI5 application with Docker and Kubernetes under the Ubuntu operating system. Because I know that many ABAP practitioners still use the Windows development environment, this article simply lists my steps for building Docker under the Windows operating system, and interested friends can do it again.

The Windows here specifically refers to Windows10.

The prerequisite for Windows operating system to use Docker is to turn on Hyper V virtual technology, select the box in front of Hyper-V in the control panel and restart it.

Download the Community version of Docker For Windows on Docker's official website:

Downloaded is a 900-megabyte executable file:

After installation, you can see the icon of Docker in the lower right corner of the taskbar:

Installation installs the Docker command line tool docker.exe and the container orchestration tool docker-compose.exe into the Docker folder of Program Files by default:

Right-click to use GUI to manage:

However, we are generally more accustomed to using the command line tool docker.exe to manipulate various container images.

Jerry has developed a SAP UI5 application in advance, deployed and run it on the Nginx server, and packaged the application with the Nginx server in a container image and published it to Docker Hub at the following address:

Just run the image directly on the command line:

Docker run i042416/ui5-nginx:v2.0

As you can see from the command to print the log, because my local environment does not have this image named i042416/ui5-nginx and labeled v2.0, the image will first be automatically downloaded locally from Docker Hub.

After that, you can use the docker images command to see the image successfully downloaded to the local image, with a size of about 109MB:

Now start a container using the following command line:

Docker run-d-p 1080 docker run-- name jerrynginx i042416/ui5-nginx:v2.0

The meanings of the parameters are as follows:

-d: launch the container in background mode and return its ID.-p: map the port 80 opened by the Nginx inside the container to the host port 1080, so that the host accesses the container by entering localhost:1080 in the Windows environment.

-- name: give a name to the launched container instance. After executing the command line, the browser enters the following url to access the SAP UI5 application running on the Nginx in the container:

Docker ps command, you can see the container instance that is running:

Docker inspect jerrynginx can view the details:

The container instance named jerrynginx running in the background can be observed in the Dashboard menu of Windows Docker Desktop:

The Dashboard provides some basic operations for the runtime container instance, such as viewing logs:

And log in to the container instance and execute the command line and other functions interactively. These functions are based on the implementation of the docker command line tool, which can be used according to your preference.

For more original Jerry articles, please follow the official account "Wang Zixi":

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report