mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-08 05:51:47 -07:00
Disable update for docker containers (#715)
Also add docker info to about page and sentry context
This commit is contained in:
parent
6afece237c
commit
4be01a5a95
13 changed files with 101 additions and 30 deletions
|
@ -16,6 +16,7 @@ class About extends Component {
|
|||
const {
|
||||
version,
|
||||
isMonoRuntime,
|
||||
isDocker,
|
||||
runtimeVersion,
|
||||
migrationVersion,
|
||||
appData,
|
||||
|
@ -42,6 +43,14 @@ class About extends Component {
|
|||
/>
|
||||
}
|
||||
|
||||
{
|
||||
isDocker &&
|
||||
<DescriptionListItem
|
||||
title="Docker"
|
||||
data={'True'}
|
||||
/>
|
||||
}
|
||||
|
||||
<DescriptionListItem
|
||||
title="DB Migration"
|
||||
data={migrationVersion}
|
||||
|
@ -83,6 +92,7 @@ About.propTypes = {
|
|||
version: PropTypes.string.isRequired,
|
||||
isMonoRuntime: PropTypes.bool.isRequired,
|
||||
runtimeVersion: PropTypes.string.isRequired,
|
||||
isDocker: PropTypes.bool.isRequired,
|
||||
migrationVersion: PropTypes.number.isRequired,
|
||||
appData: PropTypes.string.isRequired,
|
||||
startupPath: PropTypes.string.isRequired,
|
||||
|
|
|
@ -24,6 +24,7 @@ class Updates extends Component {
|
|||
error,
|
||||
items,
|
||||
isInstallingUpdate,
|
||||
isDocker,
|
||||
shortDateFormat,
|
||||
onInstallLatestPress
|
||||
} = this.props;
|
||||
|
@ -48,24 +49,34 @@ class Updates extends Component {
|
|||
|
||||
{
|
||||
hasUpdateToInstall &&
|
||||
<div className={styles.updateAvailable}>
|
||||
<SpinnerButton
|
||||
className={styles.updateAvailable}
|
||||
kind={kinds.PRIMARY}
|
||||
isSpinning={isInstallingUpdate}
|
||||
onPress={onInstallLatestPress}
|
||||
>
|
||||
Install Latest
|
||||
</SpinnerButton>
|
||||
<div className={styles.updateAvailable}>
|
||||
{
|
||||
!isDocker &&
|
||||
<SpinnerButton
|
||||
className={styles.updateAvailable}
|
||||
kind={kinds.PRIMARY}
|
||||
isSpinning={isInstallingUpdate}
|
||||
onPress={onInstallLatestPress}
|
||||
>
|
||||
Install Latest
|
||||
</SpinnerButton>
|
||||
}
|
||||
|
||||
{
|
||||
isFetching &&
|
||||
<LoadingIndicator
|
||||
className={styles.loading}
|
||||
size={20}
|
||||
/>
|
||||
}
|
||||
</div>
|
||||
{
|
||||
isDocker &&
|
||||
<div className={styles.upToDateMessage}>
|
||||
An update is available. Please update your Docker image and re-create the container.
|
||||
</div>
|
||||
}
|
||||
|
||||
{
|
||||
isFetching &&
|
||||
<LoadingIndicator
|
||||
className={styles.loading}
|
||||
size={20}
|
||||
/>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
||||
{
|
||||
|
@ -162,6 +173,7 @@ Updates.propTypes = {
|
|||
error: PropTypes.object,
|
||||
items: PropTypes.array.isRequired,
|
||||
isInstallingUpdate: PropTypes.bool.isRequired,
|
||||
isDocker: PropTypes.bool.isRequired,
|
||||
shortDateFormat: PropTypes.string.isRequired,
|
||||
onInstallLatestPress: PropTypes.func.isRequired
|
||||
};
|
||||
|
|
|
@ -6,6 +6,7 @@ import { fetchUpdates } from 'Store/Actions/systemActions';
|
|||
import { executeCommand } from 'Store/Actions/commandActions';
|
||||
import createCommandExecutingSelector from 'Store/Selectors/createCommandExecutingSelector';
|
||||
import createUISettingsSelector from 'Store/Selectors/createUISettingsSelector';
|
||||
import createSystemStatusSelector from 'Store/Selectors/createSystemStatusSelector';
|
||||
import * as commandNames from 'Commands/commandNames';
|
||||
import Updates from './Updates';
|
||||
|
||||
|
@ -14,7 +15,8 @@ function createMapStateToProps() {
|
|||
(state) => state.system.updates,
|
||||
createUISettingsSelector(),
|
||||
createCommandExecutingSelector(commandNames.APPLICATION_UPDATE),
|
||||
(updates, uiSettings, isInstallingUpdate) => {
|
||||
createSystemStatusSelector(),
|
||||
(updates, uiSettings, isInstallingUpdate, systemStatus) => {
|
||||
const {
|
||||
isFetching,
|
||||
isPopulated,
|
||||
|
@ -28,6 +30,7 @@ function createMapStateToProps() {
|
|||
error,
|
||||
items,
|
||||
isInstallingUpdate,
|
||||
isDocker: systemStatus.isDocker,
|
||||
shortDateFormat: uiSettings.shortDateFormat
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue