github.com/netdata/go.d.plugin@v0.58.1/modules/dockerhub/integrations/docker_hub_repository.md (about) 1 <!--startmeta 2 custom_edit_url: "https://github.com/netdata/go.d.plugin/edit/master/modules/dockerhub/README.md" 3 meta_yaml: "https://github.com/netdata/go.d.plugin/edit/master/modules/dockerhub/metadata.yaml" 4 sidebar_label: "Docker Hub repository" 5 learn_status: "Published" 6 learn_rel_path: "Data Collection/Containers and VMs" 7 most_popular: False 8 message: "DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE" 9 endmeta--> 10 11 # Docker Hub repository 12 13 14 <img src="https://netdata.cloud/img/docker.svg" width="150"/> 15 16 17 Plugin: go.d.plugin 18 Module: dockerhub 19 20 <img src="https://img.shields.io/badge/maintained%20by-Netdata-%2300ab44" /> 21 22 ## Overview 23 24 This collector keeps track of DockerHub repositories statistics such as the number of stars, pulls, current status, and more. 25 26 27 28 29 This collector is supported on all platforms. 30 31 This collector supports collecting metrics from multiple instances of this integration, including remote instances. 32 33 34 ### Default Behavior 35 36 #### Auto-Detection 37 38 This integration doesn't support auto-detection. 39 40 #### Limits 41 42 The default configuration for this integration does not impose any limits on data collection. 43 44 #### Performance Impact 45 46 The default configuration for this integration is not expected to impose a significant performance impact on the system. 47 48 49 ## Metrics 50 51 Metrics grouped by *scope*. 52 53 The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels. 54 55 56 57 ### Per Docker Hub repository instance 58 59 These metrics refer to the entire monitored application. 60 61 This scope has no labels. 62 63 Metrics: 64 65 | Metric | Dimensions | Unit | 66 |:------|:----------|:----| 67 | dockerhub.pulls_sum | sum | pulls | 68 | dockerhub.pulls | a dimension per repository | pulls | 69 | dockerhub.pulls_rate | a dimension per repository | pulls/s | 70 | dockerhub.stars | a dimension per repository | stars | 71 | dockerhub.status | a dimension per repository | status | 72 | dockerhub.last_updated | a dimension per repository | seconds | 73 74 75 76 ## Alerts 77 78 There are no alerts configured by default for this integration. 79 80 81 ## Setup 82 83 ### Prerequisites 84 85 No action required. 86 87 ### Configuration 88 89 #### File 90 91 The configuration file name for this integration is `go.d/dockerhub.conf`. 92 93 94 You can edit the configuration file using the `edit-config` script from the 95 Netdata [config directory](https://github.com/netdata/netdata/blob/master/docs/configure/nodes.md#the-netdata-config-directory). 96 97 ```bash 98 cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata 99 sudo ./edit-config go.d/dockerhub.conf 100 ``` 101 #### Options 102 103 The following options can be defined globally: update_every, autodetection_retry. 104 105 106 <details><summary>Config options</summary> 107 108 | Name | Description | Default | Required | 109 |:----|:-----------|:-------|:--------:| 110 | update_every | Data collection frequency. | 1 | no | 111 | autodetection_retry | Recheck interval in seconds. Zero means no recheck will be scheduled. | 0 | no | 112 | url | DockerHub URL. | https://hub.docker.com/v2/repositories | yes | 113 | repositories | List of repositories to monitor. | | yes | 114 | timeout | HTTP request timeout. | 1 | no | 115 | username | Username for basic HTTP authentication. | | no | 116 | password | Password for basic HTTP authentication. | | no | 117 | proxy_url | Proxy URL. | | no | 118 | proxy_username | Username for proxy basic HTTP authentication. | | no | 119 | proxy_password | Password for proxy basic HTTP authentication. | | no | 120 | method | HTTP request method. | GET | no | 121 | body | HTTP request body. | | no | 122 | headers | HTTP request headers. | | no | 123 | not_follow_redirects | Redirect handling policy. Controls whether the client follows redirects. | no | no | 124 | tls_skip_verify | Server certificate chain and hostname validation policy. Controls whether the client performs this check. | no | no | 125 | tls_ca | Certification authority that the client uses when verifying the server's certificates. | | no | 126 | tls_cert | Client TLS certificate. | | no | 127 | tls_key | Client TLS key. | | no | 128 129 </details> 130 131 #### Examples 132 133 ##### Basic 134 135 A basic example configuration. 136 137 ```yaml 138 jobs: 139 - name: dockerhub 140 repositories: 141 - 'user1/name1' 142 - 'user2/name2' 143 - 'user3/name3' 144 145 ``` 146 147 148 ## Troubleshooting 149 150 ### Debug Mode 151 152 To troubleshoot issues with the `dockerhub` collector, run the `go.d.plugin` with the debug option enabled. The output 153 should give you clues as to why the collector isn't working. 154 155 - Navigate to the `plugins.d` directory, usually at `/usr/libexec/netdata/plugins.d/`. If that's not the case on 156 your system, open `netdata.conf` and look for the `plugins` setting under `[directories]`. 157 158 ```bash 159 cd /usr/libexec/netdata/plugins.d/ 160 ``` 161 162 - Switch to the `netdata` user. 163 164 ```bash 165 sudo -u netdata -s 166 ``` 167 168 - Run the `go.d.plugin` to debug the collector: 169 170 ```bash 171 ./go.d.plugin -d -m dockerhub 172 ``` 173 174