{system, pkgs}:

rec {
### Databases

  rooms = import ../pkgs/databases/rooms {
    inherit (pkgs) stdenv;
  };
  
  staff = import ../pkgs/databases/staff {
    inherit (pkgs) stdenv;
  };
  
  zipcodes = import ../pkgs/databases/zipcodes {
    inherit (pkgs) stdenv;
  };
  
### Web services + Clients

  GeolocationService = import ../pkgs/webservices/GeolocationService {
    inherit (pkgs) dotnetenv;
  };
  
  RoomService = import ../pkgs/webservices/RoomService {
    inherit (pkgs) dotnetenv;
  };
  
  StaffService = import ../pkgs/webservices/StaffService {
    inherit (pkgs) dotnetenv;
  };
  
  ZipcodeService = import ../pkgs/webservices/ZipcodeService {
    inherit (pkgs) dotnetenv;
  };
  
### Web applications

  StaffTracker = import ../pkgs/webapplications/StaffTracker {
    inherit (pkgs) dotnetenv;
  };
}

{system, pkgs}:

let
  callPackage = pkgs.lib.callPackageWith (pkgs // self);
  
  self = {
    ### Databases

    rooms = callPackage ../pkgs/databases/rooms { };
  
    staff = callPackage ../pkgs/databases/staff { };
  
    zipcodes = callPackage ../pkgs/databases/zipcodes { };
  
    ### Web services + Clients

    GeolocationService = callPackage ../pkgs/webservices/GeolocationService { };
  
    RoomService = callPackage ../pkgs/webservices/RoomService { };
  
    StaffService = callPackage ../pkgs/webservices/StaffService { };
  
    ZipcodeService = callPackage ../pkgs/webservices/ZipcodeService { };
  
    ### Web applications

    StaffTracker = callPackage ../pkgs/webapplications/StaffTracker { };
  };
in
self

Use callPackage for the top-level composition expression
Use callPackage for the top-level composition expression
