Comment on Element/Matrix Official Docker Install Method?
vane@lemmy.world 1 week ago
If you’re proficient it’s 30minutes
Something like this for server.
generate config
docker run -it --rm \ -v <your-data-path>:/data \ -e SYNAPSE_SERVER_NAME=<your-public-address-subdomain> \ -e SYNAPSE_REPORT_STATS=yes \ matrixdotorg/synapse:v1.136.0 generate
run
docker run -d \ --restart=always \ --name synapse \ -v <your-data-path>:/data \ -p 8008:8008 matrixdotorg/synapse:v1.136.0
register user
docker exec -ti synapse register_new_matrix_user http://localhost:8008/ -c /data/homeserver.yaml -u <username> -p <password> --exists-ok
Proxy it using ex. nginx
location / { proxy_pass http://127.0.0.1:8008/; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-for $remote_addr; proxy_connect_timeout 600; proxy_read_timeout 86400; }
For UI if you want element on your domain, download and unpack tar.gz from.
github.com/element-hq/element-web/releases
Point this location to your proxy server ex. nginx
location / { root /opt/element-v1.11.109; index index.html; }
Modify config.json inside /opt/element-v1.11.109 to point location to <your-public-address-subdomain>
captcha_incorrect@lemmy.world 1 week ago
If you like compose files: www.composerize.com
docker run -it --rm -v <your-data-path>:/data -e SYNAPSE_SERVER_NAME=<your-public-address-subdomain> -e SYNAPSE_REPORT_STATS=no matrixdotorg/synapse:v1.136.0 generate:docker run -d --restart=always --name synapse -e SYNAPSE_REPORT_STATS=no -v <your-data-path>:/data -p 8008:8008 matrixdotorg/synapse:v1.136.0:vane@lemmy.world 1 week ago
I don’t like compose files :)
captcha_incorrect@lemmy.world 6 days ago
How do you manage your containers?
vane@lemmy.world 6 days ago
I have a git repo with some directory convention and bash scripts. Ex stop is just
etc. depending on what actions I need to do against container I have bash script for that and if I need to perform such action on other container I just copy paste and change name variable. So I pull this repo to my container host and just type ./bin/synapse/stop and I stop synapse.
Hope that makes sense.