File tree Expand file tree Collapse file tree 5 files changed +25
-17
lines changed
Compose/ProductionBuilder/Service Expand file tree Collapse file tree 5 files changed +25
-17
lines changed Original file line number Diff line number Diff line change @@ -50,22 +50,30 @@ public function getServiceName(): string
50
50
* @inheritDoc
51
51
*/
52
52
public function getConfig (Config $ config ): array
53
- {
54
- return $ this ->serviceFactory ->create (
55
- $ this ->getServiceName (),
56
- $ config ->getServiceVersion ($ this ->getServiceName ()),
57
- [
53
+ {
54
+ $ configArray = $ this ->serviceFactory ->create (
55
+ $ this ->getServiceName (),
56
+ $ config ->getServiceVersion ($ this ->getServiceName ()),
57
+ [
58
58
BuilderInterface::SERVICE_HEALTHCHECK => [
59
- 'test ' => 'valkey-cli ping || exit 1 ' ,
60
- 'interval ' => '30s ' ,
61
- 'timeout ' => '30s ' ,
62
- 'retries ' => 3
59
+ 'test ' => 'valkey-cli ping || exit 1 ' ,
60
+ 'interval ' => '30s ' ,
61
+ 'timeout ' => '30s ' ,
62
+ 'retries ' => 3
63
63
]
64
- ],
65
- $ config ->getServiceImage ($ this ->getServiceName ()),
66
- $ config ->getCustomRegistry ()
64
+ ],
65
+ $ config ->getServiceImage ($ this ->getServiceName ()),
66
+ $ config ->getCustomRegistry ()
67
67
);
68
- }
68
+
69
+ // Set both 'cache' and 'valkey.magento2.docker' as aliases unconditionally
70
+ $ configArray ['networks ' ][BuilderInterface::NETWORK_MAGENTO ]['aliases ' ] = [
71
+ 'cache ' ,
72
+ 'valkey.magento2.docker '
73
+ ];
74
+
75
+ return $ configArray ;
76
+ }
69
77
70
78
/**
71
79
* @inheritDoc
Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ class Relationship
57
57
],
58
58
'valkey ' => [
59
59
[
60
- 'host ' => 'valkey ' ,
60
+ 'host ' => 'cache ' ,
61
61
'port ' => '6379 '
62
62
]
63
63
],
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ class CliSource implements SourceInterface
27
27
public const OPTION_EXPOSE_DB_QUOTE_PORT = 'expose-db-quote-port ' ;
28
28
public const OPTION_EXPOSE_DB_SALES_PORT = 'expose-db-sales-port ' ;
29
29
public const OPTION_REDIS = 'redis ' ;
30
- public const OPTION_VALKEY = 'cache ' ;
30
+ public const OPTION_VALKEY = 'valkey ' ;
31
31
public const OPTION_ES = 'es ' ;
32
32
public const OPTION_OS = 'os ' ;
33
33
public const OPTION_RABBIT_MQ = 'rmq ' ;
Original file line number Diff line number Diff line change @@ -47,7 +47,7 @@ class CloudSource implements SourceInterface
47
47
ServiceInterface::SERVICE_ELASTICSEARCH => ['elasticsearch ' , 'es ' ],
48
48
ServiceInterface::SERVICE_OPENSEARCH => ['opensearch ' , 'os ' ],
49
49
ServiceInterface::SERVICE_REDIS => ['redis ' ],
50
- ServiceInterface::SERVICE_VALKEY => ['cache ' ],
50
+ ServiceInterface::SERVICE_VALKEY => ['cache ' , ' valkey ' ],
51
51
ServiceInterface::SERVICE_RABBITMQ => ['rmq ' , 'rabbitmq ' ]
52
52
];
53
53
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ interface ServiceInterface
23
23
public const SERVICE_DB_SALES = 'mysql-sales ' ;
24
24
public const SERVICE_NGINX = 'nginx ' ;
25
25
public const SERVICE_REDIS = 'redis ' ;
26
- public const SERVICE_VALKEY = 'cache ' ;
26
+ public const SERVICE_VALKEY = 'valkey ' ;
27
27
public const SERVICE_ELASTICSEARCH = 'elasticsearch ' ;
28
28
public const SERVICE_OPENSEARCH = 'opensearch ' ;
29
29
public const SERVICE_RABBITMQ = 'rabbitmq ' ;
You can’t perform that action at this time.
0 commit comments