diff --git a/Dockerfile b/Dockerfile
index ab192c68..57b547ae 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -12,7 +12,8 @@ FROM alpine:latest
RUN apk add --update --no-cache lighttpd
ADD lighttpd.conf /etc/lighttpd/lighttpd.conf
-COPY --from=build /build/dist /app
+COPY --from=build /build/dist /app/sengi
+COPY --from=build /build/assets/docker_init /app
EXPOSE 80
diff --git a/assets/docker_init/index.html b/assets/docker_init/index.html
new file mode 100644
index 00000000..38e77596
--- /dev/null
+++ b/assets/docker_init/index.html
@@ -0,0 +1 @@
+
TEST
\ No newline at end of file
diff --git a/lighttpd.conf b/lighttpd.conf
index 420fabfa..7b0d821f 100644
--- a/lighttpd.conf
+++ b/lighttpd.conf
@@ -10,5 +10,5 @@ server.modules = (
include "mime-types.conf"
server.pid-file = "/run/lighttpd.pid"
index-file.names = ( "index.html", "index.htm" )
-url.rewrite-once = ( "^/(.*)" => "/index.html" )
-server.error-handler-404 = "/index.html"
\ No newline at end of file
+#url.rewrite-once = ( "^sengi/(.*)" => "/sengi/index.html" )
+server.error-handler-404 = "/sengi/index.html"
\ No newline at end of file
diff --git a/src/app/components/floating-column/add-new-account/add-new-account.component.ts b/src/app/components/floating-column/add-new-account/add-new-account.component.ts
index a031f780..3176d2c8 100644
--- a/src/app/components/floating-column/add-new-account/add-new-account.component.ts
+++ b/src/app/components/floating-column/add-new-account/add-new-account.component.ts
@@ -6,6 +6,7 @@ import { RegisteredAppsStateModel, AppInfo, AddRegisteredApp } from '../../../st
import { AuthService, CurrentAuthProcess } from '../../../services/auth.service';
import { AppData } from '../../../services/models/mastodon.interfaces';
import { NotificationService } from '../../../services/notification.service';
+import { HttpXsrfInterceptor } from '@angular/common/http/src/xsrf';
@Component({
selector: 'app-add-new-account',
@@ -132,8 +133,12 @@ export class AddNewAccountComponent implements OnInit {
}
private getLocalHostname(): string {
- let localHostname = location.protocol + '//' + location.hostname + (location.port ? ':' + location.port : '');
- return localHostname;
+ let href = window.location.href;
+ if(href.includes('/home')){
+ return href.split('/home')[0];
+ } else {
+ return location.protocol + '//' + location.hostname + (location.port ? ':' + location.port : '');
+ }
}
private saveNewApp(instance: string, app: AppData): Promise {