Skip to content

Commit

Permalink
feat: add a configuration option to open the endpoint /uuid to other …
Browse files Browse the repository at this point in the history
…… (backport #136) (#185)

This is an automatic backport of pull request #136 done by [Mergify](https://mergify.io).
Cherry-pick of 9d71702 has failed:
```
On branch mergify/bp/release_0.8/pr-136
Your branch is up to date with 'origin/release_0.8'.

You are currently cherry-picking commit 9d71702.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   config/nginx.conf

Unmerged paths:
  (use "git add/rm <file>..." as appropriate to mark resolution)
	deleted by us:   config/config.ini.custom

```


To fix up this pull request, you can check it out locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

---


<details>
<summary>Mergify commands and options</summary>

<br />

More conditions and actions can be found in the [documentation](https://docs.mergify.io/).

You can also trigger Mergify actions by commenting on this pull request:

- `@Mergifyio refresh` will re-evaluate the rules
- `@Mergifyio rebase` will rebase this PR on its base branch
- `@Mergifyio update` will merge the base branch into this PR
- `@Mergifyio backport <destination>` will backport this PR on `<destination>` branch

Additionally, on Mergify [dashboard](https://dashboard.mergify.io/) you can:

- look at your merge queues
- generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.io/
</details>
  • Loading branch information
mergify[bot] authored Jun 25, 2021
1 parent 8ae25b1 commit 1362f02
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions config/config.ini
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,13 @@ storage_min_delete_depth=0
# (see http://nginx.org/en/docs/http/ngx_http_autoindex_module.html)
storage_autoindex=1

# extra networks allowed on /uuid endpoint (in addition to 127.0.0.1/32)
# (coma separated list)
# ("null" => no extra uuid allowed)
# example :
# uuid_endpoint_extra_allows=5.6.0.0/16,1.2.3.4/32
uuid_endpoint_extra_allows=null


#######################
##### AUTORESTART #####
Expand Down
7 changes: 7 additions & 0 deletions config/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,13 @@ http {
# FIXME: rename this in __uuid
location = /uuid {
allow 127.0.0.1/32;
{% if MFBASE_NGINX_UUID_ENDPOINT_EXTRA_ALLOWS != "null" -%}
{% for ALLOW in MFBASE_NGINX_UUID_ENDPOINT_EXTRA_ALLOWS.split(',') %}
{%- if ALLOW != "" -%}
allow {{ALLOW}};
{% endif %}
{%- endfor -%}
{%- endif -%}
deny all;
echo "{{UUID}}";
access_log off;
Expand Down

0 comments on commit 1362f02

Please sign in to comment.