Skip to content

Commit

Permalink
fix: use legacy install for latest
Browse files Browse the repository at this point in the history
  • Loading branch information
seia-soto committed Sep 17, 2022
1 parent e560ff5 commit 5867ab1
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ jobs:
uses: actions/checkout@v2
- uses: actions/setup-node@v3
with:
node-version: 16
node-version: 12
- name: Setup QEMU
uses: docker/setup-qemu-action@v1
with:
Expand All @@ -88,7 +88,7 @@ jobs:
password: ${{secrets.GITHUB_TOKEN}}
- name: Build and push
run: |
bash ./build.sh "${{env.ARCH}}" "${{env.PACKAGE_NAME}}:latest" "${{needs.version.outputs.remote_tag}}" "false"
bash ./build.sh "${{env.ARCH}}" "${{env.PACKAGE_NAME}}:latest" "${{needs.version.outputs.remote_tag}}" "true"
- name: Conditional release
uses: actions/create-release@v1
env:
Expand Down
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,12 @@ cd outline-server-multiarch
Usage:
./build.sh $arch $tag $checkpoint
./build.sh $arch $tag $checkpoint $use_legacy_install
$arch {string} The arch to build, using docker platform style
$tag {string} The docker tag to use while building the image
$checkpoint {string} The git branch or tag to build, using `latest` will automatically use latest release tag
$checkpoint {string} The git branch or tag to checkout on Jigsaw-Code/Outline-Server
$use_legacy_install {boolean} Set as true to build recent versions of outline-server using Node.JS v16 (likely on master branch)
About:
Expand All @@ -65,10 +66,10 @@ About:
export SB_IMAGE="shadowbox-local"

PLATFORM="linux/amd64" # use one of linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6, or all
CHECKPOINT="latest" # or `master`
CHECKPOINT="latest" # use latest for latest tag or `master`

# build latest
bash ./build.sh "${PLATFORM}" "${SB_IMAGE}" "${CHECKPOINT}"
bash ./build.sh "${PLATFORM}" "${SB_IMAGE}" "${CHECKPOINT}" "true"

# run install script
curl -sL "https://raw.githubusercontent.com/Jigsaw-Code/outline-server/master/src/server_manager/install_scripts/install_server.sh" | sed '/local MACHINE_TYPE/,/fi/{d}' | bash
Expand Down
7 changes: 6 additions & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Usage:
$arch {string} The arch to build, using docker platform style
$tag {string} The docker tag to use while building the image
$checkpoint {string} The git branch or tag to checkout on Jigsaw-Code/Outline-Server
$use_legacy_install {boolean} Set as true to build recent versions of outline-server using Node.JS v16 since v1.10.0
$use_legacy_install {boolean} Set as true to build recent versions of outline-server using Node.JS v16 (likely on master branch)
About:
Expand Down Expand Up @@ -82,6 +82,11 @@ git clone "https://github.com/${REPO_BASE}.git" "${NS_BASE}"
# Go to repo and checkout to latest release
cd "${NS_BASE}"

# Use patch latest
if [[ "${CHECKPOINT}" == "latest" ]]; then
CHECKPOINT="$(git describe --tags --abbrev=0)"
fi

git checkout "${CHECKPOINT}"

# Multi arch build
Expand Down

0 comments on commit 5867ab1

Please sign in to comment.