diff --git a/.snapcraft/resources/startRocketChat b/.snapcraft/resources/startRocketChat index 9963948d50b..50d257b4515 100755 --- a/.snapcraft/resources/startRocketChat +++ b/.snapcraft/resources/startRocketChat @@ -3,6 +3,14 @@ function start_rocketchat { echo "Checking if oplog has been enabled, and enabling if not" LC_ALL=C mongo $SNAP/bin/initreplset.js + + ## For making fonts work for sharp + export XDG_DATA_HOME=$SNAP/usr/share + + # Font Config + export FONTCONFIG_PATH=$SNAP/etc/fonts/config.d + export FONTCONFIG_FILE=$SNAP/etc/fonts/fonts.conf + export DEPLOY_METHOD=snap export NODE_ENV=production diff --git a/.snapcraft/snapcraft.yaml b/.snapcraft/snapcraft.yaml index 77bd479d66e..60c6b5b05bd 100644 --- a/.snapcraft/snapcraft.yaml +++ b/.snapcraft/snapcraft.yaml @@ -16,7 +16,7 @@ apps: rocketchat-server: command: startRocketChat daemon: simple - plugs: [network, network-bind, desktop] + plugs: [network, network-bind] rocketchat-mongo: command: startmongo daemon: simple @@ -54,10 +54,13 @@ parts: source: . stage-packages: - execstack + - fontconfig-config stage: - programs - main.js - .node_version.txt + - etc + - usr mongodb: build-packages: - wget