diff --git a/.gitignore b/.gitignore index 610c0e3..7b04db6 100755 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +deployment.lua + # .gitignore: static posts/*.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..f9ebb40 --- /dev/null +++ b/README.md @@ -0,0 +1,5 @@ +# Pipeline process + +1. Push to the git bucket server +2. Open jenkins +3. Trigger pipeline build in the UI diff --git a/package.nix b/package.nix index e4e8b26..4bd3704 100644 --- a/package.nix +++ b/package.nix @@ -1,7 +1,9 @@ { lib, + pkgs, python3Packages, fetchgit, + fetchFromGitHub, nodejs_latest, nodePackages, chromium, @@ -9,27 +11,28 @@ makeWrapper, which, }: let - deployment_pipeline = python3Packages.buildPythonPackage { - pname = "deployment_pipeline"; - version = "0.1.0"; - pyproject = true; - src = fetchgit { - url = "ssh://git@git.jasonpoage.vpn:29418/jason/deployment_pipeline.git"; - rev = "main"; - hash = "sha256-2yapZOSOop/ng8MNjZcuJIr7Qu9rZfeHlH8h0ljN4aE="; - }; - # src = fetchFromGitHub { - # owner = "jpoage1"; - # repo = "deployment_pipeline"; - # rev = "main"; - # hash = "sha256-2yapZOSOop/ng8MNjZcuJIr7Qu9rZfeHlH8h0ljN4aE="; - # }; - nativeBuildInputs = with python3Packages; [ - setuptools - wheel - ]; - doCheck = false; + local_source = ../../deployment_pipeline; + vpn_source = builtins.fetchGit { + url = "ssh://git@git.jasonpoage.vpn:29418/jason/deployment_pipeline.git"; }; + github_source = fetchFromGitHub { + owner = "jpoage1"; + repo = "deployment_pipeline"; + rev = "main"; + hash = "sha256-2yapZOSOop/ng8MNjZcuJIr7Qu9rZfeHlH8h0ljN4aE="; + }; + # deployment_pipeline = python3Packages.buildPythonPackage { + # pname = "deployment_pipeline"; + # version = "0.1.0"; + # pyproject = true; + # src = vpn_source; + # nativeBuildInputs = with python3Packages; [ + # setuptools + # wheel + # ]; + # doCheck = false; + # }; + deployment_pipeline = pkgs.callPackage local_source {}; in python3Packages.buildPythonApplication { pname = "deployment_pipeline"; @@ -57,12 +60,12 @@ setuptools ]); - # Inject environment variables into the final binary - postFixup = '' - wrapProgram $out/bin/deployment_pipeline \ - --set PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true \ - --set PUPPETEER_EXECUTABLE_PATH ${chromium}/bin/chromium - ''; + # # Inject environment variables into the final binary + # postFixup = '' + # wrapProgram $out/bin/deployment_pipeline \ + # --set PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true \ + # --set PUPPETEER_EXECUTABLE_PATH ${chromium}/bin/chromium + # ''; meta = with lib; { description = "Deployment Pipeline with Node.js and Chromium integration"; diff --git a/shell.nix b/shell.nix index 2e75e9c..2430a4e 100644 --- a/shell.nix +++ b/shell.nix @@ -1,42 +1,9 @@ -# NodeJS PM2 # shell.nix {pkgs ? import {}}: let - # deployment_pipeline = python3Packages.buildPythonPackage { - # pname = "deployment_pipeline"; - # version = "0.1.0"; - # pyproject = true; - # src = fetchgit { - # url = "ssh://git@git.jasonpoage.vpn:29418/jason/pipeline_runner.git"; - # rev = "main"; - # hash = "sha256-2yapZOSOop/ng8MNjZcuJIr7Qu9rZfeHlH8h0ljN4aE="; - # }; - # # src = fetchFromGitHub { - # # owner = "jpoage1"; - # # repo = "deployment_pipeline"; - # # rev = "main"; - # # hash = "sha256-2yapZOSOop/ng8MNjZcuJIr7Qu9rZfeHlH8h0ljN4aE="; - # # }; - # nativeBuildInputs = with python3Packages; [ - # setuptools - # wheel - # ]; - # doCheck = false; - # }; deployment_pipeline = pkgs.callPackage ./package.nix {}; in pkgs.mkShell { inputsFrom = [deployment_pipeline]; - # packages = with pkgs; - # [ - # which - # nodejs_latest - # nodePackages.pnpm - # chromium - # # nodePackages.pm2mk - # imagemagick - # deployment_pipeline - # ] - # ++ (with python313Packages; [tomli lupa pip]); shellHook = '' export PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true export PUPPETEER_EXECUTABLE_PATH=${pkgs.chromium}/bin/chromium