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

Sample analysis of packaging and uploading to cloud service projects in idea

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

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

This article mainly introduces the example analysis packaged in idea and uploaded to the cloud service project, which has a certain reference value. Interested friends can refer to it. I hope you will learn a lot after reading this article. Let the editor take you to know it.

one. First of all, you have to pack it at idea.

I am using a project in the springboot framework

1. Start your own project first.

There is a border on the far right of idea. Click Maven.

If you have previously packaged for this purpose, you can click clean to clean up the previous cache, and then click package to package the project

two. After packing, we will need our own CVM.

You can use the SecureCRT or XShell plug-in to manipulate our Ali cloud server.

I'm using XShell here.

Before that, we need to match the environment of cloud services, the java jdk environment, the construction of mysql database, and the construction of tomcat environment.

On the basis of these environments, the next step of project deployment can be carried out.

three. Idea packed the jar package for us before configuring the war package.

Let's start with the jar package.

We need to use the upload plug-in on our CVM to use the command: yum install-y lrzsz

After downloading, use the command: rz and then find the jar or war package you want to deploy in the file

After putting it in the current directory, use: java-jar jar package name for example: java-jar cms111.jar

After compiling once, you can type the port number of our idea setting again to come out of the front-end web page, but we can't compile it once in the background.

So, we can create a file to store the compilation so that it compiles automatically every time we visit, then we need to use ps-ef | grep java

Let's check out the compilation process we just did.

Before the jar process, there is a five-digit number after your user name, which is his process number.

Then use the kill-9 process number to force the shutdown of the process

Once again, use ps-ef | grep java to confirm that the jar process does not exist, then use the nohup java-jar jar package name & command to create a nohup.out file to store the compiled file log

! You must not throw & away in this command. At this point, our jar package was successfully deployed to the server.

In the case of the 3-2 war package, go to the webapps directory under your tomcat path and use yum install-y lrzsz to download the plug-in first.

Then rz selects your war package when the file is uploaded successfully, the server will compile automatically. Is success.

Thank you for reading this article carefully. I hope the article "sample Analysis of packaged and uploaded to Cloud Service projects in idea" shared by the editor will be helpful to you. At the same time, I also hope you will support us and follow the industry information channel. More related knowledge is waiting for you to learn!

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

Servers

Wechat

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

12
Report