commit
7a88b8002f
3 changed files with 47 additions and 7 deletions
|
@ -138,11 +138,11 @@ sudo ufw status
|
||||||
|
|
||||||
You should now have an up and running BirdsiteLIVE instance!
|
You should now have an up and running BirdsiteLIVE instance!
|
||||||
|
|
||||||
## Upgrading
|
## Updating
|
||||||
|
|
||||||
Make sure your data belong outside the containers before migrating (set by default).
|
Make sure your data belong outside the containers before migrating (set by default).
|
||||||
|
|
||||||
To upgrade your installation to the latest release:
|
To update your installation to the latest release:
|
||||||
|
|
||||||
```
|
```
|
||||||
# Edit `docker-compose.yml` to update the version, if you have one specified
|
# Edit `docker-compose.yml` to update the version, if you have one specified
|
||||||
|
@ -152,6 +152,37 @@ docker-compose pull
|
||||||
docker-compose up -d
|
docker-compose up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Auto-Updating
|
||||||
|
|
||||||
|
To set auto-updates on your deployment, add to the `docker-compose.yml` file this section:
|
||||||
|
|
||||||
|
```diff
|
||||||
|
version: "3"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
birdsitelivenetwork:
|
||||||
|
external: false
|
||||||
|
|
||||||
|
services:
|
||||||
|
server:
|
||||||
|
image: nicolasconstant/birdsitelive:latest
|
||||||
|
[...]
|
||||||
|
|
||||||
|
db:
|
||||||
|
image: postgres:9.6
|
||||||
|
[...]
|
||||||
|
|
||||||
|
+ watchtower:
|
||||||
|
+ image: containrrr/watchtower
|
||||||
|
+ restart: always
|
||||||
|
+ container_name: watchtower
|
||||||
|
+ environment:
|
||||||
|
+ - WATCHTOWER_CLEANUP=true
|
||||||
|
+ volumes:
|
||||||
|
+ - /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
+ command: --interval 300
|
||||||
|
```
|
||||||
|
|
||||||
## More options
|
## More options
|
||||||
|
|
||||||
You can find more options available [here](https://github.com/NicolasConstant/BirdsiteLive/blob/master/VARIABLES.md)
|
You can find more options available [here](https://github.com/NicolasConstant/BirdsiteLive/blob/master/VARIABLES.md)
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||||
<UserSecretsId>d21486de-a812-47eb-a419-05682bb68856</UserSecretsId>
|
<UserSecretsId>d21486de-a812-47eb-a419-05682bb68856</UserSecretsId>
|
||||||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
||||||
<Version>0.14.3</Version>
|
<Version>0.14.4</Version>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
|
|
@ -13,19 +13,28 @@ namespace BirdsiteLive.Services
|
||||||
{
|
{
|
||||||
private readonly IDatabaseInitializer _databaseInitializer;
|
private readonly IDatabaseInitializer _databaseInitializer;
|
||||||
private readonly IStatusPublicationPipeline _statusPublicationPipeline;
|
private readonly IStatusPublicationPipeline _statusPublicationPipeline;
|
||||||
|
private readonly IHostApplicationLifetime _applicationLifetime;
|
||||||
|
|
||||||
#region Ctor
|
#region Ctor
|
||||||
public FederationService(IDatabaseInitializer databaseInitializer, IStatusPublicationPipeline statusPublicationPipeline)
|
public FederationService(IDatabaseInitializer databaseInitializer, IStatusPublicationPipeline statusPublicationPipeline, IHostApplicationLifetime applicationLifetime)
|
||||||
{
|
{
|
||||||
_databaseInitializer = databaseInitializer;
|
_databaseInitializer = databaseInitializer;
|
||||||
_statusPublicationPipeline = statusPublicationPipeline;
|
_statusPublicationPipeline = statusPublicationPipeline;
|
||||||
|
_applicationLifetime = applicationLifetime;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
protected override async Task ExecuteAsync(CancellationToken stoppingToken)
|
protected override async Task ExecuteAsync(CancellationToken stoppingToken)
|
||||||
{
|
{
|
||||||
await _databaseInitializer.InitAndMigrateDbAsync();
|
try
|
||||||
await _statusPublicationPipeline.ExecuteAsync(stoppingToken);
|
{
|
||||||
|
await _databaseInitializer.InitAndMigrateDbAsync();
|
||||||
|
await _statusPublicationPipeline.ExecuteAsync(stoppingToken);
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
_applicationLifetime.StopApplication();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Add table
Reference in a new issue