mirror of
https://github.com/ckaczor/HomeMonitor.git
synced 2026-01-14 01:25:38 -05:00
Update hub service
This commit is contained in:
@@ -5,8 +5,6 @@ VisualStudioVersion = 16.0.28711.60
|
|||||||
MinimumVisualStudioVersion = 10.0.40219.1
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Service", "Service\Service.csproj", "{11E9A9F4-9348-402E-8ADF-942F66965D32}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Service", "Service\Service.csproj", "{11E9A9F4-9348-402E-8ADF-942F66965D32}"
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Models", "..\Weather\Models\Models.csproj", "{7DE44178-B63E-4CC4-88AE-B322274EDE26}"
|
|
||||||
EndProject
|
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
@@ -17,10 +15,6 @@ Global
|
|||||||
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Release|Any CPU.Build.0 = Release|Any CPU
|
{11E9A9F4-9348-402E-8ADF-942F66965D32}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
{7DE44178-B63E-4CC4-88AE-B322274EDE26}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
|
||||||
{7DE44178-B63E-4CC4-88AE-B322274EDE26}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
|
||||||
{7DE44178-B63E-4CC4-88AE-B322274EDE26}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
|
||||||
{7DE44178-B63E-4CC4-88AE-B322274EDE26}.Release|Any CPU.Build.0 = Release|Any CPU
|
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace Hub.Service.Controllers
|
namespace ChrisKaczor.HomeMonitor.Hub.Service.Controllers
|
||||||
{
|
{
|
||||||
[Route("api/[controller]")]
|
[Route("api/[controller]")]
|
||||||
[ApiController]
|
[ApiController]
|
||||||
|
|||||||
@@ -4,14 +4,13 @@ EXPOSE 80
|
|||||||
|
|
||||||
FROM microsoft/dotnet:2.2-sdk-stretch AS build
|
FROM microsoft/dotnet:2.2-sdk-stretch AS build
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY ["Hub/Service/Service.csproj", "Hub/Service/"]
|
COPY ["./Service.csproj", "./"]
|
||||||
COPY ["Weather/Models/Models.csproj", "Weather/Models/"]
|
RUN dotnet restore "Service.csproj"
|
||||||
RUN dotnet restore "Hub/Service/Service.csproj"
|
|
||||||
COPY . .
|
COPY . .
|
||||||
WORKDIR "/src/Hub/Service"
|
WORKDIR "/src"
|
||||||
RUN dotnet publish "Service.csproj" -c Release -o /app
|
RUN dotnet publish "Service.csproj" -c Release -o /app
|
||||||
|
|
||||||
FROM base AS final
|
FROM base AS final
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY --from=build /app .
|
COPY --from=build /app .
|
||||||
ENTRYPOINT ["dotnet", "Hub.Service.dll"]
|
ENTRYPOINT ["dotnet", "ChrisKaczor.HomeMonitor.Hub.Service.dll"]
|
||||||
@@ -3,7 +3,7 @@ using Microsoft.AspNetCore.SignalR;
|
|||||||
using System;
|
using System;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace Hub.Service.Hubs
|
namespace ChrisKaczor.HomeMonitor.Hub.Service.Hubs
|
||||||
{
|
{
|
||||||
[UsedImplicitly]
|
[UsedImplicitly]
|
||||||
public class WeatherHub : Microsoft.AspNetCore.SignalR.Hub
|
public class WeatherHub : Microsoft.AspNetCore.SignalR.Hub
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
using Microsoft.AspNetCore;
|
using Microsoft.AspNetCore;
|
||||||
using Microsoft.AspNetCore.Hosting;
|
using Microsoft.AspNetCore.Hosting;
|
||||||
|
|
||||||
namespace Hub.Service
|
namespace ChrisKaczor.HomeMonitor.Hub.Service
|
||||||
{
|
{
|
||||||
public static class Program
|
public static class Program
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -4,18 +4,15 @@
|
|||||||
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
|
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
|
||||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||||
<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
|
<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
|
||||||
<AssemblyName>Hub.Service</AssemblyName>
|
<AssemblyName>ChrisKaczor.HomeMonitor.Hub.Service</AssemblyName>
|
||||||
<RootNamespace>Hub.Service</RootNamespace>
|
<RootNamespace>ChrisKaczor.HomeMonitor.Hub.Service</RootNamespace>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<PackageReference Include="ChrisKaczor.HomeMonitor.Weather.Models" Version="1.0.6" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.App" />
|
<PackageReference Include="Microsoft.AspNetCore.App" />
|
||||||
<PackageReference Include="JetBrains.Annotations" Version="2019.1.3" />
|
<PackageReference Include="JetBrains.Annotations" Version="2019.1.3" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
|
||||||
<ProjectReference Include="..\..\Weather\Models\Models.csproj" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
using Hub.Service.Hubs;
|
using ChrisKaczor.HomeMonitor.Hub.Service.Hubs;
|
||||||
using Microsoft.AspNetCore.Builder;
|
using Microsoft.AspNetCore.Builder;
|
||||||
using Microsoft.AspNetCore.Hosting;
|
using Microsoft.AspNetCore.Hosting;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
|
|
||||||
namespace Hub.Service
|
namespace ChrisKaczor.HomeMonitor.Hub.Service
|
||||||
{
|
{
|
||||||
public class Startup
|
public class Startup
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user