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

Installation and use tutorials for Alpine Linux

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

Share

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

This article focuses on the installation and use of Alpine Linux tutorials, interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Now let the editor take you to learn the "installation and use of Alpine Linux tutorial" bar!

Alpine Linux

The Alpine Linux Docker image is based on the Alpine Linux operating system, which is a lightweight security-oriented Linux distribution. Unlike the usual Linux distributions, Alpine Linux uses musl libc and busybox to reduce system size and runtime resource consumption. While keeping slim, Alpine Linux also provides its own package management tool, apk, which can be queried on its website or directly queried and installed through the apk command.

Official website: https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management

Apk search-v 'jdk'

Apk update

Apk add curl=7.55.0-r0

Here we choose to use a smaller Linux image, Alpine, to image the container of the QR code service with the same function.

Because Alpine and Ubuntu are not maintained by the same community, many package names are different, and here I directly provide the image file that I have looked for and modified.

If you have similar requirements and need to migrate and install software from different systems, you can look up the name of the package you need in https://pkgs.alpinelinux.org/packages.

=

Attempt to install with apt-get install python-matplotlib failed, so install with pip instead

Pip install matplotlib: failure caused by pip's failure to install dependent libraries of the operating system

=

Execute: pip install-I https://pypi.tuna.tsinghua.edu.cn/simple matplotlib

Question 1

Failure caused by pip's failure to install dependent libraries of the operating system

Resolve:

Apk search-v 'freetype' | grep devel

Apk search-v 'png' | grep devel

Manual installation: apk add freetype-dev

Apk add libpng-dev

Question 2:

Gcc: error trying to exec 'cc1plus': execvp: No such file or directory

The cause of the problem may be that there is no gcc installed, or the installed gcc version is not compatible with Gmail +. The solution is as follows:

First, check whether gcc or Gmail + has been installed. If not, use gcc-v and gcc +-v to check the version numbers of gcc and Gmail +, respectively, to see if the version numbers are the same. If not, please install the same version of gcc and Gmail +.

Solution: gcc is installed, but galleys are not installed, so you can install it: apk add gears +

Question 3:

The installation prompt can be solved.

The final Dockerfile is:

FROM * * / flask-restfulRUN apk update & &\ apk add gcc freetype-dev libpng-dev g++WORKDIR / usr/lib/python2.7/site-packages/RUN mkdir-p matplotlib/backends/web_backendCOPY jquery-ui-1.12.1.zip / tmpRUN unzip / tmp/jquery-ui-1.12.1.zip-d / usr/lib/python2.7/site-packages/ Matplotlib/backends/web_backendRUN rm-rf / tmp/jquery-ui-1.12.1.zip & &\ pip install-I https://pypi.tuna.tsinghua.edu.cn/simple-U pip setuptools & &\ pip install-I https://pypi.tuna.tsinghua.edu.cn/simple matplotlib & &\ apk add ttf-dejavu & &\ rm-rf / var/cache/apk/ * COPY msyh.ttf / usr/share/fonts/ttf-dejavu

= install FROM nx-goldwind.alauda.cn:5000/common/air_grpc:0.0.3 using root user

MAINTAINER zhangchunyang@goldwind.com.cnUSER 0RUN pip install-I https://pypi.tuna.tsinghua.edu.cn/simple-U pip setuptools & &\ pip install-I https://pypi.tuna.tsinghua.edu.cn/simple pymongo & &\ pip install-I https://pypi.tuna.tsinghua.edu.cn/simple pandas & &\ pip install-I https://pypi.tuna.tsinghua.edu.cn/simple numpy &\ pip install-I https : / / pypi.tuna.tsinghua.edu.cn/simple scikit-learn==0.19.1 USER airflow to this point I believe you have a deeper understanding of the "installation and use of Alpine Linux tutorial". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue 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

Internet Technology

Wechat

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

12
Report