File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -149,6 +149,7 @@ func build(
149149 slugName ,
150150 conf .StorageType ,
151151 conf .DockerBuilderImage ,
152+ conf .RegistryProxyPort ,
152153 dockerBuilderImagePullPolicy ,
153154 )
154155 } else {
Original file line number Diff line number Diff line change @@ -14,10 +14,10 @@ const (
1414// builder's git-receive hook.
1515type Config struct {
1616 // k8s service discovery env vars
17- ControllerHost string `envconfig:"DEIS_CONTROLLER_SERVICE_HOST" required:"true"`
18- ControllerPort string `envconfig:"DEIS_CONTROLLER_SERVICE_PORT" required:"true"`
19- RegistryHost string `envconfig:"DEIS_REGISTRY_SERVICE_HOST" required:"true"`
20- RegistryPort string `envconfig:"DEIS_REGISTRY_SERVICE_PORT" required:"true "`
17+ ControllerHost string `envconfig:"DEIS_CONTROLLER_SERVICE_HOST" required:"true"`
18+ ControllerPort string `envconfig:"DEIS_CONTROLLER_SERVICE_PORT" required:"true"`
19+ RegistryHost string `envconfig:"DEIS_REGISTRY_SERVICE_HOST" required:"true"`
20+ RegistryProxyPort string `envconfig:"DEIS_REGISTRY_PROXY_PORT" default:"5555 "`
2121
2222 GitHome string `envconfig:"GIT_HOME" required:"true"`
2323 SSHConnection string `envconfig:"SSH_CONNECTION" required:"true"`
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ func dockerBuilderPod(
4343 tarKey ,
4444 imageName ,
4545 storageType ,
46- image string ,
46+ image , registryProxyPort string ,
4747 pullPolicy api.PullPolicy ,
4848) * api.Pod {
4949
@@ -55,6 +55,7 @@ func dockerBuilderPod(
5555 addEnvToPod (pod , tarPath , tarKey )
5656 addEnvToPod (pod , "IMG_NAME" , imageName )
5757 addEnvToPod (pod , builderStorage , storageType )
58+ addEnvToPod (pod , "DEIS_REGISTRY_PROXY_PORT" , registryProxyPort )
5859
5960 pod .Spec .Containers [0 ].VolumeMounts = append (pod .Spec .Containers [0 ].VolumeMounts , api.VolumeMount {
6061 Name : dockerSocketName ,
Original file line number Diff line number Diff line change @@ -132,6 +132,7 @@ func TestBuildPod(t *testing.T) {
132132 build .imgName ,
133133 build .storageType ,
134134 build .dockerBuilderImage ,
135+ "5555" ,
135136 build .dockerBuilderImagePullPolicy ,
136137 )
137138
You can’t perform that action at this time.
0 commit comments