Skip to content

Commit 35cfe28

Browse files
authored
EPR: enable proxy mode (#957)
* EPR: enable proxy mode * Address PR comments * Use ENV
1 parent 64b8a71 commit 35cfe28

File tree

4 files changed

+11
-8
lines changed

4 files changed

+11
-8
lines changed
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
FROM __BASE_IMAGE__
2-
32
ARG PROFILE
3+
4+
# Disable package validation (already done).
5+
ENV EPR_DISABLE_PACKAGE_VALIDATION=true
6+
7+
ENV EPR_FEATURE_PROXY_MODE=true
8+
49
COPY profiles/${PROFILE}/stack/package-registry.config.yml /package-registry/config.yml
5-
COPY stack/development/ /packages/development
10+
COPY stack/development/ /packages/development

internal/profile/_static/docker-compose-stack.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ services:
6161
retries: 300
6262
interval: 1s
6363
environment:
64+
- "EPR_LOG_LEVEL=debug"
6465
- "EPR_ADDRESS=0.0.0.0:8080"
6566
- "EPR_METRICS_ADDRESS=0.0.0.0:9000"
6667
- "EPR_TLS_KEY=/etc/ssl/package-registry/key.pem"
Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
package_paths:
2-
- /packages/development
3-
- /packages/production
4-
- /packages/staging
5-
- /packages/snapshot
2+
- /packages/development

internal/profile/static.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,6 @@ var packageRegistryConfigYml string
115115

116116
// newPackageRegistryConfig returns a Managed Config
117117
func newPackageRegistryConfig(_ string, profilePath string) (*simpleFile, error) {
118-
119118
return &simpleFile{
120119
name: string(PackageRegistryConfigFile),
121120
path: filepath.Join(profilePath, profileStackPath, string(PackageRegistryConfigFile)),
@@ -124,7 +123,8 @@ func newPackageRegistryConfig(_ string, profilePath string) (*simpleFile, error)
124123
}
125124

126125
// PackageRegistryBaseImage is the base Docker image of the Elastic Package Registry.
127-
const PackageRegistryBaseImage = "docker.elastic.co/package-registry/distribution:snapshot"
126+
// commit SHA of enabled proxy mode (technical preview feature)
127+
const PackageRegistryBaseImage = "docker.elastic.co/package-registry/package-registry:14455fcb7e415d6b4aed48e00d2289718f056162"
128128

129129
// PackageRegistryDockerfileFile is the dockerfile for the Elastic package registry
130130
const PackageRegistryDockerfileFile configFile = "Dockerfile.package-registry"

0 commit comments

Comments
 (0)