diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7162a87..d8fabe3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -123,9 +123,28 @@ win32-installer: - master stage: installer tags: [ docker ] - image: electronuserland/builder:wine-mono + image: docker:stable + services: + - docker:stable-dind + variables: + DOCKER_DRIVER: overlay2 script: - - npm run-script build-win32 + - | + if ! docker info &>/dev/null; then + if [ -z "$DOCKER_HOST" -a "$KUBERNETES_PORT" ]; then + export DOCKER_HOST='tcp://localhost:2375' + fi + fi + - mkdir installer-builds + - chmod 777 installer-builds + - docker run + --env ELECTRON_CACHE="/root/.cache/electron" + --env ELECTRON_BUILDER_CACHE="/root/.cache/electron-builder" + -v ${PWD}:/project + -v ~/.cache/electron:/root/.cache/electron + -v ~/.cache/electron-builder:/root/.cache/electron-builder + electronuserland/builder:wine-mono /bin/bash -c "npm run-script build-win32" + - ls installer-builds/RyzenControllerInstaller.exe artifacts: paths: - installer-builds/ diff --git a/installers/windows/createinstaller.js b/installers/windows/createinstaller.js index 3a025c7..078ed1d 100644 --- a/installers/windows/createinstaller.js +++ b/installers/windows/createinstaller.js @@ -1,15 +1,24 @@ const createWindowsInstaller = require('electron-winstaller').createWindowsInstaller const path = require('path') +var keepAlive = false; + getInstallerConfig() .then(createWindowsInstaller) .catch((error) => { console.error(error.message || error) process.exit(1) }) +.then(function(){ + clearInterval(keepAlive); + console.log('Installer created.'); +}) function getInstallerConfig () { console.log('creating windows installer') + keepAlive = setInterval(function(){ + console.log(`I'm alive ...`); + }, 10000); const rootPath = path.join('./') return Promise.resolve({