-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/bacpop/beebop into bacpop-1…
…86-v9-db
- Loading branch information
Showing
17 changed files
with
139 additions
and
83 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 |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: build and push docker images | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- "*" | ||
env: | ||
BRANCH_NAME: ${{ github.head_ref || github.ref_name }} | ||
jobs: | ||
build-and-push: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Login to GHCR (GitHub Packages) | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Build Server image | ||
run: app/server/docker/build | ||
- name: Build Proxy image | ||
run: proxy/docker/build | ||
- name: Docker smoke test | ||
run: scripts/docker_smoke_test | ||
- name: Push Server image branch ${{ env.BRANCH_NAME }} | ||
run: app/server/docker/push | ||
- name: Push Proxy image branch ${{ env.BRANCH_NAME }} | ||
run: proxy/docker/push |
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
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 |
---|---|---|
@@ -1,25 +1,18 @@ | ||
#!/usr/bin/env bash | ||
set -e | ||
|
||
REGISTRY=ghcr.io | ||
PACKAGE_ROOT=$(realpath $HERE/..) | ||
PACKAGE_NAME=beebop-server | ||
PACKAGE_ORG=mrcide | ||
PACKAGE_ORG=bacpop | ||
|
||
# Buildkite doesn't check out a full history from the remote (just the | ||
# single commit) so you end up with a detached head and git rev-parse | ||
# doesn't work | ||
if [ "$BUILDKITE" = "true" ]; then | ||
GIT_SHA=${BUILDKITE_COMMIT:0:7} | ||
GIT_SHA=$(git -C "$PACKAGE_ROOT" rev-parse --short=7 HEAD) | ||
if [[ -v "BRANCH_NAME" ]]; then | ||
GIT_BRANCH=${BRANCH_NAME} | ||
else | ||
GIT_SHA=$(git -C "$PACKAGE_ROOT" rev-parse --short=7 HEAD) | ||
GIT_BRANCH=$(git symbolic-ref --short HEAD) | ||
fi | ||
|
||
if [ "$BUILDKITE" = "true" ]; then | ||
GIT_BRANCH=$BUILDKITE_BRANCH | ||
else | ||
GIT_BRANCH=$(git -C "$PACKAGE_ROOT" symbolic-ref --short HEAD) | ||
fi | ||
|
||
TAG_SHA="${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_SHA}" | ||
TAG_BRANCH="${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_BRANCH}" | ||
TAG_LATEST="${PACKAGE_ORG}/${PACKAGE_NAME}:latest" | ||
TAG_SHA="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_SHA}" | ||
TAG_BRANCH="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_BRANCH}" | ||
TAG_LATEST="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:latest" |
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 was deleted.
Oops, something went wrong.
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
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 |
---|---|---|
@@ -1,25 +1,19 @@ | ||
#!/usr/bin/env bash | ||
set -e | ||
|
||
REGISTRY=ghcr.io | ||
PACKAGE_ROOT=$(realpath $HERE/..) | ||
PACKAGE_NAME=beebop-proxy | ||
PACKAGE_ORG=mrcide | ||
PACKAGE_ORG=bacpop | ||
|
||
# Buildkite doesn't check out a full history from the remote (just the | ||
# single commit) so you end up with a detached head and git rev-parse | ||
# doesn't work | ||
if [ "$BUILDKITE" = "true" ]; then | ||
GIT_SHA=${BUILDKITE_COMMIT:0:7} | ||
GIT_SHA=$(git -C "$PACKAGE_ROOT" rev-parse --short=7 HEAD) | ||
if [[ -v "BRANCH_NAME" ]]; then | ||
GIT_BRANCH=${BRANCH_NAME} | ||
else | ||
GIT_SHA=$(git -C "$PACKAGE_ROOT" rev-parse --short=7 HEAD) | ||
GIT_BRANCH=$(git symbolic-ref --short HEAD) | ||
fi | ||
|
||
if [ "$BUILDKITE" = "true" ]; then | ||
GIT_BRANCH=$BUILDKITE_BRANCH | ||
else | ||
GIT_BRANCH=$(git -C "$PACKAGE_ROOT" symbolic-ref --short HEAD) | ||
fi | ||
|
||
TAG_SHA="${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_SHA}" | ||
TAG_BRANCH="${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_BRANCH}" | ||
TAG_LATEST="${PACKAGE_ORG}/${PACKAGE_NAME}:latest" | ||
TAG_SHA="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_SHA}" | ||
TAG_BRANCH="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:${GIT_BRANCH}" | ||
TAG_LATEST="${REGISTRY}/${PACKAGE_ORG}/${PACKAGE_NAME}:latest" |
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 |
---|---|---|
@@ -1,2 +1,9 @@ | ||
#!/usr/bin/env bash | ||
export API_BRANCH="bacpop-202-fallback-to-refs" | ||
export API_IMAGE="bacpop-205-fix-network-dev" | ||
|
||
NETWORK=beebop_nw | ||
VOLUME=beebop-storage | ||
NAME_REDIS=beebop-redis | ||
NAME_API=beebop-py-api | ||
NAME_WORKER=beebop-py-worker | ||
PORT=5000 |
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,17 @@ | ||
parse_mount_arg() { | ||
local mount="" | ||
|
||
while [ $# -gt 0 ]; do | ||
case "$1" in | ||
-mount) | ||
mount="$2" | ||
shift 2 | ||
;; | ||
*) | ||
shift | ||
;; | ||
esac | ||
done | ||
|
||
echo "$mount" | ||
} |
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