Skip to content

Commit

Permalink
Updating release process to fit documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
kontsevoy committed Jun 20, 2016
1 parent 93a3dfa commit 8987e07
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ $(eval BUILDFLAGS := $(ADDFLAGS) -ldflags -w)
#
.PHONY: all
all: setver teleport tctl tsh assets
cp -f build.assets/release.mk $(BUILDDIR)/Makefile

.PHONY: tctl
tctl:
Expand Down
28 changes: 28 additions & 0 deletions build.assets/release.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This file is distributed with every binary Teleport tarball
BINDIR=/usr/local/bin
VARDIR=/var/lib/teleport
WEBDIR=/usr/local/share/teleport

#
# sudo make install: installs Teleport into a UNIX-like OS
#
.PHONY: install
install: sudo
mkdir -p $(VARDIR) $(WEBDIR) $(BINDIR)
cp -f teleport tctl tsh $(BINDIR)/
cp -fr app index.html $(WEBDIR)/

#
# sudo make uninstall: removes Teleport
#
.PHONY: uninstall
uninstall: sudo
rm -rf $(VARDIR) $(WEBDIR) $(BINDIR)/tctl $(BINDIR)/teleport $(BINDIR)/tsh


# helper: makes sure it runs as root
.PHONY:sudo
sudo:
@if [ $$(id -u) != "0" ]; then \
echo "ERROR: You must be root" && exit 1 ;\
fi

0 comments on commit 8987e07

Please sign in to comment.