如意玲珑支持发行版再添新成员,openEuler安装使用如意玲珑操作指南
<p><img class="alignnone size-full wp-image-34377" src="https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面.png" alt="" width="900" height="383" srcset="https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面.png 900w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-300x128.png 300w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-150x64.png 150w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-768x327.png 768w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-24x10.png 24w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-36x15.png 36w, https://www.deepin.org/wp-content/uploads/2024/08/蓝紫色渐变科技风企业招聘微信公众号封面-48x20.png 48w" sizes="(max-width: 900px) 100vw, 900px" /></p><p>如意玲珑(Linyaps)项目已与开放原子开源基金会完成捐赠协议签署,目前如意玲珑已成为基金会的正式孵化期项目。</p>
<p><img loading="lazy" class="alignnone size-full wp-image-34237" src="https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1.png" alt="" width="663" height="172" srcset="https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1.png 663w, https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1-300x78.png 300w, https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1-150x39.png 150w, https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1-24x6.png 24w, https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1-36x9.png 36w, https://www.deepin.org/wp-content/uploads/2024/07/企业微信截图_17211009637781-1-48x12.png 48w" sizes="(max-width: 663px) 100vw, 663px" /></p>
<p>如意玲珑是开源软件包格式,用于替代 deb、rpm等包管理工具,实现应用包管理、分发、容器、集成开发工具等功能。作为一种新型的独立包管理工具集,如意玲珑主要提供分层与隔离的运行环境,来解决传统包管理系统强依赖导致的兼容性问题,以及权限松散导致的安全问题。减少不同操作系统下分发时的打包次数,做到“一个架构,一次构建”,为Linux生态发展提供了坚实的基础。</p>
<p> </p>
<section data-role="outer">
<section>
<section>
<section>
<section>
<h1 style="text-align: center;"><strong data-brushtype="text">如意玲珑发行版适配进展</strong></h1>
</section>
</section>
</section>
</section>
</section>
<ul>
<li>在openEuler系统上如意玲珑已集成到Eur仓库,添加该仓库后,用户手动安装使用;</li>
<li>在UOS 1070系统上添加如意玲珑外网仓库到系统仓库后,用户手动安装使用;</li>
<li>如意玲珑已集成到deepin V23系统,用户可直接使用;</li>
<li>目前适配了openKylin、麒麟专业版、Ubuntu 24.04和Debian 12。对于即将发布的1.6版本,将提供各发行版的独立仓库,用户可以手动添加使用。</li>
</ul>
<p>近日,如意玲珑官网使用手册新增openEuler添加如意玲珑仓库源介绍,诚邀您抢先体验。</p>
<p> </p>
<section data-role="paragraph">
<section data-role="outer">
<section>
<section>
<section>
<section>
<h1 style="text-align: center;"><strong>openEuler安装如意玲珑</strong></h1>
</section>
</section>
</section>
</section>
</section>
<section></section>
</section>
<section data-role="paragraph">
<section data-role="list">本文适用于1.5.6版本, 请使用 ll-cli --version 检查您的如意玲珑程序版本。 </p>
<section></section>
<h2><strong>1、如意玲珑组成</strong></h2>
<ul class="list-paddingleft-1">
<li>
<section>ll-builder 用来构建和调试如意玲珑应用,由 linglong-builder 提供; </section>
</li>
<li>
<section>ll-box 沙箱容器,由 linglong-box 提供; </section>
</li>
<li>
<section>ll-cli 管理和运行如意玲珑应用,由 linglong-bin 提供。 </section>
</li>
</ul>
<p> </p>
<h2><strong>2、openEuler添加如意玲珑仓库源并更新仓库信息</strong></h2>
</section>
</section>
<blockquote><p>sudo curl -o /etc/yum.repos.d/linglong.repo -L https://eur.openEuler.openatom.cn/coprs/kamiyadm/linglong/repo/openEuler-24.03_LTS/kamiyadm-linglong-openEuler-24.03_LTS.repo</p>
<p>sudo dnf update</p></blockquote>
<p> </p>
<h2><strong>3、安装玲珑环境</strong></h2>
<blockquote><p>sudo dnf install linglong-builder linglong-box linglong-bin</p></blockquote>
<p> </p>
<h2><strong>4、安装桌面环境(可选) </strong></h2>
<p>如果想运行gui类型应用,需要安装桌面环境,仅运行终端类型应用不需要安装桌面环境。这里以安装DDE为例,也支持在其他桌面环境下使用,如KDE,GNOME。</p>
<blockquote><p>sudo dnf install dde</p>
<p>sudo systemctl set-default graphical.target</p></blockquote>
<h2><strong>5、重启系统 </strong></h2>
<blockquote><p>sudo reboot</p></blockquote>
<p> </p>
<section>
<h1 style="text-align: center;"><strong data-brushtype="text">openEuler使用如意玲珑</strong></h1>
</section>
<h2><strong>1、使用构建工具ll-builder</strong></h2>
<section><strong> </strong></section>
<section><strong>1.1创建项目 </strong></section>
<section><strong> </strong></section>
<section>创建如意玲珑项目命令:ll-builder create</section>
<section></section>
<p>查看 ll-builder create 命令的帮助信息:</p>
<blockquote><p>ll-builder create --help</p></blockquote>
<p>ll-builder create 命令的帮助信息如下:</p>
<blockquote>
<section>Usage: ll-builder create <org.deepin.demo> </section>
<section>Options: </section>
<section>-v, --verbose show detail log </section>
<section>-h, --help Displays help on commandline options. </section>
<section>--help-all Displays help including Qt specific options. </section>
<section>Arguments: </section>
<section>create create build template project </section>
<section>name project name</section>
</blockquote>
<section></section>
<p data-width="70%">ll-builder create命令根据输入的项目名称,在当前目录创建对应的文件夹,同时生成构建所需的 linglong.yaml模板文件。示例:</p>
<blockquote><p>ll-builder create org.deepin.hello</p></blockquote>
<p> </p>
<section>
<section>
<section>命令输出如下:</section>
</section>
</section>
<p> </p>
<blockquote>
<section>org.deepin.hello/</section>
<section>└── linglong.yaml</section>
</blockquote>
<p> </p>
<p><strong>1.2 编辑linglong.yaml</strong></p>
<p>linglong.yaml 文件语法的版本:version: "1"</p>
<p>软件包元信息配置:</p>
<blockquote><p>package:<br />
id: org.deepin.hello<br />
name: hello<br />
version: 0.0.0.1<br />
kind: app<br />
description: /<br />
simple demo.</p></blockquote>
<p> </p>
<p>基础环境,最小的根文件系统:</p>
<blockquote><p>base: org.deepin.foundation/23.0.0</p></blockquote>
<p>如意玲珑应用的启动命令:</p>
<blockquote><p>command: </blockquote>
<p>在容器内构建项目需要的命令:</p>
<blockquote><p>build: /<br />
echo 'hello' #some operation to build this project</p></blockquote>
<p>完整的linglong.yaml配置内容如下:</p>
<blockquote><p>version: "1"</p>
<p>package:<br />
id: org.deepin.hello<br />
name: your name #set your application name<br />
version: 0.0.0.1 #set your version<br />
kind: app<br />
description: /<br />
your description #set a brief text to introduce your application.</p>
<p>command: #the commands that your application need to run.</p>
<p>base: org.deepin.foundation/23.0.0 #set the base environment, this can be changed.</p>
<p>#set the runtime environment if you need, a example of setting deepin runtime is as follows.<br />
#runtime:<br />
#org.deepin.Runtime/23.0.1</p>
<p>#set the source if you need, a simple example of git is as follows.<br />
#sources:<br />
# - kind: git<br />
# url: https://github.com/linuxdeepin/linglong-builder-demo.git<br />
# version: master\n<br />
# commit: a3b89c3aa34c1aff8d7f823f0f4a87d5da8d4dc0</p>
<p>build: /<br />
echo 'hello' #some operation to build this project</p></blockquote>
<p> </p>
<p><strong>1.3 构建应用</strong></p>
<p>ll-builder build命令用来构建如意玲珑应用。</p>
<p>查看ll-builder build命令的帮助信息:</p>
<blockquote><p>ll-builder build --help</p></blockquote>
<p>ll-builder build命令的帮助信息如下:</p>
<blockquote>
<section> --exec <command> run exec than build script</section>
<section> --offline only use local files. This implies --skip-fetch-source</section>
<section> and --skip-pull-depend</section>
<section> --skip-fetch-source skip fetch sources</section>
<section> --skip-pull-depend skip pull dependency</section>
<section> --skip-run-container skip run container. This implies skip-commit-output</section>
<section> --skip-commit-output skip commit build output</section>
<section> --arch <arch> set the build arch</section>
<section> </section>
<section>Arguments:</section>
<section>build build project</section>
</blockquote>
<p>ll-builder build命令必须运行在工程的根目录,即 linglong.yaml文件所在位置。以如意玲珑项目 org.deepin.demo为例,构建如意玲珑应用主要步骤如下:</p>
<p><strong>● 进入到 org.deepin.demo项目工程目录:</strong></p>
<blockquote><p>cd org.deepin.demo</p></blockquote>
<p><strong>● 执行 ll-builder build命令将开始构建如意玲珑应用:</strong></p>
<blockquote><p>ll-builder build</p></blockquote>
<p>构建完成后,构建内容将自动提交到本地ostree缓存中。</p>
<p> </p>
<p><strong>1.4 验证应用</strong></p>
<p>ll-builder run命令用来运行验证应用。</p>
<p>查看ll-builder run命令的帮助信息:</p>
<blockquote><p>ll-builder run --help</p></blockquote>
<p>ll-builder run命令的帮助信息如下:</p>
<blockquote>
<section>Usage: ll-builder run</section>
<section> </section>
<section>Options:</section>
<section> -v, --verbose show detail log</section>
<section> -h, --help Displays this help.</section>
<section> --exec <exec> run exec than build script</section>
<section> </section>
<section>Arguments:</section>
<section>run run project</section>
</blockquote>
<p>在linglong.yaml文件所在位置,执行ll-builder run即可运行该应用。</p>
<p>示例项目org.deepin.demo运行结果如下:</p>
<blockquote><p>hello</p></blockquote>
<p>也可从构建缓存中导出成离线文件,通过客户端工具ll-cli安装使用。</p>
<p> </p>
<p><strong>1.5导出离线文件</strong></p>
<p>ll-builder提供了子命令export来导出离线文件(.uab/.layer)。</p>
<p>查看ll-builder export命令的帮助信息:</p>
<blockquote><p>ll-builder export --help</p></blockquote>
<p>ll-builder export命令的帮助信息如下:</p>
<blockquote>
<section>Usage: ll-builder </section>
<section> </section>
<section>Options:</section>
<section> -v, --verbose show detail log (deprecated, use QT_LOGGING_RULES)</section>
<section> -h, --help Displays help on commandline options.</section>
<section> --help-all Displays help including Qt specific options.</section>
<section> -f, --file <path> file path of the linglong.yaml (default is ./linglong.yaml)</section>
<section> -i, --icon <path> uab icon (optional)</section>
<section> -l, --layer export layer file</section>
</blockquote>
<p>在linglong.yaml文件所在位置,执行以下命令即可将构建缓存导出离线文件:</p>
<blockquote><p>ll-builder export --layer</p></blockquote>
<p>执行成功后,将在当前目录下,生成两个以.layer结尾的文件:</p>
<blockquote>
<section>org.deepin.demo_0.0.0.1_x86_64_develop.layer </section>
<section>org.deepin.demo_0.0.0.1_x86_64_binary.layer</section>
</blockquote>
<p>包含binary(此前这部分名为runtime)的部分为应用的主要运行内容,develop 在 binary 的基础上保留调试环境(如调试符号)。</p>
<p> </p>
<h2><strong>2、使用客户端ll-cli</strong></h2>
<p><strong>2.1 安装玲珑应用</strong></p>
<p><strong>2.1.1使用ll-cli install安装</strong></p>
<p>首先查看ll-cli install命令的帮助信息:</p>
<blockquote><p>ll-cli install --help</p></blockquote>
<p>ll-cli install命令的帮助信息如下:</p>
<blockquote><p>linglong CLI<br />
A CLI program to run application and manage linglong pagoda and tiers.</p>
<p>Usage:<br />
ll-cli [--json] --version<br />
ll-cli [--json] run APP [--no-dbus-proxy] [--dbus-proxy-cfg=PATH] ( [--file=FILE] | [--url=URL] ) [--]
ll-cli [--json] ps<br />
ll-cli [--json] exec PAGODA [--working-directory=PATH] [--] COMMAND...<br />
ll-cli [--json] enter PAGODA [--working-directory=PATH] [--]
ll-cli [--json] kill PAGODA<br />
ll-cli [--json] [--no-dbus] install TIER<br />
ll-cli [--json] uninstall TIER [--all] [--prune]
ll-cli [--json] upgrade TIER<br />
ll-cli [--json] search [--type=TYPE] [--dev] TEXT<br />
ll-cli [--json] [--no-dbus] list [--type=TYPE]
ll-cli [--json] repo modify [--name=REPO] URL<br />
ll-cli [--json] repo show<br />
ll-cli [--json] info TIER<br />
ll-cli [--json] content APP</p>
<p>Arguments:<br />
APP Specify the application.<br />
PAGODA Specify the pagodas (container).<br />
TIER Specify the tier (container layer).<br />
URL Specify the new repo URL.<br />
TEXT The text used to search tiers.</p>
<p>Options:<br />
-h --help Show help information of ll-cli.<br />
--version Show version.<br />
--json Use json to output command result, you can get the description of the output refer to linglong api documentation(/usr/share/linglong/api/api.json).<br />
--no-dbus Use peer to peer DBus, this is used only in case that DBus daemon is not available.<br />
--no-dbus-proxy Do not enable linglong-dbus-proxy.<br />
--dbus-proxy-cfg=PATH Path of config of linglong-dbus-proxy.<br />
--file=FILE you can refer to https://linglong.dev/guide/ll-cli/run.html to use this parameter.<br />
--url=URL you can refer to https://linglong.dev/guide/ll-cli/run.html to use this parameter.<br />
--working-directory=PATH Specify working directory.<br />
--type=TYPE Filter result with tiers type. One of "runtime", "app" or "all".
--state=STATE Filter result with the tiers install state. Should be "local" or "remote".
--prune Remove application data if the tier is an application and all version of that application has been removed.<br />
--dev include develop tiers in result.</p>
<p>Subcommands:<br />
run Run an application.<br />
ps List all pagodas.<br />
exec Execute command in a pagoda.<br />
enter Enter a pagoda.<br />
kill Stop applications and remove the pagoda.<br />
install Install tier(s).<br />
uninstall Uninstall tier(s).<br />
upgrade Upgrade tier(s).<br />
search Search for tiers.<br />
list List known tiers.<br />
repo Display or modify information of the repository currently using.<br />
info Display the information of layer<br />
content Display the exported files of application</p></blockquote>
<p>从玲珑仓库安装玲珑应用,以百度网盘为例:</p>
<blockquote><p>ll-cli install com.baidu.baidunetdisk</p></blockquote>
<p>ll-cli install命令需要输入应用完整的id,若仓库有多个版本则会默认安装最高版本。安装指定版本需在 appid后附加对应版本号:</p>
<blockquote><p>ll-cli install com.baidu.baidunetdisk/4.17.7.0</p></blockquote>
<p>应用安装完成后,客户端会显示安装结果。</p>
<p> </p>
<p><strong>2.1.2从本地通过离线文件安装应用</strong></p>
<p>以构建示例org.deepin.demo为例:</p>
<p>安装.layer 文件:</p>
<blockquote>
<ul>
<li>ll-cli install ./org.deepin.demo_0.0.0.1_x86_64_binary.layer</li>
</ul>
</blockquote>
<p>查看安装是否成功命令:</p>
<blockquote>
<ul>
<li>ll-cli list | grep org.deepin.demo</li>
</ul>
</blockquote>
<p> </p>
<p><strong>2.2 运行玲珑应用</strong></p>
<p>如果有桌面环境的情况下,可以通过双击启动器下的图标运行应用,或通过终端命令行运行,使用run命令运行应用:</p>
<blockquote><p>ll-cli run org.deepin.demo</p></blockquote>
<p> </p>
<h1 style="text-align: center;"> <strong>如意玲珑生态共建</strong></h1>
<p>已有数十家企业、数十位个人开发者参与如意玲珑应用生态贡献,目前已成功适配超过2000款玲珑应用,这些应用将逐步上架至如意玲珑网页版商店、deepin以及统信应用商店,为广大用户提供更丰富的选择和更便捷的体验。诚挚邀请广大伙伴及用户加入如意玲珑生态共建,携手推动Linux生态的进步和发展。</p>
<p>如意玲珑网页版商店地址:https://store.linglong.dev/ </p>
<p> </p>
<h1><strong>附录:</strong></h1>
<p>(1)deepin 历史版本镜像(含 deepin V15)</p>
<p>(2)如意玲珑社区官网</p>
<p>(3)如意玲珑代码仓库</p>
<p> </p>
<p style="text-align: right;">转载请注明出处</p>
</div>
頁:
[1]