-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
423 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,5 +2,5 @@ | |
# = Project-Specific = | ||
# ==================== | ||
|
||
# generate man pages | ||
# generated man pages | ||
*.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
class Docker < Requirement | ||
fatal true | ||
default_formula "docker" | ||
|
||
satisfy { which "docker" } | ||
|
||
def message | ||
"Docker is required for this package." | ||
end | ||
end | ||
|
||
class Citustools < Formula | ||
desc "Tools and config used in Citus Data projects." | ||
homepage "https://github.com/citusdata/tools" | ||
url "https://github.com/citusdata/tools/archive/v0.1.0.tar.gz" | ||
sha256 "dc773c21989aa4d716b653ed7542d333f63f14a10d470f9a24fe12fac836b262" | ||
|
||
depends_on "uncrustify" | ||
depends_on Docker | ||
|
||
def install | ||
system "make", "install", "prefix=#{prefix}", "sysconfdir=#{etc}" | ||
end | ||
|
||
test do | ||
system "true" | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# needed variables will be passed in via top-level Makefile | ||
|
||
INSTALL := install -c | ||
INSTALL_DATA := $(INSTALL) -m 644 | ||
INSTALL_SCRIPT := $(INSTALL) -m 755 | ||
|
||
POD2MAN := pod2man --center "Citus Data Tools" -r "Citus Data" | ||
MANPAGES := citus_package.1 | ||
|
||
all: man | ||
|
||
man: $(MANPAGES) | ||
|
||
%.1: % | ||
$(POD2MAN) --quotes=none --section 1 $< $@ | ||
|
||
clean: | ||
rm -f *.1 | ||
|
||
installdirs: | ||
$(INSTALL) -d $(DESTDIR)$(bindir) $(DESTDIR)$(pkgsysconfdir) $(DESTDIR)$(mandir)/man1 | ||
|
||
install: all installdirs | ||
$(INSTALL_SCRIPT) citus_package $(DESTDIR)$(bindir) | ||
$(INSTALL_DATA) $(MANPAGES) $(DESTDIR)$(mandir)/man1 | ||
|
||
.PHONY: all man clean installdirs install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Packaging | ||
|
||
`citus_package` encapsulates complex packaging logic to ensure team members can easily build release, nightly, and custom packages for any Citus project on any supported OS. Under the hood, it's using [Docker][1] to guarantee some level of repeatability. | ||
|
||
## Getting Started | ||
|
||
`citus_package` requires `docker` v1.10 or greater. | ||
|
||
`make install` to install the script and a man page. `man citus_package` for more details. | ||
|
||
## Usage | ||
|
||
Ensure your `GITHUB_TOKEN` environment variable is properly set (see the man page if you're not sure how to do that). Make sure Docker is running, then you're off to the races! For example, build a `citus` nightly on CentOS 7, Debian Jessie and Ubuntu Xenial like so: `citus_package -p el/7 -p debian/jessie -p ubuntu/xenial citus nightly` | ||
|
||
[1]: https://www.docker.com |
Oops, something went wrong.