{"payload":{"feedbackUrl":"https://github.com/orgs/community/discussions/53140","repo":{"id":460182483,"defaultBranch":"main","name":"mango","ownerLogin":"tjhop","currentUserCanPush":false,"isFork":false,"isEmpty":false,"createdAt":"2022-02-16T21:23:50.000Z","ownerAvatar":"https://avatars.githubusercontent.com/u/33664289?v=4","public":true,"private":false,"isOrgOwned":false},"refInfo":{"name":"","listCacheKey":"v0:1716444098.0","currentOid":""},"activityList":{"items":[{"before":"965941802d8c9f58faf81564606eddd04639b24c","after":"dd62baa06e94e443b3e3b15174616319b71e0c88","ref":"refs/heads/main","pushedAt":"2024-05-23T06:01:38.000Z","pushType":"push","commitsCount":4,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"chore: `go get -u ./...`","shortMessageHtmlLink":"chore: go get -u ./..."}},{"before":"7f6a0ef2d37d63f62308130993b436bcf6747489","after":"965941802d8c9f58faf81564606eddd04639b24c","ref":"refs/heads/main","pushedAt":"2024-05-20T06:09:17.000Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"build: update packaged systemd service to set `--inventory.reload-interval 5m`","shortMessageHtmlLink":"build: update packaged systemd service to set `--inventory.reload-int…"}},{"before":"2220b5b235c2b1c394bdbfb4618d70c3b4be4013","after":"7f6a0ef2d37d63f62308130993b436bcf6747489","ref":"refs/heads/main","pushedAt":"2024-05-18T04:45:16.000Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ci: lots of updates/upgrades for release action","shortMessageHtmlLink":"ci: lots of updates/upgrades for release action"}},{"before":"b7e89d24a4f37f9900f4e102369ad29c2f3fd5d9","after":"2220b5b235c2b1c394bdbfb4618d70c3b4be4013","ref":"refs/heads/main","pushedAt":"2024-05-18T03:30:16.000Z","pushType":"push","commitsCount":6,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ci: add systemd service file to archive (tarball) in releases","shortMessageHtmlLink":"ci: add systemd service file to archive (tarball) in releases"}},{"before":"f8e2272f2089abdc006c1b3b64796c090c8425a5","after":"b7e89d24a4f37f9900f4e102369ad29c2f3fd5d9","ref":"refs/heads/main","pushedAt":"2024-05-17T05:14:09.000Z","pushType":"push","commitsCount":16,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix(template): block device queue stats path update + error checking\n\nThe function will prepend the `/sys/block/` path in for us, so we don't\nneed to use the joined path here, just the regular device name returned\nfrom the list function.\n\nAlso, somehow, I wrote this so that the error log would always log,\nregardless of whether or not there was an error. It actually checks if\nthe function errored now. :facepalm:","shortMessageHtmlLink":"fix(template): block device queue stats path update + error checking"}},{"before":"81d916679579951135e03b9fad89aee865bd035e","after":"f8e2272f2089abdc006c1b3b64796c090c8425a5","ref":"refs/heads/main","pushedAt":"2024-05-09T04:06:41.000Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"docs: add table explaining inventory components and various files","shortMessageHtmlLink":"docs: add table explaining inventory components and various files"}},{"before":"4f7da75b185d6fe6c74c7a1326245a0fd104fedd","after":"81d916679579951135e03b9fad89aee865bd035e","ref":"refs/heads/main","pushedAt":"2024-05-08T06:03:30.000Z","pushType":"push","commitsCount":4,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix!: manager track prev executed directives, prevent duplicate runs\n\n`directives` are supposed to only be executed _once_ IFF the file has\nbeen executed within the last 24h. The existing code would, during the\ncourse of the normal scheduled runs, attempt to reload and run all valid\ndirectives found in the inventory. Because we are not tracking\ndirectives that have already been executed, this means that if a\ndirective is added to an inventory, then during the course of it's\nnormal scheduled runs, _each run_ of the reload-and-run-all code would\nattempt to execute the directive during that 24h validity period. This\nmeans that a directive would not be executed once as intended, but\nrather would be executed `24h / $inventory.reload_interval` number of\ntimes.\n\nThis adds a cache map to the manager to keep track of which directives\nhave already been executed.\n\nNOTE: the cache is not persistent beyond the lifetime of the process in\nwhich mango is running. This means that if a new directive is added and\nexecuted by mango, and then mango itself subsequently gets restarted\nduring the 24h validity period of that directive, the cache will be\nreset and mango will re-execute the directive. Given that mango is\nintended to be run as a long lived daemon, I find this reasonable.","shortMessageHtmlLink":"fix!: manager track prev executed directives, prevent duplicate runs"}},{"before":"8acbab98907d224850efcfe1d8d170c0ef5c78c7","after":"4f7da75b185d6fe6c74c7a1326245a0fd104fedd","ref":"refs/heads/main","pushedAt":"2024-04-18T03:08:42.000Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"build: update deps","shortMessageHtmlLink":"build: update deps"}},{"before":"e1251332d9a6ffc64729e055bbe5d52b1debed12","after":"8acbab98907d224850efcfe1d8d170c0ef5c78c7","ref":"refs/heads/main","pushedAt":"2024-04-17T17:13:35.000Z","pushType":"push","commitsCount":7,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"chore: update gitignore, ignore mango binary and golangci-lint cache\n\n- when running the local build using goreleaser, it copies the binary\n out of `dist/` into the working directory, so we should exclude that\ncopy of the binary as well.\n- excludes local golangci lint cache directory","shortMessageHtmlLink":"chore: update gitignore, ignore mango binary and golangci-lint cache"}},{"before":"800d473a4f3e45e0b4bb03d509f8a3c99c98990d","after":"e1251332d9a6ffc64729e055bbe5d52b1debed12","ref":"refs/heads/main","pushedAt":"2024-04-16T23:51:44.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix: better handle failures when parsing group glob/regex patterns\n\nThe `Must` methods panic on failure -- this switches to using the normal\nfunctions and logging any returned errors so we can skip broken patterns\nand continue on","shortMessageHtmlLink":"fix: better handle failures when parsing group glob/regex patterns"}},{"before":"ad2178b289079b9e8860de5a054e6c1e155f7db2","after":"800d473a4f3e45e0b4bb03d509f8a3c99c98990d","ref":"refs/heads/main","pushedAt":"2024-04-09T18:03:26.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat: add `--version` flag","shortMessageHtmlLink":"feat: add --version flag"}},{"before":"9f6b530fe6677f96a89813e0eb54032661b5ae77","after":"ad2178b289079b9e8860de5a054e6c1e155f7db2","ref":"refs/heads/main","pushedAt":"2024-04-09T16:34:22.000Z","pushType":"push","commitsCount":4,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ref: rename `config` pkg to `version`\n\nIt only houses version info anyway.","shortMessageHtmlLink":"ref: rename config pkg to version"}},{"before":"a8a65a1fb2115f088d0d6ea06463ce312a2b446f","after":"9f6b530fe6677f96a89813e0eb54032661b5ae77","ref":"refs/heads/main","pushedAt":"2024-03-14T02:54:26.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ci: add `ci` and `test` commit prefixes to changelogs","shortMessageHtmlLink":"ci: add ci and test commit prefixes to changelogs"}},{"before":"a8a65a1fb2115f088d0d6ea06463ce312a2b446f","after":null,"ref":"refs/tags/v0.9.0","pushedAt":"2024-03-09T19:40:02.000Z","pushType":"branch_deletion","commitsCount":0,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"}},{"before":"04edbe91fec0b624970fdc4a08c64a1f1121d622","after":"a8a65a1fb2115f088d0d6ea06463ce312a2b446f","ref":"refs/heads/main","pushedAt":"2024-03-09T19:37:10.000Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"chore: make linter happy","shortMessageHtmlLink":"chore: make linter happy"}},{"before":"d2ea7366df2d6964b9d87b15b78b4bb4c9b1e57d","after":"04edbe91fec0b624970fdc4a08c64a1f1121d622","ref":"refs/heads/main","pushedAt":"2024-03-09T19:32:28.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix: allow unset log level flag, default to info if unset\n\nWhen the flag was unset, the previous switch case was failing to parse\nand handle that case. This adds handling to default log level to `info`\nif the flag is unset (as well as log a warning). Fixes:\n\n```\n~/go/src/github.com/tjhop/mango (main [ U ]) -> ./dist/mango_linux_amd64_v1/mango --inventory.path /dev/null\ntime=2024-03-09T14:24:52.649-05:00 level=ERROR msg=\"Failed to parse log level from flag\" err=\"Unsupported log level\" log_level=\"\"\n```\n\nThe default level is info so setting it explicitly is for the humans\nreading this chunk of logic.","shortMessageHtmlLink":"fix: allow unset log level flag, default to info if unset"}},{"before":"03a035ac7317d76b04537dc56de50fe2fbdeb003","after":"d2ea7366df2d6964b9d87b15b78b4bb4c9b1e57d","ref":"refs/heads/main","pushedAt":"2023-11-10T05:55:04.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat: add proper help flag, make mango charityware <3\n\nRIP Bram.","shortMessageHtmlLink":"feat: add proper help flag, make mango charityware <3"}},{"before":"45ab7f289bdecb8275e259bd2cc05de4cba0683d","after":"03a035ac7317d76b04537dc56de50fe2fbdeb003","ref":"refs/heads/main","pushedAt":"2023-11-01T01:35:03.000Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ref!: refactor out info metrics into main/mango, inventory, etc","shortMessageHtmlLink":"ref!: refactor out info metrics into main/mango, inventory, etc"}},{"before":"3a9934b7f4b3f7b5505eb76743a2e740db5d7ba1","after":"45ab7f289bdecb8275e259bd2cc05de4cba0683d","ref":"refs/heads/main","pushedAt":"2023-10-14T04:17:24.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ref: metrics HTTP server now setup from main, remove deprecated stuff","shortMessageHtmlLink":"ref: metrics HTTP server now setup from main, remove deprecated stuff"}},{"before":"9acff3aaaa6e74a844b4972df9b5d05464d8751e","after":"3a9934b7f4b3f7b5505eb76743a2e740db5d7ba1","ref":"refs/heads/main","pushedAt":"2023-10-13T05:26:56.000Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix: more consistently check for hidden files in inventory","shortMessageHtmlLink":"fix: more consistently check for hidden files in inventory"}},{"before":"6c73e79aae1e4508f9063f85ed87834044b78ea6","after":"9acff3aaaa6e74a844b4972df9b5d05464d8751e","ref":"refs/heads/main","pushedAt":"2023-10-13T05:15:37.000Z","pushType":"push","commitsCount":7,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat: add `IsHidden` func to util pkg","shortMessageHtmlLink":"feat: add IsHidden func to util pkg"}},{"before":"c620c413a8d27bf6efb78206a9f0f8606450bfd9","after":"6c73e79aae1e4508f9063f85ed87834044b78ea6","ref":"refs/heads/main","pushedAt":"2023-09-14T03:25:31.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"chore(deps): deprecate internal `self` pkg, clean dead code","shortMessageHtmlLink":"chore(deps): deprecate internal self pkg, clean dead code"}},{"before":"68a99c109003d81a20fa7b66c69e3f635dcd428b","after":"c620c413a8d27bf6efb78206a9f0f8606450bfd9","ref":"refs/heads/main","pushedAt":"2023-09-12T02:46:35.000Z","pushType":"push","commitsCount":25,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix(template): storage metadata block device queue stats path","shortMessageHtmlLink":"fix(template): storage metadata block device queue stats path"}},{"before":"46c8d5cd3e75991918691b10f7d9889a834c0077","after":"68a99c109003d81a20fa7b66c69e3f635dcd428b","ref":"refs/heads/main","pushedAt":"2023-07-21T04:47:47.000Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat!: add host `group` concept to inventory, support globs + regex\n\nLots of changes:\n\n- new `Group` type for new inventory component\n- new prometheus metrics with the component\n- `Store` interface functions that deal with enrollment have been\n updated to account for groups, as well\n- Manager has been updated to support keeping a list of group(s)/host\n variable file paths to source on reload, to allow for sourcing\nvariables from `variables` files in any/all groups and/or from explicit\nhost configs\n- `inventory.GetVariablesForSelf()` has been updated to return a slice\n of strings containing the paths to `variables` files relevant to the\ncurrent host\n- add new func `filterDuplicateRoles()` to remove duplicate roles that\n could be assigned across multiple groups a host may be a member to\n- various test inventory updates to better utilize `group` configs","shortMessageHtmlLink":"feat!: add host group concept to inventory, support globs + regex"}},{"before":"8199712e6c23b41570760f648ba0a1debb35465a","after":"46c8d5cd3e75991918691b10f7d9889a834c0077","ref":"refs/heads/main","pushedAt":"2023-07-01T18:38:03.000Z","pushType":"push","commitsCount":3,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"fix: only allow setting custom hostname if running as root\n\nThis is match access level to `/etc/hostname` of `0644`. If only root\ncan change system hostname, then only root should be able to change the\nhostname of the inventory that is used to enroll in the configuration\nmanagement system.","shortMessageHtmlLink":"fix: only allow setting custom hostname if running as root"}},{"before":"e7ee2fddf99b2faa87b310a7b98eca76055d6b89","after":"8199712e6c23b41570760f648ba0a1debb35465a","ref":"refs/heads/main","pushedAt":"2023-06-23T21:09:59.689Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat!: `requires` file on modules in inventory for explicit ordering\n\nThis commit adds the ability to create a file called `requires` within a\nmodule, that contains a new-line separated list of other modules that\nmust be run before this module.\n\nBehind the scenes, this adds an edge to the DAG of modules that are\nmanaged by the manager routine. When running all modules, the\ntopological sort ensures that there is a consistent ordering.\n\nExample output from test inventory:\n```\n[root@testbox-arch /]# cat /tmp/mango-dependency-testing\n/opt/mango/inventory/modules/test-reload\n/opt/mango/inventory/modules/test-env-vars\n/opt/mango/inventory/modules/test-requires-1\n/opt/mango/inventory/modules/test-template\n/opt/mango/inventory/modules/test-requires-2\n/opt/mango/inventory/modules/test-requires-3\n/opt/mango/inventory/modules/test-requires-4\n/opt/mango/inventory/modules/test-requires-5\n[root@testbox-arch /]#\n```","shortMessageHtmlLink":"feat!: requires file on modules in inventory for explicit ordering"}},{"before":"b40bf5b5299a208cb956ccf5a5748bac391d54aa","after":"e7ee2fddf99b2faa87b310a7b98eca76055d6b89","ref":"refs/heads/main","pushedAt":"2023-06-16T12:34:38.797Z","pushType":"push","commitsCount":1,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat(manager): manage modules as DAG\n\nEach module is represented as a vertex in the DAG. Ordering/dependency\nmanagement should be able to be implemented by adding edges between the\nvarious modules and relying on a topological sort.","shortMessageHtmlLink":"feat(manager): manage modules as DAG"}},{"before":"a99c20425ae5c2f8e5b546dcff57c929d1e2666e","after":"b40bf5b5299a208cb956ccf5a5748bac391d54aa","ref":"refs/heads/main","pushedAt":"2023-06-16T01:07:01.514Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"docs: updated flags output in README\n\nFlags were updated when the auto reload flag was added, so docs need\nupdating.","shortMessageHtmlLink":"docs: updated flags output in README"}},{"before":"a478c0fc8951dc836bdbd0ebf12a2d65e6427412","after":"a99c20425ae5c2f8e5b546dcff57c929d1e2666e","ref":"refs/heads/main","pushedAt":"2023-06-14T04:10:31.792Z","pushType":"push","commitsCount":10,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"ci: duplicate testbox host in inv for new arch test container\n\nNeeding to literally duplicate/copy over an existing host to duplicate\nit is frustrating.\n\nI think I'm going to add a new `groups` folder into the inventory to\nallow for defining a glob/regexp for matching hostnames against the\ninventory. That way, you could have a single inventory definition for eg\n`testbox-*` or similar.","shortMessageHtmlLink":"ci: duplicate testbox host in inv for new arch test container"}},{"before":"98521fe1963bda94d1c88a88df9781e5e2b4200c","after":"a478c0fc8951dc836bdbd0ebf12a2d65e6427412","ref":"refs/heads/main","pushedAt":"2023-06-02T03:23:59.550Z","pushType":"push","commitsCount":2,"pusher":{"login":"tjhop","name":"TJ Hoplock","path":"/tjhop","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/33664289?s=80&v=4"},"commit":{"message":"feat: add `--inventory.reload-interval`/timer support for auto reloads","shortMessageHtmlLink":"feat: add --inventory.reload-interval/timer support for auto reloads"}}],"hasNextPage":true,"hasPreviousPage":false,"activityType":"all","actor":null,"timePeriod":"all","sort":"DESC","perPage":30,"cursor":"djE6ks8AAAAEUaSxRQA","startCursor":null,"endCursor":null}},"title":"Activity · tjhop/mango"}