Add local environment that uses alpha configuration
This commit is contained in:
		
							parent
							
								
									f36dfbb494
								
							
						
					
					
						commit
						5b683a7631
					
				|  | @ -6,6 +6,14 @@ up: | |||
| %: | ||||
| 	docker-compose $* | ||||
| 
 | ||||
| .PHONY: alpha-config-up | ||||
| alpha-config-up: | ||||
| 	docker-compose -f docker-compose.yaml -f docker-compose-alpha-config.yaml up -d | ||||
| 
 | ||||
| .PHONY: alpha-config-% | ||||
| alpha-config-%: | ||||
| 	docker-compose -f docker-compose.yaml -f docker-compose-nginx.yaml $* | ||||
| 
 | ||||
| .PHONY: nginx-up | ||||
| nginx-up: | ||||
| 	docker-compose -f docker-compose.yaml -f docker-compose-nginx.yaml up -d | ||||
|  |  | |||
|  | @ -0,0 +1,19 @@ | |||
| # This docker-compose file can be used to bring up an example instance of oauth2-proxy | ||||
| # for manual testing and exploration of features. | ||||
| # Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider, | ||||
| # etcd for storage for Dex  and HTTPBin as an example upstream. | ||||
| # This file also uses alpha configuration when configuring OAuth2 Proxy. | ||||
| # | ||||
| # This file is an extension of the main compose file and must be used with it | ||||
| #    docker-compose -f docker-compose.yaml -f docker-compose-alpha-config.yaml <command> | ||||
| # Alternatively: | ||||
| #    make alpha-config-<command> (eg make nginx-up, make nginx-down) | ||||
| # | ||||
| # Access http://localhost:4180 to initiate a login cycle | ||||
| version: '3.0' | ||||
| services: | ||||
|   oauth2-proxy: | ||||
|     command: --config /oauth2-proxy.cfg --alpha-config /oauth2-proxy-alpha-config.yaml | ||||
|     volumes: | ||||
|       - "./oauth2-proxy-alpha-config.cfg:/oauth2-proxy.cfg" | ||||
|       - "./oauth2-proxy-alpha-config.yaml:/oauth2-proxy-alpha-config.yaml" | ||||
|  | @ -0,0 +1,10 @@ | |||
| http_address="0.0.0.0:4180" | ||||
| cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w=" | ||||
| provider="oidc" | ||||
| email_domains="example.com" | ||||
| oidc_issuer_url="http://dex.localhost:4190/dex" | ||||
| client_secret="b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK" | ||||
| client_id="oauth2-proxy" | ||||
| cookie_secure="false" | ||||
| 
 | ||||
| redirect_url="http://localhost:4180/oauth2/callback" | ||||
|  | @ -0,0 +1,17 @@ | |||
| upstreams: | ||||
|   - id: httpbin | ||||
|     path: / | ||||
|     uri: http://httpbin | ||||
| injectRequestHeaders: | ||||
| - name: X-Forwarded-Groups | ||||
|   values: | ||||
|   - claim: groups | ||||
| - name: X-Forwarded-User | ||||
|   values: | ||||
|   -   claim: user | ||||
| - name: X-Forwarded-Email | ||||
|   values: | ||||
|   - claim: email | ||||
| - name: X-Forwarded-Preferred-Username | ||||
|   values: | ||||
|   - claim: preferred_username | ||||
		Loading…
	
		Reference in New Issue