@@ -53,7 +53,7 @@ import {
53
53
RegistryIcon ,
54
54
ComponentSizeType ,
55
55
PasswordField ,
56
- OtherRegistryAuthenticationType ,
56
+ RegistryCredentialsType ,
57
57
} from '@devtron-labs/devtron-fe-common-lib'
58
58
import Tippy from '@tippyjs/react'
59
59
import { useHistory , useParams , useRouteMatch } from 'react-router-dom'
@@ -261,7 +261,7 @@ const CollapsedList = ({
261
261
repositoryList = [ ] ,
262
262
disabledFields = [ ] ,
263
263
ociRegistryConfig,
264
- credentialsType ,
264
+ registryCredentialsType ,
265
265
...rest
266
266
} ) => {
267
267
const [ collapsed , toggleCollapse ] = useState ( true )
@@ -341,7 +341,7 @@ const CollapsedList = ({
341
341
isPublic,
342
342
disabledFields,
343
343
ociRegistryConfig,
344
- credentialsType ,
344
+ registryCredentialsType ,
345
345
} }
346
346
/>
347
347
) }
@@ -381,7 +381,7 @@ const DockerForm = ({
381
381
: {
382
382
CONTAINER : OCIRegistryConfigConstants . PULL_PUSH ,
383
383
} ,
384
- credentialsType : authCredentialsType ,
384
+ registryCredentialsType ,
385
385
...rest
386
386
} ) => {
387
387
const re = PATTERNS . APP_NAME
@@ -544,8 +544,8 @@ const DockerForm = ({
544
544
const [ registryStorageType , setRegistryStorageType ] = useState < string > (
545
545
isPublic ? RegistryStorageType . OCI_PUBLIC : RegistryStorageType . OCI_PRIVATE ,
546
546
)
547
- const [ authenticationType , setAuthenticationType ] = useState < OtherRegistryAuthenticationType > (
548
- id && authCredentialsType ? authCredentialsType : OtherRegistryAuthenticationType . USERNAME_PASSWORD ,
547
+ const [ authenticationType , setAuthenticationType ] = useState < RegistryCredentialsType > (
548
+ id && registryCredentialsType ? registryCredentialsType : RegistryCredentialsType . USERNAME_PASSWORD ,
549
549
)
550
550
551
551
const InitialValueOfIsContainerStore : boolean =
@@ -721,7 +721,7 @@ const DockerForm = ({
721
721
}
722
722
723
723
const handleChangeOtherRegistryAuthType = ( e ) => {
724
- const updatedAuthType = e . target . value as OtherRegistryAuthenticationType
724
+ const updatedAuthType = e . target . value as RegistryCredentialsType
725
725
setAuthenticationType ( updatedAuthType )
726
726
}
727
727
@@ -818,7 +818,7 @@ const DockerForm = ({
818
818
...( registryStorageType !== RegistryStorageType . OCI_PUBLIC &&
819
819
selectedDockerRegistryType . value === RegistryType . OTHER
820
820
? {
821
- ...( authenticationType === OtherRegistryAuthenticationType . USERNAME_PASSWORD
821
+ ...( authenticationType === RegistryCredentialsType . USERNAME_PASSWORD
822
822
? {
823
823
username : trimmedUsername ,
824
824
password : parsePassword ( customState . password . value ) ,
@@ -857,7 +857,7 @@ const DockerForm = ({
857
857
sshConnectionType ,
858
858
) ,
859
859
...( AuthenticationTypeRadio && selectedDockerRegistryType . value === RegistryType . OTHER
860
- ? { credentialsType : authenticationType }
860
+ ? { registryCredentialsType : authenticationType }
861
861
: { } ) ,
862
862
}
863
863
}
@@ -1023,7 +1023,7 @@ const DockerForm = ({
1023
1023
let error = false
1024
1024
if (
1025
1025
registryStorageType === RegistryStorageType . OCI_PRIVATE &&
1026
- authenticationType === OtherRegistryAuthenticationType . USERNAME_PASSWORD &&
1026
+ authenticationType === RegistryCredentialsType . USERNAME_PASSWORD &&
1027
1027
( ! customState . username . value || ! ( customState . password . value || id ) )
1028
1028
) {
1029
1029
setCustomState ( ( st ) => ( {
@@ -1629,7 +1629,7 @@ const DockerForm = ({
1629
1629
1630
1630
const isUserNamePasswordRequired =
1631
1631
selectedDockerRegistryType . value === RegistryType . OTHER
1632
- ? authenticationType === OtherRegistryAuthenticationType . USERNAME_PASSWORD
1632
+ ? authenticationType === RegistryCredentialsType . USERNAME_PASSWORD
1633
1633
: true
1634
1634
1635
1635
return (
0 commit comments