mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
Remove useless policy dir
This commit is contained in:
parent
0b6b62f3b3
commit
f14b64b003
4 changed files with 4 additions and 9 deletions
|
|
@ -1,7 +1,7 @@
|
||||||
FROM denoland/deno:1.43.3
|
FROM denoland/deno:1.43.3
|
||||||
EXPOSE 4036
|
EXPOSE 4036
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
RUN mkdir -p data/policy && chown -R deno data
|
RUN mkdir -p data && chown -R deno data
|
||||||
USER deno
|
USER deno
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN deno cache src/server.ts
|
RUN deno cache src/server.ts
|
||||||
|
|
|
||||||
1
data/.gitignore
vendored
1
data/.gitignore
vendored
|
|
@ -1,3 +1,2 @@
|
||||||
*
|
*
|
||||||
!.gitignore
|
!.gitignore
|
||||||
!/policy
|
|
||||||
2
data/policy/.gitignore
vendored
2
data/policy/.gitignore
vendored
|
|
@ -1,2 +0,0 @@
|
||||||
*
|
|
||||||
!.gitignore
|
|
||||||
|
|
@ -3,8 +3,6 @@ import * as Comlink from 'comlink';
|
||||||
import { Conf } from '@/config.ts';
|
import { Conf } from '@/config.ts';
|
||||||
import type { CustomPolicy } from '@/workers/policy.worker.ts';
|
import type { CustomPolicy } from '@/workers/policy.worker.ts';
|
||||||
|
|
||||||
const policyDir = new URL('../../data/policy', import.meta.url).pathname;
|
|
||||||
|
|
||||||
export const policyWorker = Comlink.wrap<CustomPolicy>(
|
export const policyWorker = Comlink.wrap<CustomPolicy>(
|
||||||
new Worker(
|
new Worker(
|
||||||
new URL('./policy.worker.ts', import.meta.url),
|
new URL('./policy.worker.ts', import.meta.url),
|
||||||
|
|
@ -12,8 +10,8 @@ export const policyWorker = Comlink.wrap<CustomPolicy>(
|
||||||
type: 'module',
|
type: 'module',
|
||||||
deno: {
|
deno: {
|
||||||
permissions: {
|
permissions: {
|
||||||
read: [Conf.policy, policyDir],
|
read: [Conf.policy],
|
||||||
write: [policyDir],
|
write: false,
|
||||||
net: 'inherit',
|
net: 'inherit',
|
||||||
env: false,
|
env: false,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue