-
Notifications
You must be signed in to change notification settings - Fork 0
/
snapcraft.yaml
40 lines (38 loc) · 982 Bytes
/
snapcraft.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Copyright 2024 Canonical Ltd.
# See LICENSE file for licensing details.
name: mjolnir
summary: Mjolnir snap
description: A moderation tool for Matrix
version: 1.8.3
base: core22
license: Apache-2.0
confinement: strict
architectures:
- build-on: [amd64]
build-for: [amd64]
apps:
mjolnir:
command: "bin/node $SNAP/mjolnir/index.js"
plugs:
- network
parts:
node:
plugin: dump
source: https://nodejs.org/dist/v20.2.0/node-v20.2.0-linux-x64.tar.xz
stage:
- bin
- include
- lib
install-mjolnir:
after: [node]
plugin: nil
source: https://github.com/matrix-org/mjolnir.git
source-tag: v1.8.3
source-type: git
override-build: |
npm install -g yarn@1.22.19
yarn install
yarn build
mv lib $CRAFT_PRIME/mjolnir
mv node_modules $CRAFT_PRIME/
mv mjolnir-entrypoint.sh $CRAFT_PRIME/