Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
5171469d
Commit
5171469d
authored
Apr 29, 2019
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab-ce master
parents
9f2038c5
6050de19
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
30 additions
and
43 deletions
+30
-43
app/assets/javascripts/clusters/clusters_bundle.js
app/assets/javascripts/clusters/clusters_bundle.js
+4
-8
app/assets/javascripts/mirrors/ssh_mirror.js
app/assets/javascripts/mirrors/ssh_mirror.js
+1
-1
app/assets/javascripts/monitoring/services/monitoring_service.js
...ets/javascripts/monitoring/services/monitoring_service.js
+2
-2
app/assets/javascripts/mr_popover/constants.js
app/assets/javascripts/mr_popover/constants.js
+5
-3
app/assets/javascripts/vue_shared/components/content_viewer/lib/viewer_utils.js
.../vue_shared/components/content_viewer/lib/viewer_utils.js
+3
-1
changelogs/unreleased/61036-fix-ingress-base-domain-text.yml
changelogs/unreleased/61036-fix-ingress-base-domain-text.yml
+5
-0
locale/gitlab.pot
locale/gitlab.pot
+3
-0
spec/frontend/clusters/clusters_bundle_spec.js
spec/frontend/clusters/clusters_bundle_spec.js
+7
-28
No files found.
app/assets/javascripts/clusters/clusters_bundle.js
View file @
5171469d
...
@@ -279,14 +279,10 @@ export default class Clusters {
...
@@ -279,14 +279,10 @@ export default class Clusters {
this
.
store
.
acknowledgeSuccessfulUpdate
(
appId
);
this
.
store
.
acknowledgeSuccessfulUpdate
(
appId
);
}
}
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
)
{
toggleIngressDomainHelpText
({
externalIp
},
{
externalIp
:
newExternalIp
})
{
const
{
externalIp
,
status
}
=
ingressNewState
;
if
(
externalIp
!==
newExternalIp
)
{
const
helpTextHidden
=
status
!==
APPLICATION_STATUS
.
INSTALLED
||
!
externalIp
;
this
.
ingressDomainHelpText
.
classList
.
toggle
(
'
hide
'
,
!
newExternalIp
);
const
domainSnippetText
=
`
${
externalIp
}${
INGRESS_DOMAIN_SUFFIX
}
`
;
this
.
ingressDomainSnippet
.
textContent
=
`
${
newExternalIp
}${
INGRESS_DOMAIN_SUFFIX
}
`
;
if
(
ingressPreviousState
.
status
!==
status
)
{
this
.
ingressDomainHelpText
.
classList
.
toggle
(
'
hide
'
,
helpTextHidden
);
this
.
ingressDomainSnippet
.
textContent
=
domainSnippetText
;
}
}
}
}
...
...
app/assets/javascripts/mirrors/ssh_mirror.js
View file @
5171469d
...
@@ -290,7 +290,7 @@ export default class SSHMirror {
...
@@ -290,7 +290,7 @@ export default class SSHMirror {
this
.
setSSHPublicKey
(
data
.
import_data_attributes
.
ssh_public_key
);
this
.
setSSHPublicKey
(
data
.
import_data_attributes
.
ssh_public_key
);
})
})
.
catch
(()
=>
{
.
catch
(()
=>
{
Flash
(
_
(
'
Unable to regenerate public ssh key.
'
));
Flash
(
_
_
(
'
Unable to regenerate public ssh key.
'
));
});
});
}
}
...
...
app/assets/javascripts/monitoring/services/monitoring_service.js
View file @
5171469d
import
axios
from
'
../../lib/utils/axios_utils
'
;
import
axios
from
'
../../lib/utils/axios_utils
'
;
import
statusCodes
from
'
../../lib/utils/http_status
'
;
import
statusCodes
from
'
../../lib/utils/http_status
'
;
import
{
backOff
}
from
'
../../lib/utils/common_utils
'
;
import
{
backOff
}
from
'
../../lib/utils/common_utils
'
;
import
{
s__
}
from
'
../../locale
'
;
import
{
s__
,
__
}
from
'
../../locale
'
;
const
MAX_REQUESTS
=
3
;
const
MAX_REQUESTS
=
3
;
...
@@ -15,7 +15,7 @@ function backOffRequest(makeRequestCallback) {
...
@@ -15,7 +15,7 @@ function backOffRequest(makeRequestCallback) {
if
(
requestCounter
<
MAX_REQUESTS
)
{
if
(
requestCounter
<
MAX_REQUESTS
)
{
next
();
next
();
}
else
{
}
else
{
stop
(
new
Error
(
'
Failed to connect to the prometheus server
'
));
stop
(
new
Error
(
__
(
'
Failed to connect to the prometheus server
'
)
));
}
}
}
else
{
}
else
{
stop
(
resp
);
stop
(
resp
);
...
...
app/assets/javascripts/mr_popover/constants.js
View file @
5171469d
import
{
__
}
from
'
~/locale
'
;
export
const
mrStates
=
{
export
const
mrStates
=
{
merged
:
'
merged
'
,
merged
:
'
merged
'
,
closed
:
'
closed
'
,
closed
:
'
closed
'
,
};
};
export
const
humanMRStates
=
{
export
const
humanMRStates
=
{
merged
:
'
Merged
'
,
merged
:
__
(
'
Merged
'
)
,
closed
:
'
Closed
'
,
closed
:
__
(
'
Closed
'
)
,
open
:
'
Open
'
,
open
:
__
(
'
Open
'
)
,
};
};
app/assets/javascripts/vue_shared/components/content_viewer/lib/viewer_utils.js
View file @
5171469d
import
{
__
}
from
'
~/locale
'
;
const
viewers
=
{
const
viewers
=
{
image
:
{
image
:
{
id
:
'
image
'
,
id
:
'
image
'
,
},
},
markdown
:
{
markdown
:
{
id
:
'
markdown
'
,
id
:
'
markdown
'
,
previewTitle
:
'
Preview Markdown
'
,
previewTitle
:
__
(
'
Preview Markdown
'
)
,
},
},
};
};
...
...
changelogs/unreleased/61036-fix-ingress-base-domain-text.yml
0 → 100644
View file @
5171469d
---
title
:
Fix base domain help text update
merge_request
:
27746
author
:
type
:
fixed
locale/gitlab.pot
View file @
5171469d
...
@@ -4804,6 +4804,9 @@ msgstr ""
...
@@ -4804,6 +4804,9 @@ msgstr ""
msgid "Failed to check related branches."
msgid "Failed to check related branches."
msgstr ""
msgstr ""
msgid "Failed to connect to the prometheus server"
msgstr ""
msgid "Failed to create repository via gitlab-shell"
msgid "Failed to create repository via gitlab-shell"
msgstr ""
msgstr ""
...
...
spec/frontend/clusters/clusters_bundle_spec.js
View file @
5171469d
...
@@ -6,7 +6,7 @@ import { loadHTMLFixture } from 'helpers/fixtures';
...
@@ -6,7 +6,7 @@ import { loadHTMLFixture } from 'helpers/fixtures';
import
{
setTestTimeout
}
from
'
helpers/timeout
'
;
import
{
setTestTimeout
}
from
'
helpers/timeout
'
;
import
$
from
'
jquery
'
;
import
$
from
'
jquery
'
;
const
{
INSTALLING
,
INSTALLABLE
,
INSTALLED
,
NOT_INSTALLABLE
}
=
APPLICATION_STATUS
;
const
{
INSTALLING
,
INSTALLABLE
,
INSTALLED
}
=
APPLICATION_STATUS
;
describe
(
'
Clusters
'
,
()
=>
{
describe
(
'
Clusters
'
,
()
=>
{
setTestTimeout
(
1000
);
setTestTimeout
(
1000
);
...
@@ -317,13 +317,12 @@ describe('Clusters', () => {
...
@@ -317,13 +317,12 @@ describe('Clusters', () => {
let
ingressNewState
;
let
ingressNewState
;
beforeEach
(()
=>
{
beforeEach
(()
=>
{
ingressPreviousState
=
{
status
:
INSTALLABLE
};
ingressPreviousState
=
{
externalIp
:
null
};
ingressNewState
=
{
status
:
INSTALLED
,
externalIp
:
'
127.0.0.1
'
};
ingressNewState
=
{
externalIp
:
'
127.0.0.1
'
};
});
});
describe
(
`when ingress
application new status is
${
INSTALLED
}
`
,
()
=>
{
describe
(
`when ingress
have an external ip assigned
`
,
()
=>
{
beforeEach
(()
=>
{
beforeEach
(()
=>
{
ingressNewState
.
status
=
INSTALLED
;
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
});
});
...
@@ -338,31 +337,11 @@ describe('Clusters', () => {
...
@@ -338,31 +337,11 @@ describe('Clusters', () => {
});
});
});
});
describe
(
`when ingress
application new status is different from
${
INSTALLED
}
`
,
()
=>
{
describe
(
`when ingress
does not have an external ip assigned
`
,
()
=>
{
it
(
'
hides custom domain help text
'
,
()
=>
{
it
(
'
hides custom domain help text
'
,
()
=>
{
ingressNewState
.
status
=
NOT_INSTALLABLE
;
ingressPreviousState
.
externalIp
=
'
127.0.0.1
'
;
cluster
.
ingressDomainHelpText
.
classList
.
remove
(
'
hide
'
);
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
expect
(
cluster
.
ingressDomainHelpText
.
classList
.
contains
(
'
hide
'
)).
toEqual
(
true
);
});
});
describe
(
'
when ingress application new status and old status are the same
'
,
()
=>
{
it
(
'
does not display custom domain help text
'
,
()
=>
{
ingressPreviousState
.
status
=
INSTALLED
;
ingressNewState
.
status
=
ingressPreviousState
.
status
;
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
expect
(
cluster
.
ingressDomainHelpText
.
classList
.
contains
(
'
hide
'
)).
toEqual
(
true
);
});
});
describe
(
`when ingress new status is
${
INSTALLED
}
and there isn’t an ip assigned`
,
()
=>
{
it
(
'
does not display custom domain help text
'
,
()
=>
{
ingressNewState
.
externalIp
=
null
;
ingressNewState
.
externalIp
=
null
;
cluster
.
ingressDomainHelpText
.
classList
.
remove
(
'
hide
'
);
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
cluster
.
toggleIngressDomainHelpText
(
ingressPreviousState
,
ingressNewState
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment