Debian based version:
Main docker image based on Debian and used by default in the docker-compose.yml
. Recommended for test and production deployments.
Alpine based version:
Minimal docker image based on Alpine can be used for expert setups. In order to prevent crashes due to dependency problems, this version comes without PDF export.
- git (https://git-scm.com/)
- docker (https://www.docker.com/community-edition)
- docker-compose (https://docs.docker.com/compose/install/)
See more here: https://docs.docker.com/
- Install docker and docker-compose, "Docker for Windows" or "Docker for Mac"
- Run
git clone https://github.com/codimd/container.git codimd-container
- Change to the directory
codimd-container
directory - Run
docker-compose up
in your terminal - Wait until see the log
HTTP Server listening at port 3000
, it will take few minutes based on your internet connection. - Open http://127.0.0.1:3000
Start your docker and enter the terminal, follow below commands:
cd codimd-container ## enter the directory
git pull ## pull new commits
docker-compose pull ## pull new containers
docker-compose up ## turn on
If you used the docker-hackmd
repository before, migrating to codimd-container
is easy.
Since codimd-container is basically a fork of docker-hackmd
, all you need to do is replacing the upstream URL.
git remote set-url origin https://github.com/codimd/container.git
git pull
Now you can follow the regular update steps.
We don't use LZString to compress socket.io data and DB data after version 0.5.0. Please run the migration tool if you're upgrading from the old version.
- Stop your CodiMD containers
- Modify
docker-compose.yml
, add expose ports5432
tohackmdPostgres
docker-compose up
to start your codimd containers- Backup DB (see below)
- Git clone above
migration-to-0.5.0
andnpm install
(see more on above link) - Modify
config.json
inmigration-to-0.5.0
, change itsusername
,password
andhost
to your docker - Run migration (see more on above link)
- Stop your codimd containers
- Modify
docker-compose.yml
, remove expose ports5432
inhackmdPostgres
- git pull in
codimd-container
, update to version 0.5.0 (see below)
Start your docker and enter the terminal, follow below commands:
docker-compose exec database pg_dump hackmd -U hackmd > backup.sql
Before starting the application for the first time, run these commands:
docker-compose up -d database
cat backup.sql | docker exec -i $(docker-compose ps -q database) psql -U hackmd
To install use helm install stable/hackmd
.
For all further details, please check out the offical HackMD K8s helm chart.
The default setting would use pre-build docker image, if you want to build your own containers
uncomment the build
section in the docker-compose.yml
and edit the config.json
.
If you change the database settings and don't use the HMD_DB_URL
make sure you edit the .sequelizerc
.
View license information for the software contained in this image.
This image is officially supported on Docker version 17.03.1-CE.
Support for older versions (down to 1.12) is provided on a best-effort basis.
Please see the Docker installation documentation for details on how to upgrade your Docker daemon.
If you have any problems with or questions about this image, please contact us through a GitHub issue.
You can also reach many of the project maintainers via our #codimd:matrix.org
.
You are invited to contribute new features, fixes, or updates, large or small; we are always thrilled to receive pull requests, and do our best to process them as fast as we can.
Happy CodiMD 😄