mirror of https://github.com/Ombi-app/Ombi
parent
d6b3c7ac2c
commit
759b8a3e31
@ -0,0 +1,23 @@
|
||||
import { Component, OnInit } from "@angular/core";
|
||||
import { CookieService } from "ng2-cookies";
|
||||
import { Router } from "@angular/router";
|
||||
|
||||
@Component({
|
||||
templateUrl: "cookie.component.html",
|
||||
})
|
||||
export class CookieComponent implements OnInit {
|
||||
constructor(private readonly cookieService: CookieService,
|
||||
private readonly router: Router) { }
|
||||
|
||||
public ngOnInit() {
|
||||
debugger;
|
||||
const cookie = this.cookieService.getAll();
|
||||
if(cookie.Auth) {
|
||||
const jwtVal = cookie.Auth;
|
||||
localStorage.setItem("id_token", jwtVal);
|
||||
this.router.navigate(["search"]);
|
||||
} else {
|
||||
this.router.navigate(["login"]);
|
||||
}
|
||||
}
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
FROM microsoft/dotnet:1.1-sdk-msbuild
|
||||
ARG source=./bin/Release/netcoreapp1.1/publish
|
||||
WORKDIR /app
|
||||
COPY $source .
|
||||
ENV ASPNETCORE_URLS http://*:5000
|
||||
EXPOSE 5000
|
||||
ENTRYPOINT ["dotnet", "Ombi.dll"]
|
||||
COPY . /app
|
Loading…
Reference in new issue