-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from Isawan/prepare-for-announcement
Prepare for announcement
- Loading branch information
Showing
8 changed files
with
96 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# Summary | ||
|
||
- [Introduction](./introduction.md) | ||
- [External Caching](./external-caching.md) | ||
- [Reverse proxy](./reverse-proxy.md) | ||
- [Mirror refreshing](./mirror-refreshing.md) | ||
- [Private Registry Authentication](./private-registry-authentication.md) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# Reverse proxy | ||
|
||
The Terraform mirror [Provider Network Mirror Protocol](https://developer.hashicorp.com/terraform/internals/provider-network-mirror-protocol) requires that the API request be performed over encrypted HTTPS. | ||
Terrashine itself does not currently perform TLS termination, a reverse proxy must always be deployed to perform this function for a working setup. | ||
|
||
## External Caching | ||
|
||
Caching is optional however, terrashine sets `Cache-Control` headers where possible to allow caching by external reverse proxies. | ||
If caching is required, this should be achieved by configuring the reverse proxy to cache responses as appropriate. | ||
Cache headers are sometimes not set in cases where caching may incorrect behavior by the terraform client. | ||
For example: headers are not set in scenarios where caching could result in subsequent requests from the same client seeing inconsistent views of the available packages, resulting in an error when downloading packages. | ||
|
||
## Example NGINX configuration | ||
|
||
Here is an example NGINX configuration that provides TLS termination and caching enabled | ||
for a locally deployed terrashine instance. | ||
|
||
``` nginx | ||
user nginx; | ||
worker_processes auto; | ||
error_log /dev/stdout notice; | ||
pid /var/run/nginx.pid; | ||
events { | ||
worker_connections 1024; | ||
} | ||
http { | ||
default_type application/octet-stream; | ||
log_format main '$remote_addr - $remote_user [$time_local] "$request" ' | ||
'$status $body_bytes_sent "$http_referer" ' | ||
'"$http_user_agent" "$http_x_forwarded_for"'; | ||
access_log /dev/stdout main; | ||
sendfile on; | ||
keepalive_timeout 65; | ||
proxy_cache_path /tmp keys_zone=mycache:10m; | ||
server { | ||
listen 443 ssl; | ||
server_name localhost; | ||
proxy_cache mycache; | ||
ssl_certificate localhost.pem; | ||
ssl_certificate_key localhost.pem; | ||
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; | ||
ssl_ciphers HIGH:!aNULL:!MD5; | ||
location / { | ||
# terrashine | ||
proxy_pass http://localhost:9543; | ||
} | ||
} | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 22 additions & 1 deletion
23
resources/test/terraform/random-import-stack/.terraform.lock.hcl
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.