Skip to content

tgardiner/docker-nginx-ccrp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

docker-nginx-ccrp

About

Work around CORS issues by running an Nginx reverse proxy that will cache requests to the source API.

Requirements

  • Docker

Configuration

Check the serverblock inside default.conf. At a minimum you'll need to change the destination address.

The config has a 10s cache expiry and some options to hide certain headers from the response.

See the Nginx documentation here.

Build

docker build -t nginx-ccrp .

Run

docker run -dit --name nginx-ccrp -p 8080:80 nginx-ccrp

Test

Requests to http://localhost:8080/ should return your configured API.

About

Nginx cors caching reverse proxy

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published