{"id":17465673,"url":"https://github.com/argonlaser/go-isdocker","last_synced_at":"2026-04-19T14:03:40.734Z","repository":{"id":57512513,"uuid":"85600472","full_name":"argonlaser/go-isdocker","owner":"argonlaser","description":"Check if process is running inside a docker","archived":false,"fork":false,"pushed_at":"2017-03-21T17:37:31.000Z","size":13,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-17T14:51:07.673Z","etag":null,"topics":["docker","docker-image","docker-machine","go"],"latest_commit_sha":null,"homepage":null,"language":"Go","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/argonlaser.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-03-20T16:31:21.000Z","updated_at":"2023-05-17T06:48:54.000Z","dependencies_parsed_at":"2022-09-26T17:51:41.283Z","dependency_job_id":null,"html_url":"https://github.com/argonlaser/go-isdocker","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/argonlaser/go-isdocker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/argonlaser%2Fgo-isdocker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/argonlaser%2Fgo-isdocker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/argonlaser%2Fgo-isdocker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/argonlaser%2Fgo-isdocker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/argonlaser","download_url":"https://codeload.github.com/argonlaser/go-isdocker/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/argonlaser%2Fgo-isdocker/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32009239,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"online","status_checked_at":"2026-04-19T02:00:07.110Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","docker-image","docker-machine","go"],"created_at":"2024-10-18T12:42:14.297Z","updated_at":"2026-04-19T14:03:40.714Z","avatar_url":"https://github.com/argonlaser.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GoDoc](https://godoc.org/github.com/argonlaser/go-isdocker?status.svg)](http://godoc.org/github.com/argonlaser/go-isdocker)\n[![Build Status](https://semaphoreci.com/api/v1/argonlaser/go-isdocker/branches/master/badge.svg)](https://semaphoreci.com/argonlaser/go-isdocker)\n[![Build Status](https://travis-ci.org/argonlaser/go-isdocker.svg?branch=master)](https://travis-ci.org/argonlaser/go-isdocker)\n# go-isdocker\n\n  Check if the process is running inside a docker.\n\n## Getting Started\n\nThis package checks for the presence of ```/.dockerenv``` file or searches for the presence of ```docker``` in the file ```/proc/self/cgroup``` \n\n```\nimport \"github.com/argonlaser/go-isdocker\"\n```\n\n## Documentation and APIs\nRefer godoc [go-isdocker](https://godoc.org/github.com/argonlaser/go-isdocker) for detailed APIs.\n\n### Usage\n\n```\nimport \"github.com/argonlaser/go-isdocker\"\n\nif isdocker.IsDocker() == true {\n  // this process is running on a docker\n\n} else {\n  // this process is running on a host machine\n\n}\n```\n\n## Running the tests\n\n```\n$ cd $HOME/go/src/github.com/argonlaser/go-isdocker\n$ go test\n```\n\n### Check coding style tests\n\n```\n$ cd $HOME/go/src/github.com/argonlaser/go-isdocker\n$ go fmt\n```\n\n## Bug reports\nPlease feel to raise an [issue](https://github.com/argonlaser/go-isdocker/issues) here. It means a lot to the project.\n\n\n## Contributing\n1. Fetch the Sources From GitHub\n\n```\n$ go get github.com/argonlaser/go-isdocker\n```\n\n2. Change to the ```go-isdocker``` source directory:\n\n```\n$ cd $GOPATH/src/github.com/argonlaser/go-isdocker\n```\n\n3. Create a new branch for your changes (the branch name is arbitrary):\n\n```\n$ git checkout -b mybranch\n```\n\n4. After making your changes, commit them to your new branch:\n \n```\n$ git commit -a -v\n```\n\n5. Fork this project in Github and add your fork as a new remote (the remote name, \"fork\" in this example, is arbitrary):\n\n```\n$ git remote add fork git://github.com/USERNAME/go-isdocker.git\n```\n\n6. Run codestyle checks and tests for ```go-isdocker``` with Your Changes. Add more tests if needed.\n\n```\n$ cd $HOME/go/src/github.com/argonlaser/go-isdocker\n$ go fmt\n$ go test\n```\n\n7. Push the changes to your new remote once all tests are passed.\n\n```\n$ git push --set-upstream fork mybranch\n```\n\n## Authors\n\n* Authored and maintained by **Venkata krishna** and the list of [contributors](https://github.com/argonlaser/go-isdocker/contributors).\n\n* Contact me via [Twitter](https://twitter.com/argon_laser)\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](https://github.com/argonlaser/go-isdocker/blob/master/LICENSE) file for details\n\n## Acknowledgments\n\n* [Hugo](https://github.com/spf13/hugo/blob/master/CONTRIBUTING.md )\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fargonlaser%2Fgo-isdocker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fargonlaser%2Fgo-isdocker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fargonlaser%2Fgo-isdocker/lists"}