nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
fork

Configure Feed

Select the types of activity you want to include in your feed.

at gcc-offload 46 lines 1.2 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 postgresql, 6 unstableGitUpdater, 7 nixosTests, 8 postgresqlTestExtension, 9 buildPostgresqlExtension, 10}: 11 12buildPostgresqlExtension (finalAttrs: { 13 pname = "pgjwt"; 14 version = "0-unstable-2023-03-02"; 15 16 src = fetchFromGitHub { 17 owner = "michelp"; 18 repo = "pgjwt"; 19 rev = "f3d82fd30151e754e19ce5d6a06c71c20689ce3d"; 20 sha256 = "sha256-nDZEDf5+sFc1HDcG2eBNQj+kGcdAYRXJseKi9oww+JU="; 21 }; 22 23 passthru.updateScript = unstableGitUpdater { }; 24 25 passthru.tests = lib.recurseIntoAttrs { 26 pgjwt = nixosTests.postgresql.pgjwt.passthru.override postgresql; 27 28 extension = postgresqlTestExtension { 29 inherit (finalAttrs) finalPackage; 30 sql = '' 31 CREATE EXTENSION pgjwt CASCADE; 32 SELECT sign('{"sub":"1234567890","name":"John Doe","admin":true}', 'secret'); 33 ''; 34 }; 35 }; 36 37 meta = with lib; { 38 description = "PostgreSQL implementation of JSON Web Tokens"; 39 longDescription = '' 40 sign() and verify() functions to create and verify JSON Web Tokens. 41 ''; 42 license = licenses.mit; 43 platforms = postgresql.meta.platforms; 44 maintainers = with maintainers; [ spinus ]; 45 }; 46})