-
Notifications
You must be signed in to change notification settings - Fork 4
/
build.sh
executable file
·62 lines (55 loc) · 1.62 KB
/
build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/bin/bash
sudo apt-get -y update
sudo apt-get -y upgrade
# Dependencies
sudo apt-get -y install \
awscli \
build-essential \
curl \
ffmpeg \
git \
libncurses5 \
libnginx-mod-http-dav-ext \
libtinfo5 \
net-tools \
nginx \
nginx-extras \
ninja-build \
openssh-server \
python \
python3-pip \
wget
# Shaka Packager with HTTP upload
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH="$PATH:$PWD/depot_tools"
mkdir shaka_packager
cd shaka_packager
# grab the repo containing the HTTP upload branch
gclient config https://github.com/joeyparrish/shaka-packager.git --name=src --unmanaged
# checkout the HTTP branch
gclient sync -r 224b9e41822b02bfe99c74cb65c608674f1b369f
cd src
# build shaka player
ninja -C out/Release
# verify the build
./out/Release/packager --version
# save the binary file to local bin for global use
sudo install -m 755 ./out/Release/packager /usr/local/bin/packager
cd ../..
# Shaka Streamer with HTTP upload
git clone https://github.com/joeyparrish/shaka-streamer.git
sudo snap install google-cloud-sdk --classic
# install s3-upload-proxy
git clone https://github.com/fsouza/s3-upload-proxy.git
cd s3-upload-proxy
# go to working commit
git checkout 793d1164921d6e42b4bec26686e76001995f218b
cd ..
# install go
wget https://golang.org/dl/go1.15.5.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.15.5.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
sudo install -m 755 /usr/local/go/bin/go /usr/local/bin/go
go version
# install Big Buck Bunny as sample file
wget "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"