LoginSignup
4
3

More than 5 years have passed since last update.

プライベートyumリポジトリの作成

Posted at

Install

$ yum -y install createrepo
$ yum -y install --enablerepo=epel repoview

Setup

$ mkdir amzn/RPMS/2014.09
# amzn/RPMS/2014.09 へ作成したRPMを置く
$ createrepo amzn/RPMS/2014.09

Build

$ repoview --title="Private binary package for Amazon Linux" \
   --url="<private url>/amzn/RPMS/2014.09" \
   ./amzn/RPMS/2014.09/
$ tree -I '*.html|*.rpm' amzn/RPMS/x86_64/
amzn/RPMS/x86_64/
├── repodata
│   ├── 099b49f620f4f7a54ec082303e93d6b3a21364dbe1acaa7c51f0c34643f0b657-primary.xml.gz
│   ├── 11812ceb52190748d0bc191d1c6bf62e3590439938bb77612a09ea001c8da5f7-primary.sqlite.bz2
│   ├── 219bee792ce44c7128bff6ee7f0d62bfc9575f41d2808f8d1c587d739e937543-filelists.xml.gz
│   ├── 4ade99f9fc01966e8eaa8cd6e192470a4492d32aa68cc484ad230b793dace4e0-filelists.xml.gz
│   ├── 555cb5c8976145f92541f68d2c6d124a595ebe7056bf99e382b55ace29f039ec-filelists.sqlite.bz2
│   ├── 6556d255f7fbc62ae724e766ab8dd7fdeef3b740f56217a15d7bf45c6025ea73-primary.sqlite.bz2
│   ├── 74e65497632d24e2017cd6ad0d01a4ad3b4f980d2cf84206db45933ace86e1bd-other.xml.gz
│   ├── 9173d0b3970896d99527f420281a0f79db350eec459b044dab77514f16233065-other.sqlite.bz2
│   ├── 977b7bf8f3f4f138676f3ce54ff8d2edc1cfaa672f2c7b9dabecfdcc660c0393-other.sqlite.bz2
│   ├── aa48c1ffea66fe0ac929fc05b4b735f3b902d18171e88c8c46db05e8246ab4bc-other.xml.gz
│   ├── b4eea0f3be57d7b5c428c8878a3ff2d755c83124830e91f541f6a961145bdd9f-filelists.sqlite.bz2
│   ├── d09fc3f385fc7d095bc7ca3b61f500e0ac552bced386ff1140cbe89453b80e38-primary.xml.gz
│   └── repomd.xml
└── repoview
    ├── latest-feed.xml
    ├── layout
    │   └── repostyle.css
    └── state.sqlite

repoview/ 以下に静的なHTMLが作成されるのでブラウザから参照可能になるます。

How to use

$ cat /etc/yum.repos.d/private.repo 
[private]
name=Private binary package - $basearch
baseurl=<private url>/amzn/RPMS/2014.09
enabled=0
gpgcheck=0

※ GPGKeyを作成していないのはよろしくないです

4
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
3