Skip to content

Commit

Permalink
Move Artifact registry to other region.
Browse files Browse the repository at this point in the history
  • Loading branch information
ekharkunov committed Aug 12, 2024
1 parent eb8e565 commit 5ad117f
Show file tree
Hide file tree
Showing 21 changed files with 48 additions and 48 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/application-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
- "manifestmergetool-v[0-9]+.[0-9]+.[0-9]+"

env:
GOOGLE_ARTIFACT_REGISTRY: europe-north1-docker.pkg.dev
GOOGLE_ARTIFACT_REGISTRY: europe-west1-docker.pkg.dev
MAVEN_SERVICE_ACCOUNT: [email protected]

jobs:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docker-env-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ on:


env:
GOOGLE_ARTIFACT_REGISTRY: europe-north1-docker.pkg.dev
PUBLIC_REGISTRY: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry
PRIVATE_REGISTRY: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry
GOOGLE_ARTIFACT_REGISTRY: europe-west1-docker.pkg.dev
PUBLIC_REGISTRY: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry
PRIVATE_REGISTRY: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry
PRIVATE_PLATFORMS: "nssdk ps4 ps5"

jobs:
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ publishing {
repositories {
maven {
name "extenderRepo"
url "artifactregistry://europe-north1-maven.pkg.dev/extender-426409/extender-maven/"
url "artifactregistry://europe-west1-maven.pkg.dev/extender-426409/extender-maven/"
}
}
}
Expand Down
12 changes: 6 additions & 6 deletions server/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ Extender instance should run in preconfigured environment (where necessary SDKs,
```
3. Configure Docker to use Artifact registries
```sh
gcloud auth configure-docker europe-north1-docker.pkg.dev
gcloud auth configure-docker europe-west1-docker.pkg.dev
```
4. Check that everything set up correctly by pulling base image. Run
```sh
docker pull europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
docker pull europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
```

## How to build docker images locally
Expand All @@ -43,9 +43,9 @@ By default all built images tagged with `latest` version.
## How to add new Docker image with new environment
1. Place new Dockerfile in `server/docker` folder. Docker file should have name in format `Dockerfile.<platform>[.<version>]-env` (version can be optional if Dockerfile contains some common stuff for other images).
2. Depends on plaform choose right base image (for `FROM` instruction):
1. `europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env` for any **Android-based** images
2. `europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env` for any **Windows-based** images
3. `europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env` for the rest of cases
1. `europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env` for any **Android-based** images
2. `europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env` for any **Windows-based** images
3. `europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env` for the rest of cases
3. Set exact version of base image in `FROM` instruction.
4. Add appropriate command to `server/build-docker.sh` script.
5. Run `server/build-docker.sh` and check that everything is built correctly.
Expand Down Expand Up @@ -142,7 +142,7 @@ As an example show stepp on Android NDK25 Docker image.
```
or single docker build command
```sh
DM_PACKAGES_URL=<URL_TO_PACKAGES> docker buildx build --secret id=DM_PACKAGES_URL --platform linux/amd64 -t europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env:latest -f ./server/docker/Dockerfile.android-env ./server/docker
DM_PACKAGES_URL=<URL_TO_PACKAGES> docker buildx build --secret id=DM_PACKAGES_URL --platform linux/amd64 -t europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env:latest -f ./server/docker/Dockerfile.android-env ./server/docker
```
3. Create new git tag according to name convention:
`<platform>[.<sdk_version>]-<version>`
Expand Down
4 changes: 2 additions & 2 deletions server/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ set -e

SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

DOCKER_REGISTRY=europe-north1-docker.pkg.dev/extender-426409/extender-public-registry
DOCKER_PRIVATE_REGISTRY=europe-north1-docker.pkg.dev/extender-426409/extender-private-registry
DOCKER_REGISTRY=europe-west1-docker.pkg.dev/extender-426409/extender-public-registry
DOCKER_PRIVATE_REGISTRY=europe-west1-docker.pkg.dev/extender-426409/extender-private-registry

# base images
echo "Base image"
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.android-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

# Technically part of the Android build, but also required by the GradleService.java
# until it can be disabled (e.g. by looking for the existance of GRADLE_USER_HOME)
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.android.ndk25-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env:1.3.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-env:1.3.0

#
# Android SDK/NDK
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.base-env
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ RUN \


RUN \
export DOTNET_VERSION=$(dotnet --info | grep -A 1 'Host' | grep 'Version' | awk '{print $NF}') && \
export DOTNET_VERSION=$(${DOTNET_ROOT}/dotnet --info | grep -A 1 'Host' | grep 'Version' | awk '{print $NF}') && \
echo ${DOTNET_VERSION} > ${DOTNET_VERSION_FILE}

# Final cleanup
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.emsdk.2011-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

#
# EMSCRIPTEN
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.emsdk.3155-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

# Ubuntu still seem to use python3 3.8 as default version
RUN \
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.linux-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

RUN \
echo "LINUX TOOLS + COMPILER" && \
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.nssdk.1532-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

# Added in version 1.4.4
ENV NINTENDO_SDK_ROOT_15_3_2=${PLATFORMSDK_DIR}/nx-15.3.2
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.nssdk.1753-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

ENV NINTENDO_SDK_ROOT_17_5=${PLATFORMSDK_DIR}/nx-17.5.3
ENV SWITCH_SDK_17_FILENAME=nx64-sdk-17.5.3.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.ps4.10500-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

ENV PS4_SDK_10=${PLATFORMSDK_DIR}/ps4-sdk-10.500

Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.ps4.11000-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

ENV PS4_SDK_11_VERSION=11.000
ENV PS4_SDK_11=${PLATFORMSDK_DIR}/ps4-sdk-${PS4_SDK_11_VERSION}
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.ps5.8000-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

ENV PS5_SDK_8_VERSION=8.000
ENV PS5_SDK_8=${PLATFORMSDK_DIR}/ps5-sdk-${PS5_SDK_8_VERSION}
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.wine-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:1.2.0

# Installation notes: https://wiki.winehq.org/Ubuntu
# TODO: Backup the files as descibed here: https://wiki.winehq.org/Ubuntu
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.winsdk.2019-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env:1.2.0

ENV \
PLATFORMSDK_WIN32=$PLATFORMSDK_DIR/Win32 \
Expand Down
2 changes: 1 addition & 1 deletion server/docker/Dockerfile.winsdk.2022-env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env:1.2.0
FROM europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-wine-env:1.2.0

ENV PLATFORMSDK_WIN32=$PLATFORMSDK_DIR/Win32

Expand Down
2 changes: 1 addition & 1 deletion server/docker/common-services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- ./../app/:/app/:ro
- ./../manifestmergetool/app/manifestmergetool.jar:/etc/extender/apps/manifestmergetool.jar:ro
- ./../configs:/etc/defold/extender:ro
entrypoint: ["java","-Xmx4g","-XX:MaxDirectMemorySize=2g","-jar","/app/extender.jar"]
entrypoint: ["java","-Xdebug","-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005","-Xmx4g","-XX:MaxDirectMemorySize=2g","-jar","/app/extender.jar"]
environment:
- EXAMPLE_VAR=1
# - DM_DEBUG_COMMANDS=1
Expand Down
40 changes: 20 additions & 20 deletions server/docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: extender

services:
frontend-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
extends:
file: common-services.yml
service: common_builder
Expand All @@ -25,7 +25,7 @@ services:
aliases:
- frontend
linux-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-linux-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-linux-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -38,7 +38,7 @@ services:
aliases:
- linux
android_ndk25-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-ndk25-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-ndk25-env:latest
extends:
file: common-services.yml
service: common_builder
Expand All @@ -51,7 +51,7 @@ services:
aliases:
- android-ndk25
emscripten_2011-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-2011-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-2011-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -64,7 +64,7 @@ services:
aliases:
- emsdk-2011
emscripten_3155-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-3155-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-3155-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -77,7 +77,7 @@ services:
aliases:
- emsdk-3155
nssdk_1532-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry/extender-nssdk-1532-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry/extender-nssdk-1532-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -91,7 +91,7 @@ services:
aliases:
- nssdk-1532
nssdk_1753-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry/extender-nssdk-1753-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry/extender-nssdk-1753-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -105,7 +105,7 @@ services:
aliases:
- nssdk-1753
ps4_11000-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps4-11000-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps4-11000-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -119,7 +119,7 @@ services:
aliases:
- ps4-11000
ps4_10500-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps4-10500-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps4-10500-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -133,7 +133,7 @@ services:
aliases:
- ps4-10500
ps5_8000-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps5-8000-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-private-registry/extender-ps5-8000-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -147,7 +147,7 @@ services:
aliases:
- ps5-8000
win_2019-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2019-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2019-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -160,7 +160,7 @@ services:
aliases:
- winsdk-2019
win_2022-dev:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2022-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2022-env:latest
extends:
file: common-services.yml
service: remote_builder
Expand All @@ -175,7 +175,7 @@ services:

# services for integration testing
frontend-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
extends:
file: common-services.yml
service: test_builder
Expand All @@ -191,7 +191,7 @@ services:
aliases:
- frontend
linux-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-linux-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-linux-env:latest
extends:
file: common-services.yml
service: test_remote_builder
Expand All @@ -203,7 +203,7 @@ services:
aliases:
- linux
android_ndk25-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-ndk25-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-android-ndk25-env:latest
extends:
file: common-services.yml
service: test_builder
Expand All @@ -216,7 +216,7 @@ services:
aliases:
- android-ndk25
emscripten_2011-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-2011-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-2011-env:latest
extends:
file: common-services.yml
service: test_remote_builder
Expand All @@ -227,7 +227,7 @@ services:
aliases:
- emsdk-2011
emscripten_3155-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-3155-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-emsdk-3155-env:latest
extends:
file: common-services.yml
service: test_remote_builder
Expand All @@ -238,7 +238,7 @@ services:
aliases:
- emsdk-3155
win_2019-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2019-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2019-env:latest
extends:
file: common-services.yml
service: test_remote_builder
Expand All @@ -249,7 +249,7 @@ services:
aliases:
- winsdk-2019
win_2022-integration-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2022-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-winsdk-2022-env:latest
extends:
file: common-services.yml
service: test_remote_builder
Expand All @@ -262,7 +262,7 @@ services:

# linux service for auth testing
frontend-auth-test:
image: europe-north1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
image: europe-west1-docker.pkg.dev/extender-426409/extender-public-registry/extender-base-env:latest
extends:
file: common-services.yml
service: test_builder
Expand Down

0 comments on commit 5ad117f

Please sign in to comment.