{"id":30237696,"url":"https://github.com/devopshq/luarocks-artifactory","last_synced_at":"2025-08-15T02:07:41.317Z","repository":{"id":46919405,"uuid":"316254349","full_name":"devopshq/luarocks-artifactory","owner":"devopshq","description":"Add luarock support to Artifactory","archived":false,"fork":false,"pushed_at":"2021-09-21T13:26:07.000Z","size":9,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2023-02-26T17:52:40.920Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://gitlab.com/devopshq/luarocks-artifactory","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devopshq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-11-26T14:28:00.000Z","updated_at":"2023-02-12T13:36:40.000Z","dependencies_parsed_at":"2022-08-29T22:31:23.474Z","dependency_job_id":null,"html_url":"https://github.com/devopshq/luarocks-artifactory","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"purl":"pkg:github/devopshq/luarocks-artifactory","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devopshq%2Fluarocks-artifactory","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devopshq%2Fluarocks-artifactory/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devopshq%2Fluarocks-artifactory/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devopshq%2Fluarocks-artifactory/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devopshq","download_url":"https://codeload.github.com/devopshq/luarocks-artifactory/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devopshq%2Fluarocks-artifactory/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270511293,"owners_count":24597666,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-15T02:00:12.559Z","response_time":110,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-08-15T02:07:38.445Z","updated_at":"2025-08-15T02:07:41.288Z","avatar_url":"https://github.com/devopshq.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Luarocks repository in JFrog Artifactory\n[Jfrog Artifactory] does not support [Luarocks] repository layout yet. This repository adds a workaround to store\nluarocks in Artifactory.\n\nIt comes in handy if:\n- you create Lua modules (*rocks*)\n- you can't store them at luarocks.org public repo\n- you have an Artifactory instance\n\n## Replicating Luarocks server\nLuarocks is a [static HTTP server with index and manifest files]. It's easy to replicate its functions using an \nArtifactory repository with generic layout.\n\nTo create or update Luarocks index and manifests, you need to do the following:\n1. Create a new repository in Artifactory (for example, `myluarocks.snapshot`).\n2. Upload a *rock* to this repository (manually or [via API]).\n3. Connect to `myluarocks.snapshot` via [WebDav].\n4. Create index and manifest with `luarock-admin make-manifest myluarocks.snapshot`.\n5. Wait until Artifactory reindexes the storage (5-15 seconds).\n\nNow you can use `myluarocks.snapshot` as a Luarocks server: \n```bash\nluarocks install --server=http://repo.example.com/artifactory/myluarocks.snapshot mypackage\n```\n**Note:** Our script forces no-dependencies mode for the sake of testing.\n\nIf you compile and upload all dependencies to `myluarocks.snapshot`, use `--only-server`:\n```bash\nluarocks install --only-server=http://repo.example.com/artifactory/myluarocks.snapshot mypackage\n```\n\n## Automation\nThis repository provides a shell script and a Dockerfile to update server manifests and test package installation.\n\n## Installation\nWe recommend using Docker to keep things isolated and leave your environment untouched.\n- Install [Docker]\n- Create an Artifactory repo\n- Deploy a *rock* for testing\n\n  **Important:** If your artifactory repo does not allow anonymous read access, add authentication by modifying curl\n  launch parameters:\n  ```bash\n  echo \"variables = {CURL = \\\"curl -H 'Authorization: Basic $BASE64_AUTH'\\\"}\" \u003e ~/.luarocks/config-${LUA_VERSION%.*}.lua\n  ```\n  OR (only with Luarocks 3.1+):\n  ```bash\n  luarocks config CURL=\"curl -H 'Authorization: Basic $BASE64_AUTH'\"\n  ```\n- Use this repo to create Luarocks manifests:\n```bash\ngit clone https://gitlab.com/devopshq/luarocks-artifactory.git\ncd luarocks-artifactory\ndocker build -t luarocks-artifactory .\ndocker run --rm --device /dev/fuse -v \"$(pwd)/create-luarocks.sh:/create-luarocks.sh\" --privileged luarocks-artifactory sh /create-luarocks.sh http://repo.example.com/artifactory myluarocks.snapshot username:password\nluarocks  install --server=http://repo.example.com/artifactory/myluarocks.snapshot mypackage\n```\n\n**Important:** Use `USER=root`. See [GitHub issue].\n\n## Usage\n```bash\n\u003e sh ./create-luarocks.sh --help\n\nUsage:\n    create-luarocks.sh ARTIFACTORY_URL REPO USERNAME:PASSWORD [--install-any pkg1 pgk2] [--install-all pkg1 pgk2]\n    ARTIFACTORY_URL             URL to Artifactory instance, e.g: https://repo.example.com/artifactory.\n    REPOSITORY                  Repository to store rocks and maintain index and manifest.\n    USERNAME:PASSWORD           Credentials for user with read, write and remove permissions to this repository (split by colon).\n    --install-all pkg1 pgk2     (optional) Try to install all specified packages.\n    --install-any pkg1 pgk2     (optional) Try to install any of specified packages.\n\nExamples:\n    create-luarocks.sh https://repo.example.com/artifactory myluarocks.snapshot deploy_user:password\n    create-luarocks.sh https://repo.example.com/artifactory myluarocks.snapshot deploy_user:password --install-any penlight rapidjson\n```\n\nSee [GitLab CI example](./.gitlab-ci.yml).\n\n## Scheduler and automation\nYou can schedule or use [Artifactory WebHook] to automate indexing.\n\n\n\n[Jfrog Artifactory]: https://jfrog.com/artifactory\n[Luarocks]: https://luarocks.org\n[static HTTP server with index and manifest files]: https://github.com/luarocks/luarocks/wiki/Hosting-binary-rocks\n[via API]: https://www.jfrog.com/confluence/display/JFROG/Artifactory+REST+API#ArtifactoryRESTAPI-DeployArtifact\n[WebDav]: https://www.jfrog.com/confluence/display/RTF/Using+WebDAV\n[Docker]: https://docs.docker.com/install\n[GitHub issue]: https://github.com/luarocks/luarocks/issues/901\n[Artifactory WebHook]: https://jfrog.com/blog/automation-using-webhooks-in-jfrog-artifactory","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevopshq%2Fluarocks-artifactory","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevopshq%2Fluarocks-artifactory","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevopshq%2Fluarocks-artifactory/lists"}