-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
34 changed files
with
836 additions
and
85 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
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,22 @@ | ||
#!/bin/bash | ||
|
||
if [[ ! -d signaling ]]; then | ||
cd 3rdparty | ||
fi | ||
if [[ ! -d signaling ]]; then | ||
echo "no 3rdparty" | ||
exit -1 | ||
fi | ||
if [[ ! -d ~/git/signaling ]]; then | ||
echo "no signaling" | ||
exit -1 | ||
fi | ||
|
||
echo "Copy signaling" | ||
cp -R signaling/* ~/git/signaling/ && (cd ~/git/signaling && git st) | ||
|
||
echo "Copy httpx-static" | ||
cp -R httpx-static/* ~/git/go-oryx/httpx-static/ && (cd ~/git/go-oryx && git st) | ||
|
||
echo "Copy srs-bench" | ||
cp -R srs-bench/* ~/git/srs-bench/ && (cd ~/git/srs-bench && git st) |
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,24 @@ | ||
|
||
############################################################ | ||
# build | ||
############################################################ | ||
FROM registry.cn-hangzhou.aliyuncs.com/ossrs/srs:dev AS build | ||
|
||
COPY . /tmp/signaling | ||
RUN cd /tmp/signaling && make | ||
RUN cp /tmp/signaling/objs/signaling /usr/local/bin/signaling | ||
RUN cp -R /tmp/signaling/www /usr/local/ | ||
|
||
############################################################ | ||
# dist | ||
############################################################ | ||
FROM centos:7 AS dist | ||
|
||
# HTTP/1989 | ||
EXPOSE 1989 | ||
# SRS binary, config files and srs-console. | ||
COPY --from=build /usr/local/bin/signaling /usr/local/bin/ | ||
COPY --from=build /usr/local/www /usr/local/www | ||
# Default workdir and command. | ||
WORKDIR /usr/local | ||
CMD ["./bin/signaling"] |
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,70 @@ | ||
#!/bin/bash | ||
|
||
SRS_GIT=$HOME/git/signaling | ||
SRS_TAG= | ||
|
||
# linux shell color support. | ||
RED="\\033[31m" | ||
GREEN="\\033[32m" | ||
YELLOW="\\033[33m" | ||
BLACK="\\033[0m" | ||
|
||
function NICE() { | ||
echo -e "${GREEN}$@${BLACK}" | ||
} | ||
|
||
function TRACE() { | ||
echo -e "${BLACK}$@${BLACK}" | ||
} | ||
|
||
function WARN() { | ||
echo -e "${YELLOW}$@${BLACK}" | ||
} | ||
|
||
function ERROR() { | ||
echo -e "${RED}$@${BLACK}" | ||
} | ||
|
||
################################################################################## | ||
################################################################################## | ||
################################################################################## | ||
if [[ -z $SRS_TAG ]]; then | ||
SRS_TAG=`(cd $SRS_GIT && git describe --tags --abbrev=0 --exclude release-* 2>/dev/null)` | ||
if [[ $? -ne 0 ]]; then | ||
echo "Invalid tag $SRS_TAG of $SRS_FILTER in $SRS_GIT" | ||
exit -1 | ||
fi | ||
fi | ||
|
||
NICE "Build docker for $SRS_GIT, tag is $SRS_TAG" | ||
|
||
git ci -am "Release $SRS_TAG" | ||
|
||
# For aliyun hub. | ||
NICE "aliyun hub release-v$SRS_TAG" | ||
|
||
echo "git push aliyun" | ||
git push aliyun | ||
|
||
git tag -d release-v$SRS_TAG 2>/dev/null | ||
echo "Cleanup tag $SRS_TAG for aliyun" | ||
|
||
git tag release-v$SRS_TAG; git push -f aliyun release-v$SRS_TAG | ||
echo "Create new tag $SRS_TAG for aliyun" | ||
echo "" | ||
|
||
NICE "aliyun hub release-vlatest" | ||
git tag -d release-vlatest 2>/dev/null | ||
echo "Cleanup tag latest for aliyun" | ||
|
||
git tag release-vlatest; git push -f aliyun release-vlatest | ||
echo "Create new tag latest for aliyun" | ||
|
||
# For github.com | ||
echo "git push origin" | ||
git push origin | ||
|
||
echo "git push origin $SRS_TAG" | ||
git push origin $SRS_TAG | ||
|
||
NICE "Update github ok" |
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
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
Oops, something went wrong.