diff options
author | vnugent <public@vaughnnugent.com> | 2024-03-28 16:57:57 -0400 |
---|---|---|
committer | vnugent <public@vaughnnugent.com> | 2024-03-28 16:57:57 -0400 |
commit | d8e1307252b176112040521f46951a02b5474c80 (patch) | |
tree | 416fe69db6b0294eac2b80a3b2241de744ea5810 /plugins | |
parent | b53fde4d0e9ed7d88e1ac322f455eefe0c9f0dfa (diff) |
ci(app): Switch to local build deps instead of downloading
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/ObjectCacheServer/server/container/Taskfile.yaml | 19 | ||||
-rw-r--r-- | plugins/ObjectCacheServer/server/install.taskfile.yaml | 20 | ||||
-rw-r--r-- | plugins/ObjectCacheServer/server/taskfile.yaml | 51 |
3 files changed, 23 insertions, 67 deletions
diff --git a/plugins/ObjectCacheServer/server/container/Taskfile.yaml b/plugins/ObjectCacheServer/server/container/Taskfile.yaml index 10ee86b..e02f1b3 100644 --- a/plugins/ObjectCacheServer/server/container/Taskfile.yaml +++ b/plugins/ObjectCacheServer/server/container/Taskfile.yaml @@ -8,11 +8,6 @@ version: "3" vars: INCLUDE_FILES: "Dockerfile, docker-compose.yaml" -includes: - install: - taskfile: ../install.taskfile.yaml - optional: true #not needed for inside container build - tasks: #called from inside the container to build native libraries build-libs: @@ -40,9 +35,6 @@ tasks: #remove the default config file as it's not needed in the container - powershell -Command "rm -Force -Recurse build/app/config/" - #install rpmalloc - - task: install-rpmalloc-lib - postbuild_success: cmds: #tar up the build directory and move it to the output bin directory @@ -55,17 +47,6 @@ tasks: cmds: - cmd: powershell -Command "rm -Recurse -Force ./build" - install-rpmalloc-lib: - internal: true - cmds: - #install compressor plugin - - task: install:install - vars: - PROJECT_NAME: 'vnlib_rpmalloc' - MODULE_NAME: "VNLib.Core" - FILE_NAME: "src.tgz" - DIR: './build/app/lib/vnlib_rpmalloc' - setup-container-image: internal: true cmds: diff --git a/plugins/ObjectCacheServer/server/install.taskfile.yaml b/plugins/ObjectCacheServer/server/install.taskfile.yaml deleted file mode 100644 index 37baf12..0000000 --- a/plugins/ObjectCacheServer/server/install.taskfile.yaml +++ /dev/null @@ -1,20 +0,0 @@ -# https://taskfile.dev - -#Called by the vnbuild system to produce builds for my website -#https://www.vaughnnugent.com/resources/software - -version: "3" - -tasks: - - install: - internal: true - cmds: - #make the plugin directory - - cmd: powershell -Command "mkdir {{.DIR}} -Force" - ignore_error: true - - cmd: powershell -Command "pwd" - - cd {{.DIR}} && powershell "{{.SCRIPT_DIR}}/install.ps1" -BaseUrl {{.BUILDS_URL}} -ModuleName {{.MODULE_NAME}} -ProjectName {{.PROJECT_NAME}} -FileName {{.FILE_NAME}} - - cd {{.DIR}} && tar -xzf {{.FILE_NAME}} - #remove the archive file - - cd {{.DIR}} && powershell -Command "rm {{.FILE_NAME}}"
\ No newline at end of file diff --git a/plugins/ObjectCacheServer/server/taskfile.yaml b/plugins/ObjectCacheServer/server/taskfile.yaml index 9455451..83b8e70 100644 --- a/plugins/ObjectCacheServer/server/taskfile.yaml +++ b/plugins/ObjectCacheServer/server/taskfile.yaml @@ -6,14 +6,10 @@ version: "3" vars: - BUILDS_URL: https://www.vaughnnugent.com/public/resources/software/builds SCRIPT_DIR: '{{.TASKFILE_DIR}}' BINARY_DIR: '{{.PROJECT_DIR}}/bin' #binary dir is not available for dotnet plugis includes: - install: - taskfile: install.taskfile.yaml - optional: true container: dir: container #always run from the container directory @@ -38,9 +34,8 @@ tasks: VNLIB_SHARED_HEAP_FILE_PATH: lib/libvn_rpmalloc cmds: - - cmd: dotnet webserver/VNLib.WebServer.dll --config config/config.json --input-off --inline-scheduler {{.CLI_ARGS}} - #setup sever environment - + - cmd: dotnet webserver/VNLib.WebServer.dll --config config/config.json --input-off {{.CLI_ARGS}} + #setup sever environment setup-apt: desc: "Performs initial setup on Debian/APT x64 based machines" @@ -105,6 +100,7 @@ tasks: install-webserver: internal: true cmds: + #create a server environment for each target os - for: [ win-x64, linux-x64, osx-x64, linux-arm64 ] task: create-env vars: @@ -112,20 +108,21 @@ tasks: install-plugins: internal: true + vars: + RPMALLOC_SRC: 'core/lib/Utils.Memory/vnlib_rpmalloc/bin/src.tgz' cmds: - cmd: powershell -Command "mkdir lib -Force" ignore_error: true #copy the object-cache plugin output to the local plugins directory - - cmd: powershell -Command "cp -Recurse -Force {{.PROJECT_DIR}}/bin/Release/net8.0/publish/ plugins/{{.PROJECT_NAME}}/" + - cmd: powershell -Command "cp -Recurse -Force {{.PROJECT_DIR}}/bin/Release/net8.0/publish/ plugins/{{.PROJECT_NAME}}" - #download rpmalloc - - task: install:install - vars: - PROJECT_NAME: 'vnlib_rpmalloc' - MODULE_NAME: "VNLib.Core" - FILE_NAME: "src.tgz" - DIR: './lib/vnlib_rpmalloc' + #copy local rpmalloc library to the local lib directory + - cmd: powershell mkdir lib/vnlib_rpmalloc -Force + - cmd: cd '{{.MODULE_DIR}}' && cd .. && powershell cp '{{.RPMALLOC_SRC}}' '{{.TASKFILE_DIR}}/lib/vnlib_rpmalloc/src.tgz' + - cmd: cd lib/vnlib_rpmalloc && tar -xzf src.tgz + - for: [ src.tgz, package.json ] + cmd: cd lib/vnlib_rpmalloc && powershell rm {{.ITEM}} postbuild_success: desc: "CI ONLY! DO NOT RUN" @@ -141,17 +138,12 @@ tasks: ignore_error: true - task: container:postbuild_success - - build-container: - internal: true - cmds: - - task: container:build #Creates a new webserver build environment for an operating system configuration create-env: - internal: true + #internal: true vars: - BUILD_DIR: './build/{{.TARGET_OS}}' + BUILD_DIR: 'build/{{.TARGET_OS}}' cmds: #create dir for env - cmd: powershell -Command "mkdir {{.BUILD_DIR}} -Force" @@ -169,13 +161,16 @@ tasks: #fetches a copy of (the desired os version) VNLib.WebServer project and installs it into the build directory get-webserver: internal: true + vars: + TARGET_DIR: '{{.TASKFILE_DIR}}/{{.BUILD_DIR}}/webserver/' + TARGET_FILENAME: '{{.TARGET_OS}}-release.tgz' + CI_WEBSERVER_DIR: 'VNLib.WebServer/src/bin' cmds: - - task: install:install - vars: - PROJECT_NAME: 'VNLib.Webserver' - MODULE_NAME: "VNLib.Webserver" - FILE_NAME: "{{.TARGET_OS}}-release.tgz" - DIR: '{{.BUILD_DIR}}/webserver' + #copy an existing webserver build to the build directory + - cmd: powershell -Command "mkdir {{.TARGET_DIR}} -Force" + - cmd: cd '{{.MODULE_DIR}}' && cd .. && powershell cp -Recurse -Force '{{.CI_WEBSERVER_DIR}}/{{.TARGET_FILENAME}}' '{{.TARGET_DIR}}{{.TARGET_FILENAME}}' + - cmd: cd '{{.TARGET_DIR}}' && tar -xzf {{.TARGET_FILENAME}} + - cmd: powershell rm '{{.TARGET_DIR}}/{{.TARGET_FILENAME}}' pack: internal: true |