README.md 5.12 KB
Newer Older
1
[![build status](https://gitlab.com/fdroid/repomaker/badges/master/build.svg)](https://gitlab.com/fdroid/repomaker/commits/master)
2
3
[![coverage report](https://gitlab.com/fdroid/repomaker/badges/master/coverage.svg)](https://gitlab.com/fdroid/repomaker/-/jobs)
[![translation status](https://hosted.weblate.org/widgets/f-droid/-/repomaker/svg-badge.svg)](https://hosted.weblate.org/projects/f-droid/repomaker/)
4

5
Repomaker needs a maintainer, please adopt me!  Repomaker currently runs on Django 1.11, which went out of security support in July 2020. Please see [#234](https://gitlab.com/fdroid/repomaker/-/issues/233) for more information.
Torsten Grote's avatar
Torsten Grote committed
6

7
# Installation
Nico Alt's avatar
Nico Alt committed
8

9
10
11
12
13
14
15
There are several different ways to install Repomaker.

## Flatpak

Repomaker is available as Flatpak and
[distributed on Flathub](https://flathub.org/apps/details/org.fdroid.Repomaker).
Once you got [Flatpak installed on your system](https://flatpak.org/setup/),
16
17
18
19
20
21
either go to your system's app store or execute the following commands (without `sudo`!):

```console
$ flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
$ flatpak install flathub org.fdroid.Repomaker
$ flatpak run --runtime=org.gnome.Sdk org.fdroid.Repomaker
22
23
```

24
25
## On a server / Docker

26
27
28
29
There is a test image available in Docker for quickly trying out
Repomaker.  Note that you can run Repomaker on a server and make use
of its multi user functionality.  See [Docker
docs](https://gitlab.com/fdroid/repomaker/tree/master/docker) and the
30
31
32
33
[general docs](https://gitlab.com/fdroid/repomaker/tree/master/doc)
for more information on that topic.


34
35
36
37
38
## PyPi

If you don't want or can't install Repomaker with one of the mentioned
methods, you can install it with _pip_ from PyPi.

39

40
### Requirements
Torsten Grote's avatar
Torsten Grote committed
41

42
43
Please make sure you have the following requirements installed
before proceeding with the installation. 
Torsten Grote's avatar
Torsten Grote committed
44

45

46
#### Install
47

48
* `pip` for installation of Python 3 dependencies
49
* `virtualenv` to create an isolated Python environment
50
51
52
53
54
* Python development and build files for installing/building some dependencies

On Debian, you can simply run this:

`apt install python3-pip python3-wheel python3-dev virtualenv build-essential`
55

56
#### Runtime
57

58
* `keytool` from Java Runtime Environment (JRE)
59
* `jarsigner` from Java JDK for signing the repo indexes
60
61
62
* `libmagic` for mime-type detection
* `rsync` to publish repositories
* `git` to publish repositories to git mirrors
63
64
65

On Debian, you can simply run this:

66
67
68
69
```
sudo apt install fdroidserver libmagic1 rsync git \
    python3-pyqt5.qtwebengine python3-pyqt5.qtwebkit
```
70

71
### Install into virtual environment
72
73
74
75

To not mess with other Python libraries you have installed,
we will install repomaker into its own isolated Python environment.

76
    virtualenv -p /usr/bin/python3 repomaker
77
78
79
80
81
82
83
    source repomaker/bin/activate
    pip install repomaker[gui]

You should now be able to start by typing:

    repomaker

Nico Alt's avatar
Nico Alt committed
84

85
### Troubleshooting
86
87
88
89
90
91
92
93
94
95
96

First check that you really have all dependencies from above installed.

If the installation fails with something about `openssl`,
try to install `libssl-dev` with `apt install libssl-dev`.

If the graphical user interface fails to start,
you can try running `repomaker-server` and `repomaker-tasks`.
If that works, you should be able to open [127.0.0.1:8000](http://127.0.0.1:8000/)
in your browser.

97

98
# Development
99

Nico Alt's avatar
Nico Alt committed
100
To work on repomaker, you need _npm_ to fetch CSS and JavaScript dependencies: `apt install npm`.
Torsten Grote's avatar
Torsten Grote committed
101

102
103
Then run `npm install` to install these dependencies.

Nico Alt's avatar
Nico Alt committed
104
105
106
107
108
109
110
111
If you want to run repomaker in your browser rather then using the GUI,
you can start it like this:

    virtualenv -p /usr/bin/python3 repomaker
    source repomaker/bin/activate
    ./setup.sh
    ./run.sh

112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
## Vagrant VM

There also a Vagrant setup based on the GitLab CI setup, it is a quick
way to get a development setup.  First, set up Vagrant on your machine,
then run:

```console
$ cd repomaker
$ vagrant up
$ vagrant ssh
vagrant@basebox-buster64:~$ ip a | sed -En 's,.*inet +(192\.168\.[0-9]+\.[0-9]+).*,open http://\1:8000,p'
open http://192.168.121.37:8000
vagrant@basebox-buster64:~$ cd $CI_PROJECT_DIR
vagrant@basebox-buster64:/builds/fdroid/repomaker$ ./tests/test-units.sh
```


129
130
131
132
## Translation

* GNU gettext `apt install gettext`

133
134
135
136
137
138
139
140
141
142
143
144
145
146
# License

This program is free software: you can redistribute it and/or modify it
under the terms of the [GNU Affero General Public License](/LICENSE)
as published by the Free Software Foundation,
either version 3 of the License,
or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Affero General Public License for more details.


147
# Translating
Nico Alt's avatar
Nico Alt committed
148

149
150
151
152
Everything can be translated.  See
[Translation and Localization](https://f-droid.org/docs/Translation_and_Localization)
for more info.

153
154
* To update translations, run `./update-translations.sh`.
* To add a new translation, run `python3 manage.py makemessages -l <lg>` where `<lg>` is the language code, e.g. `de`.
Nico Alt's avatar
Nico Alt committed
155

156
[![translation status](https://hosted.weblate.org/widgets/f-droid/-/repomaker/multi-auto.svg)](https://hosted.weblate.org/engage/f-droid/?utm_source=widget)