Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • hive/common-ci-configuration
1 result
Show changes
Commits on Source (11)
......@@ -170,3 +170,5 @@ USER emscripten
WORKDIR /home/emscripten
ADD --chown=emscripten ./scripts/bash/npm-helpers /home/emscripten/scripts/
RUN /home/emscripten/scripts/npm_download_browser_extensions.sh /home/emscripten/preinstalled_browser_extensions
......@@ -83,7 +83,7 @@ target "tox-test-runner" {
target "emsdk" {
dockerfile = "Dockerfile.emscripten"
tags = generate-tags("emsdk", "${EMSCRIPTEN_VERSION}-2")
tags = generate-tags("emsdk", "${EMSCRIPTEN_VERSION}-3")
cache-from = generate-cache-from("emsdk", "${EMSCRIPTEN_VERSION}")
cache-to = generate-cache-to("emsdk", "${EMSCRIPTEN_VERSION}")
args = {
......
{
"name": "Hive NodeJS & Typescript",
"image": "registry.gitlab.syncad.com/hive/common-ci-configuration/emsdk:4.0.1-2@sha256:d0c5fbd811ef2447fdf411ee1e2a111c50ad0ec610cf3d6bf2d186530bc883ad",
"image": "registry.gitlab.syncad.com/hive/common-ci-configuration/emsdk:4.0.1-3@sha256:a2aef5aee0c4bcf1655cd9388d9d940ebfe588c66dae12d0abf5e21a6aff6f0d",
"containerUser": "emscripten",
//"runArgs": ["--network=host"],
"containerEnv": {
"DISPLAY": "host.docker.internal:0.0"
},
"portsAttributes": {
"8000-8080": {
"label": "Playwright test server, do not autoforward",
"onAutoForward": "ignore"
},
"30000-50000": {
"label": "Playwright test server, do not autoforward",
"onAutoForward": "ignore"
}
},
"mounts": [
{
"source": "/storage1/",
"target": "/storage1/",
"type": "bind"
},
{
"source": "${localEnv:HOME}/.gitconfig",
"target": "/home/emscripten/.gitconfig",
"type": "bind"
}
],
"customizations": {
"vscode": {
"extensions": []
"extensions": [
"ms-playwright.playwright",
"Vue.volar",
"GitHub.copilot",
"GitHub.copilot-chat"
]
}
}
}
\ No newline at end of file
......@@ -6,3 +6,6 @@ engine-strict=true
# Always install/remove dependencies from the pnpm workspace root
ignore-workspace-root-check=true
#When executing commands recursively in a workspace, execute them on the root workspace project as well
include-workspace-root=true
packages:
- ./* # maybe we can constrain it to some common subdirs
- './src/**/*'
- './packages/**/*'
- './wasm/**/*'
catalogs:
# Can be referenced through "catalog:rollup-toolset"
......
......@@ -10,6 +10,7 @@ EMSDK_VERSION=${1:-"4.0.1"}
export DOCKER_BUILDKIT=1
docker build --target=supplemented_emscripten_builder \
--progress=plain \
--build-arg "EMSCRIPTEN_VERSION=${EMSDK_VERSION}" \
--tag "${REGISTRY}emsdk:${EMSDK_VERSION}-2" \
--tag "${REGISTRY}emsdk:${EMSDK_VERSION}-3" \
--file "${SRCDIR}/Dockerfile.emscripten" "${SRCDIR}"
......@@ -15,7 +15,7 @@ pushd "${SOURCE_DIR}" # move to the project directory (where package.json file i
"${SCRIPTPATH}/npm_generate_version.sh" "${SOURCE_DIR}" "${REGISTRY_URL}" "${SCOPE}" "${PROJECT_NAME}" "${COMMIT_REF_PROTECTED}" "${COMMIT_TAG}"
npm run build
pnpm --recursive --workspace-concurrency=1 run build
"${SCRIPTPATH}/npm_pack_package.sh" "${SOURCE_DIR}" "${REGISTRY_URL}" "${SCOPE}" "${PROJECT_NAME}" "${OUTPUT_DIR}" "${COMMIT_REF_PROTECTED}" "${COMMIT_TAG}"
......
#!/bin/bash
set -xeuo pipefail
SCRIPTPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
TARGET_DIR=${1:?"Missing arg #1 to specify target directory to save downloaded files"}
abs_target_dir=`realpath -m --relative-base="$SCRIPTPATH" "$TARGET_DIR"`
TARGET_DIR="${abs_target_dir}"
mkdir -vp "${TARGET_DIR}"
pushd "${TARGET_DIR}"
declare -A EXTENSION_LIST=(
["Hive-Keychain"]="jcacnejopjdphbnjgfaaobbfafkihpep"
["Meta-mask"]="nkbihfbeogaeaoehlefnkodbefgpgknn"
)
for i in "${!EXTENSION_LIST[@]}"; do
# echo "Key: $i value: ${EXTlist[$i]}"
extensionName=$i
extensionID=${EXTENSION_LIST[$i]}
# we could try to use Chrome documented way to specify extensions to be automatically installed, but it is not honored in headless version of Chromium
# https://developer.chrome.com/docs/extensions/how-to/distribute/install-extensions#preference-linux
#echo '{"external_update_url": "https://clients2.google.com/service/update2/crx"}' > /opt/google/chrome/extensions/${extensionID}.json
DOWNLOAD_FILE_NAME="crx?response=redirect&os=win&arch=x86-64&os_arch=x86-64&nacl_arch=x86-64&prod=chromecrx&prodchannel=unknown&prodversion=9999.0.9999.0&acceptformat=crx2,crx3&x=id=${extensionID}&uc"
DOWNLOAD_URL="https://clients2.google.com/service/update2/crx?response=redirect&os=win&arch=x86-64&os_arch=x86-64&nacl_arch=x86-64&prod=chromecrx&prodchannel=unknown&prodversion=9999.0.9999.0&acceptformat=crx2,crx3&x=id%3D${extensionID}%26uc"
wget -nc "${DOWNLOAD_URL}"
UNZIP_DIR="${TARGET_DIR}/${extensionName}"
if [[ -d "${UNZIP_DIR}" ]];
then
echo "${extensionName} extension directory exists. Skipping..."
else
echo "Unpacking ${extensionName} into directory: ${UNZIP_DIR}"
mkdir -vp "${UNZIP_DIR}"
pushd "${UNZIP_DIR}"
# unzip often failed with random errors, so instead of regular cp, let's try to fix it immediately
zip -FFv "$TARGET_DIR/${DOWNLOAD_FILE_NAME}" --out "${extensionName}.zip"
#cp -n "$TARGET_DIR/${DOWNLOAD_FILE_NAME}" "${extensionName}.zip"
unzip "./${extensionName}.zip"
popd
fi
done
popd
......@@ -40,7 +40,7 @@ else
set -e
echo "Publishing ${NAME}@${VERSION} to tag ${PACKAGE_DIST_TAG}"
# We are going to repack the tarball as there are registry-dependent data in each job for package.json
pnpm publish --no-git-checks --access=public --tag "${PACKAGE_DIST_TAG}"
pnpm --recursive publish --no-git-checks --access=public --tag "${PACKAGE_DIST_TAG}"
fi
popd
......@@ -12,6 +12,8 @@ include:
variables:
DOCKER_DRIVER: overlay2
DOCKER_TLS_CERTDIR: "/certs"
FF_NETWORK_PER_BUILD: "true"
image: registry.gitlab.syncad.com/hive/common-ci-configuration/docker-builder:${DOCKER_BUILDER_TAG}
before_script:
- |
......
......@@ -2,8 +2,8 @@ include:
- local: templates/base.gitlab-ci.yml
variables:
# uses registry.gitlab.syncad.com/hive/common-ci-configuration/emsdk:4.0.1-2
EMSCRIPTEN_IMAGE_TAG: "4.0.1-2@sha256:a63a3ed761ce99ec858855bbdaf1cda03e383635dd7e88754010a746f7fd2cb3"
# uses registry.gitlab.syncad.com/hive/common-ci-configuration/emsdk:4.0.1-3
EMSCRIPTEN_IMAGE_TAG: "4.0.1-3@sha256:a2aef5aee0c4bcf1655cd9388d9d940ebfe588c66dae12d0abf5e21a6aff6f0d"
EMSCRIPTEN_IMAGE: "registry.gitlab.syncad.com/hive/common-ci-configuration/emsdk:$EMSCRIPTEN_IMAGE_TAG"
.node_based_job_base:
......@@ -28,7 +28,7 @@ variables:
before_script:
- !reference [.node_based_job_base, before_script]
- pnpm install --frozen-lockfile # install all required dependencies
- pnpm --recursive install --frozen-lockfile # install all required dependencies
.filter_out_swagger_json:
extends: .node_based_job_base
......