Name
====
opm - OpenResty Package Manager
Table of Contents
=================
* [Name](#name)
* [Status](#status)
* [Synopsis](#synopsis)
* [Description](#description)
* [Usage](#usage)
* [Global Installation](#global-installation)
* [Local Installation](#local-installation)
* [HTTP Proxy Support](#http-proxy-support)
* [Author Workflow](#author-workflow)
* [File dist.ini](#file-distini)
* [name](#name)
* [abstract](#abstract)
* [version](#version)
* [author](#author)
* [license](#license)
* [requires](#requires)
* [repo_link](#repo_link)
* [is_original](#is_original)
* [lib_dir](#lib_dir)
* [exclude_files](#exclude_files)
* [main_module](#main_module)
* [doc_dir](#doc_dir)
* [File .opmrc](#file-opmrc)
* [github_account](#github_account)
* [github_token](#github_token)
* [upload_server](#upload_server)
* [download_server](#download_server)
* [Version Number Handling](#version-number-handling)
* [Installation](#installation)
* [For opm](#for-opm)
* [Security Considerations](#security-considerations)
* [Credit](#credit)
* [TODO](#todo)
* [Author](#author)
* [Copyright and License](#copyright-and-license)
Status
======
Experimental.
Synopsis
========
For library users:
```bash
# show usage
opm --help
# search package names and abstracts with the user pattern "lock".
opm search lock
# search package names and abstracts with multiple patterns "lru" and "cache".
opm search lru cache
# install a package named lua-resty-foo under the name of some_author
opm get some_author/lua-resty-foo
# get a list of lua-resty-foo packages under all authors.
opm get lua-resty-foo
# show the details of the installed package specified by name.
opm info lua-resty-foo
# show all the installed packages.
opm list
# upgrade package lua-resty-foo to the latest version.
opm upgrade lua-resty-foo
# update all the installed packages to their latest version.
opm update
# uninstall the newly installed package
opm remove lua-resty-foo
```
All the commands can follow the `--cwd` option to work in the current working
directory (under ./resty/modules/) instead of the system-wide location.
```bash
# install into ./resty_modules/ instead of the system-wide location:
opm --cwd get foo/lua-resty-bar
# check the locally installed packages under ./resty_modules/
opm --cwd list
# remove the locally installed packages under ./resty_modules/
opm --cwd remove lua-resty-bar
```
For library authors:
```bash
cd /path/to/lua-resty-foo/
opm build
# optional:
# cd lua-resty-foo-VERSION/ && opm server-build
# you may need to edit the ~/.opmrc file to set up your github
# personal access tokens. the first run of "opm upload" will create
# a boilerplate ~/.opmrc file for you.
opm upload
# cleaning up the leftovers of the opm build command.
opm clean dist
```
Description
===========
`opm` is the official OpenResty package manager, similar to
Perl's CPAN and NodeJS's npm in rationale.
We provide both the `opm` client-side command-line utility and
the server-side application for the central package repository in this
GitHub code repository.
The `opm` command-line utility can be used by OpenResty users to download
packages published on the central `opm` server (i.e., `opm.openresty.org`).
It can also be used to package and upload the OpenResty package to the server
for package authors and maintainers. You can find the source of `opm` under
the `bin/` directory. It is currently implemented as a standalone Perl script.
The server side web application is built upon OpenResty and written in Lua.
You can find the server code under the `web/` directory.
Unlike many other package management systems like `cpan`, `luarocks`, `npm`,
or `pip`. Our `opm` adopts a package naming discipline similar to `github`, that
is, every package name should be qualified by a publisher ID, as in
`agentzh/lua-resty-foo` where `agentzh` is the publisher ID while `lua-resty-foo`
is the package name itself. This naming requirement voids the temptation of
occupying good package names and also allows multiple same-name libraries to
coexist in the same central server repository. It is up to the user to decide
which library to install (or even install multiple forks of the same library
in different projects of hers). For simplicity, we simply map the GitHub
user IDs and organization IDs to the publisher IDs for `opm`. For this reason,
we use the GitHub personal access tokens (or oauth tokens) to authenticate
our package publishers. This also eliminates the sign-up process for `opm`
package authors altogether.
`opm` has built-in support for the `restydoc` tool, that is, the documentation
of the packages installed via `opm` is already indexed by `restydoc` and can
be viewed directly on the terminal with the `restydoc` tool.
`opm` currently only supports pure Lua libraries but we will add support for
Lua libraries in pure C or with some C components very soon. The vision is
to also add support for redistributing 3rd-party NGINX C modules as dynamic
NGINX modules via `opm` in the future. The OpenResty world consists of various
different kinds of "modules" after all.
We also have plans to allow the user to install LuaRocks packages via `opm`
through the special user ID `luarocks`. It poses a risk of installing
an OpenResty-agnostic Lua module which blocks the NGINX worker processes
horribly on network I/O, nevertheless, as the developers of `opm`, we always like choices,
especially those given to our users.
[Back to TOC](#table-of-contents)
Usage
=====
```
opm [options] command package...
Options:
-h
--help Print this help.
--install-dir=PATH Install into the specified PATH directory instead of the system-wide
OpenResty installation tree containing this tool.
--cwd Install into the current working directory under ./resty_modules/
instead of the system-wide OpenResty installation tree containing
this tool.
Commands:
build Build from the current working directory a package tarball ready
for uploading to the server.
clean ARGUMENT... Do clean-up work. Currently the valid argument is "dist", which
cleans up the temporary files and directories created by the "build"
command.
info PACKAGE... Output the detailed information (or meta data) about the specified
packages. Short package names like "lua-resty-lock" are acceptable.
get PACKAGE... Fetch and install the specified packages. Fully qualified package
names like "openresty/lua-resty-lock" are required. One can also
specify a version constraint like "=0.05" and ">=0.01".
list List all the installed packages. Both the package names and versions
are displayed.
remove PACKAGE... Remove (or uninstall) the specified packages. Short package names
like "lua-resty-lock" are acceptable.
search QUERY... Search on the server for packages matching the user queries in their
names or abstracts. Multiple queries can be specified and they must
fulfilled at the same time.
server-build Build a final package tarball ready for distribution on the server.
This command is usually used by the server to verify the uploaded
package tarball.
update Update all the installed packages to their latest version from
the server.
upgrade PACKAGE... Upgrade the packages specified by names to the latest version from
the server. Short package names like "lua-resty-lock" are acceptable.
upload Upload the package tarball to the server. This comma
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
一步安装openresty (2000个子文件)
luajit.1 2KB
nginx.8 5KB
acc 201B
ACKNOWLEDGEMENTS 87B
action_macros 2KB
action_replacements 77B
action_types 326B
array 535B
bn-c64xplus.asm 10KB
srp_verifier.txt.attr 21B
AUTHOR 38B
AUTHORS 717B
auto_config 511B
autogen 320B
msvcbuild.bat 4KB
ps4build.bat 4KB
xb1build.bat 3KB
xedkbuild.bat 3KB
psvitabuild.bat 3KB
bcc 1KB
makefile.bcc 530B
makefile.bcc 382B
makefile.bcc 365B
build 12KB
built 0B
ngx_http_lua_socket_tcp.c 179KB
ngx_stream_lua_lex.c 179KB
ngx_http_lua_lex.c 179KB
ngx_stream_lua_socket_tcp.c 174KB
minilua.c 170KB
ngx_http_upstream.c 163KB
ngx_http_core_module.c 140KB
ngx_http_grpc_module.c 137KB
ngx_http_proxy_module.c 136KB
ngx_http_v2.c 133KB
ngx_event_openssl.c 126KB
ngx_http_v2_huff_decode.c 126KB
speed.c 120KB
ngx_http_lua_util.c 117KB
s_server.c 116KB
s_client.c 115KB
ngx_http_fastcgi_module.c 111KB
ngx_resolver.c 110KB
ngx_http_upstream_check_module.c 109KB
ngx_http_mp4_module.c 105KB
ngx_stream_lua_util.c 95KB
ngx_http_request.c 95KB
lj_record.c 87KB
dtoa.c 86KB
ca.c 84KB
aes_core.c 80KB
lj_parse.c 79KB
ngx_http_ssi_filter_module.c 78KB
lj_asm.c 73KB
apps.c 73KB
ngx_http_uwsgi_module.c 72KB
ngx_http_lua_pipe.c 70KB
lj_opt_fold.c 70KB
ngx_http_file_cache.c 69KB
ngx_event_openssl_stapling.c 66KB
ngx_http_variables.c 65KB
ngx_stream_proxy_module.c 64KB
lj_crecord.c 61KB
ngx_http_scgi_module.c 60KB
ngx_http_parse.c 59KB
ngx_http_v2_filter_module.c 57KB
bss_dgram.c 57KB
lj_cparse.c 57KB
req.c 51KB
ngx_http_lua_shdict.c 51KB
ngx_http.c 51KB
ngx_cache_purge_module.c 50KB
ngx_stream_lua_shdict.c 50KB
ocsp.c 50KB
ngx_http_log_module.c 49KB
ngx_http_lua_directive.c 47KB
ngx_http_lua_subrequest.c 47KB
s_cb.c 47KB
ngx_stream_lua_socket_udp.c 47KB
lua_cjson.c 46KB
ngx_http_lua_module.c 46KB
ngx_mail_auth_http_module.c 44KB
cms.c 44KB
aria.c 44KB
ngx_string.c 44KB
ngx_http_script.c 44KB
ngx_http_geo_module.c 43KB
ngx_http_memc_response.c 42KB
ngx_http_image_filter_module.c 42KB
ngx_stream_geo_module.c 42KB
lj_alloc.c 41KB
ngx_http_lua_socket_udp.c 41KB
lj_ccall.c 41KB
ngx_stream_log_module.c 41KB
aes_x86core.c 40KB
ngx_connection.c 40KB
ngx_postgres_module.c 40KB
ngx_http_charset_filter_module.c 40KB
x509.c 39KB
lj_ffrecord.c 39KB
共 2000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 20
资源评论
- Ba~ba~tang2021-10-24你好,下载了,看起来和官网上的差不多,你这个如何自定义版本?
- weixin_476433692022-08-19资源是宝藏资源,实用也是真的实用,感谢大佬分享~
伊格洛斯
- 粉丝: 4147
- 资源: 27
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 基于matlab开发的根据rvm回归模型自己编的matlab程序.rar
- 高效C++学生成绩管理系统:教育技术+C++17编程+数据管理+教务自动化
- 基于matlab开发的Tipping的相关向量机RVM的回归MATLAB程序,有英文注释,可以运行.rar
- 一个点击正反转程序实例,可实现案件电机正反转
- 搜索链接淘特搜索引擎共享版-tot-search-engine.rar
- 第十八届全国大学生智能汽车竞赛 摄像头组/镜头组
- 基于matlab开发的AUV惯性导航系统matlab仿真程序,包括轨迹生成、gps和sins组合、gps和dvl组合.rar
- 基于SSM的“个性化电子相册”的设计与实现.zip
- 如何在撰写科研文献时,使用ai工具辅助去完成科研工作
- 吉林大学计组笔记 自用 基于b站翼云图灵的课.pdf
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功