{"id":16345272,"url":"https://github.com/mirkolenz/flocken","last_synced_at":"2025-12-28T17:53:09.257Z","repository":{"id":176289448,"uuid":"652983287","full_name":"mirkolenz/flocken","owner":"mirkolenz","description":"Flocken (German for \"flakes\") is a collection of utilities for nix flakes.","archived":false,"fork":false,"pushed_at":"2025-02-03T04:26:55.000Z","size":170,"stargazers_count":17,"open_issues_count":1,"forks_count":3,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-20T19:00:05.631Z","etag":null,"topics":["docker","flakes","nix","nixos","podman","utilities"],"latest_commit_sha":null,"homepage":"https://mirkolenz.github.io/flocken/","language":"Nix","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mirkolenz.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-06-13T07:23:00.000Z","updated_at":"2025-02-20T18:21:10.000Z","dependencies_parsed_at":"2023-10-03T00:07:40.182Z","dependency_job_id":"b7dabe47-ab72-4195-b119-d50f4f521bb6","html_url":"https://github.com/mirkolenz/flocken","commit_stats":null,"previous_names":["mirkolenz/flocken"],"tags_count":35,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mirkolenz%2Fflocken","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mirkolenz%2Fflocken/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mirkolenz%2Fflocken/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mirkolenz%2Fflocken/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mirkolenz","download_url":"https://codeload.github.com/mirkolenz/flocken/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245040235,"owners_count":20551297,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","flakes","nix","nixos","podman","utilities"],"created_at":"2024-10-11T00:30:32.925Z","updated_at":"2025-12-28T17:53:09.183Z","avatar_url":"https://github.com/mirkolenz.png","language":"Nix","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Flocken\n\nFlocken (German for \"flakes\") is a collection of utilities for nix flakes.\n\n## Usage\n\nThe project supports semantic versioning, so we advise to pin the major version (e.g., `v2`) to avoid breaking changes.\n\n```nix\n{\n  inputs = {\n    nixpkgs.url = \"github:nixos/nixpkgs/nixpkgs-unstable\";\n    flocken = {\n      url = \"github:mirkolenz/flocken/v2\";\n      inputs.nixpkgs.follows = \"nixpkgs\";\n    };\n  };\n  outputs = {nixpkgs, flocken, ...}:  {};\n}\n```\n\n## [`flocken.lib`](https://mirkolenz.github.io/flocken/lib.html)\n\nA collection of utility functions for nix flakes.\nSee the documentation for more details.\n\n## [`flocken.legacyPackages.${system}.mkDockerManifest`](https://mirkolenz.github.io/flocken/docker-manifest.html)\n\nCreate and push a Docker manifest to a registry.\nThis is particularly useful for multi-arch images.\nSome arguments (e.g., `version`) differ between invocations and thus need to be provided in a dynamic fashion.\nWe recommend to use environment variables for this purpose.\nFor instance, when running in a GitHub action, you only have to provide a value for `VERSION` and `GITHUB_TOKEN` and then can use the following snippet:\n\n```nix\ndocker-manifest = mkDockerManifest {\n  github = {\n    enable = true;\n    token = \"$GITHUB_TOKEN\";\n  };\n  version = builtins.getEnv \"VERSION\";\n  imageStreams = with self.packages; [x86_64-linux.docker aarch64-linux.docker];\n}\n```\n\n\u003e [!warning]\n\u003e Reading environment variables requires the `--impure` flag (e.g., `nix run --impure .#docker-manifest`).\n\u003e Do not use `builtins.getEnv` to read secrets, as this would expose them in the Nix store and could lead to uploading them to binary caches.\n\u003e For tokens/password, pass the name of the environment variable instead.\n\nHere is a complete example for a GitHub action that is able to build an image for multiple architectures:\n\n```yaml\non:\n  push:\n    branches: [main]\njobs:\n  release:\n    runs-on: ubuntu-latest\n    permissions:\n      contents: write\n      packages: write\n    steps:\n      - uses: actions/checkout@v4\n      - uses: docker/setup-qemu-action@v3\n        with:\n          platforms: arm64\n      - uses: DeterminateSystems/nix-installer-action@v6\n        with:\n          extra-conf: |\n            extra-platforms = aarch64-linux\n      - uses: DeterminateSystems/magic-nix-cache-action@v2\n      - run: nix run --impure .#docker-manifest\n        env:\n          VERSION: \"1.0.0\"\n          GITHUB_TOKEN: ${{ github.token }}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmirkolenz%2Fflocken","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmirkolenz%2Fflocken","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmirkolenz%2Fflocken/lists"}