Skip to content

Commit f5d2a91

Browse files
saberrazwonder-sk
authored andcommitted
updated Readme with docker steps and installation
1 parent cdf95b2 commit f5d2a91

1 file changed

Lines changed: 30 additions & 12 deletions

File tree

README.md

Lines changed: 30 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,25 +13,18 @@ Not sure where to start? Check out our [quick start](docs/quick_start.md) guide
1313

1414
<div><img align="left" width="45" height="45" src="https://raw.githubusercontent.com/MerginMaps/docs/main/src/.vuepress/public/slack.svg"><a href="https://merginmaps.com/community/join">Join our community chat</a><br/>and ask questions!</div><br />
1515

16-
### Running with Docker
1716

18-
The easiest way to run Media sync is with Docker.
19-
To build a local docker image:
20-
```
21-
docker build -t mergin_media_sync .
22-
```
23-
24-
#### Local test
25-
To run the container, use a command like the following one:
17+
#### Running with Docker
18+
To run the container, use a command like the following one:
2619
```shell
2720
docker run -it \
2821
-e MERGIN__USERNAME=john \
2922
-e MERGIN__PASSWORD=myStrongPassword \
3023
-e MERGIN__PROJECT_NAME=john/my_project \
31-
mergin_media_sync python3 media_sync_daemon.py
24+
lutraconsulting/mergin-media-sync:latest python3 media_sync_daemon.py
3225
```
33-
The sync process will start, regularly checking Mergin service copy/move media files from mergin project to external storage.
34-
Local drive is a default backend, you need to mount volume from host machine for data to persist.
26+
The sync process will start, regularly checking Mergin service copy/move media files from a Mergin project to an external storage.
27+
Local drive is a default backend, you need to mount volume from host machine for data to persist.
3528

3629
#### Update reference table in geopackage
3730
If you'd like to update references to media files (probably useful with MOVE mode), you can run:
@@ -74,6 +67,20 @@ docker run -it \
7467

7568
### Installation
7669

70+
#### Docker
71+
The easiest way to run Media sync is with Docker provided on our [docker hub repo](https://hub.docker.com/repository/docker/lutraconsulting/mergin-media-sync). You can build your own local docker image, by first cloning the repo:
72+
73+
```
74+
git clone git@github.com:lutraconsulting/mergin-media-sync.git
75+
```
76+
77+
And then building the image:
78+
79+
```
80+
docker build -t mergin_media_sync .
81+
```
82+
#### Manual installation
83+
7784
If you would like to avoid the manual installation steps, please follow the guide on using sync with Docker above. We use pipenv for managing python virtual environment.
7885

7986
```shell
@@ -125,3 +132,14 @@ To run automatic tests:
125132
export TEST_MINIO_SECRET_KEY=EXAMPLEKEY
126133
pipenv run pytest test/
127134
```
135+
136+
### Releasing new version
137+
138+
1. Update `version.py` and `CHANGELOG.md`
139+
2. Tag the new version in git repo
140+
3. Build and upload the new container (both with the new version tag and as the latest tag)
141+
```
142+
docker build --no-cache -t lutraconsulting/mergin-media-sync .
143+
docker tag lutraconsulting/mergin-media-sync lutraconsulting/mergin-media-sync:0.1.0
144+
docker push lutraconsulting/mergin-media-sync:0.1.0
145+
docker push lutraconsulting/mergin-media-sync:latest

0 commit comments

Comments
 (0)