fix prod
Build & Deploy / Build & Push Docker Image (push) Successful in 2m51s
Test / Type Check (all packages) (push) Successful in 51s
Build & Deploy / Deploy to VPS (push) Successful in 4s
Test / API Unit Tests (push) Successful in 49s
Test / Homepage Unit Tests (push) Successful in 42s
Test / Storefront Unit Tests (push) Successful in 40s
Test / Admin Unit Tests (push) Successful in 41s
Test / Dashboard Unit Tests (push) Successful in 41s
Test / API Integration Tests (push) Successful in 59s
Build & Deploy / Build & Push Docker Image (push) Successful in 2m51s
Test / Type Check (all packages) (push) Successful in 51s
Build & Deploy / Deploy to VPS (push) Successful in 4s
Test / API Unit Tests (push) Successful in 49s
Test / Homepage Unit Tests (push) Successful in 42s
Test / Storefront Unit Tests (push) Successful in 40s
Test / Admin Unit Tests (push) Successful in 41s
Test / Dashboard Unit Tests (push) Successful in 41s
Test / API Integration Tests (push) Successful in 59s
This commit is contained in:
@@ -170,9 +170,13 @@ require_release_image() {
|
||||
}
|
||||
|
||||
login_registry_if_configured() {
|
||||
local archive_disabled="${IMAGE_ARCHIVE_DISABLED:-false}"
|
||||
|
||||
if [[ "${IMAGE_ARCHIVE_REQUIRED:-false}" == "true" || "${IMAGE_ARCHIVE_REQUIRED:-0}" == "1" ]]; then
|
||||
echo "IMAGE_ARCHIVE_REQUIRED is enabled; skipping docker login."
|
||||
return 0
|
||||
if [[ "${archive_disabled}" != "true" && "${archive_disabled}" != "1" ]]; then
|
||||
echo "IMAGE_ARCHIVE_REQUIRED is enabled; skipping docker login."
|
||||
return 0
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${IMAGE_ARCHIVE_DIR:-}" && -d "${IMAGE_ARCHIVE_DIR}" ]]; then
|
||||
@@ -215,8 +219,10 @@ pull_prod_release_images() {
|
||||
|
||||
if [[ "${IMAGE_ARCHIVE_REQUIRED:-false}" == "true" || "${IMAGE_ARCHIVE_REQUIRED:-0}" == "1" ]]; then
|
||||
echo "IMAGE_ARCHIVE_REQUIRED is enabled, but no archive for IMAGE_TAG=${IMAGE_TAG} was found in ${IMAGE_ARCHIVE_DIR:-<unset>}." >&2
|
||||
echo "The VPS cannot reach the VPN-only registry. Create a shared archive first, for example:" >&2
|
||||
echo " docker save ${APP_IMAGE:-rentaldrivego/carmanagement}:${IMAGE_TAG} -o ${IMAGE_ARCHIVE_DIR:-./image-archives}/carmanagement-${IMAGE_TAG}.tar" >&2
|
||||
echo "The VPS is configured for VPN/shared-folder image handoff. Create the archive first, for example:" >&2
|
||||
echo " VPN_CONTAINER=<vpn-container-id-or-name> ./fetch-image-through-vpn.sh ${IMAGE_TAG}" >&2
|
||||
echo "Or let deploy fetch it before starting services:" >&2
|
||||
echo " VPN_CONTAINER=<vpn-container-id-or-name> ./deploy-production.sh --fetch-through-vpn" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -248,6 +254,11 @@ load_release_image_archives() {
|
||||
local archive
|
||||
local loaded=0
|
||||
|
||||
if [[ "${IMAGE_ARCHIVE_DISABLED:-false}" == "true" || "${IMAGE_ARCHIVE_DISABLED:-0}" == "1" ]]; then
|
||||
echo "Image archive loading is disabled; pulling from registry."
|
||||
return 1
|
||||
fi
|
||||
|
||||
if [[ -z "${archive_dir}" ]]; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user