mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 01:57:35 -03:30
Make sure that the license page under settings has creds available
This commit is contained in:
parent
113622c05e
commit
611f163289
@ -53,4 +53,24 @@ export default {
|
||||
}
|
||||
});
|
||||
}],
|
||||
resolve: {
|
||||
rhCreds: ['Rest', 'GetBasePath', function(Rest, GetBasePath) {
|
||||
Rest.setUrl(`${GetBasePath('settings')}system/`);
|
||||
return Rest.get()
|
||||
.then(({data}) => {
|
||||
const rhCreds = {};
|
||||
if (data.REDHAT_USERNAME && data.REDHAT_USERNAME !== "") {
|
||||
rhCreds.REDHAT_USERNAME = data.REDHAT_USERNAME;
|
||||
}
|
||||
|
||||
if (data.REDHAT_PASSWORD && data.REDHAT_PASSWORD !== "") {
|
||||
rhCreds.REDHAT_PASSWORD = data.REDHAT_PASSWORD;
|
||||
}
|
||||
|
||||
return rhCreds;
|
||||
}).catch(() => {
|
||||
return {};
|
||||
});
|
||||
}]
|
||||
}
|
||||
};
|
||||
Loading…
x
Reference in New Issue
Block a user