GithubHelp home page GithubHelp logo

nomore201 / playmaker Goto Github PK

View Code? Open in Web Editor NEW
276.0 276.0 35.0 1.91 MB

Fdroid repository manager fetching apps from Play Store

Python 9.37% JavaScript 84.16% HTML 4.91% CSS 0.89% Dockerfile 0.67%
apk download fdroid server

playmaker's People

Contributors

lxp avatar n1zzo avatar nomore201 avatar samuelb avatar yoghi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

playmaker's Issues

Google Login doesn't retry on `UNKNOWN_ERR`

With a credentials.conf file present, playmaker should try and log in using these credentials. However, when the error LoginError: 'server says: UNKNOWN_ERR' is returned, playmaker stops trying to log in.

This error is however also thrown via the regular login interface in the webbrowser, and it can sometimes take up to 10 tries to properly login.

My proposed solution is to have playmaker attempt to login multiple times when an UNKNOWN_ERR is returned by Google. This value could either be hard-coded (say, 10 times), or be configurable in credentials.conf

Can't run on Windows 10

Installed Docker Edge on Windows 10, enabled Linux Containers support, and the run command in the README says:

C:\Program Files\Docker\Docker\Resources\bin\docker.exe: Error response from daemon: invalid volume specification: '/srv/fdroid:/data/fdroid'.
See 'C:\Program Files\Docker\Docker\Resources\bin\docker.exe run --help'.

No Docker on hub

Unable to perform the pull from docker to my server.
There is no Dockerfile on the Docker hub.
Can you upload it?

Thanks

LoginError: 'server says: CaptchaRequired'

I am not able to login any more with my google account. The error message I get is "LoginError: 'server says: CaptchaRequired'".

I have 2FA activated and I am using a newly generated app password, but still no success...

Stop on Updating cache after restart

Container hang on 'Updating cache' after installing com.textra.

To reproduce:

  1. Use a empty repo (it also hang with not empty repo)
  2. Install com.textra
  3. Restart container
  4. Check log no 'Added com.textra to cache' and Apps website show only 'Server is loading apks, please wait some seconds, then refresh'

search() takes 2 positional arguments but 4 were given

Since gpapi 0.4.4 GooglePlayAPI.search() only takes one argument (+self), but it is still called with 3 arguments by playmaker. 0.4.4 is installed by default by playmaker's setup.py

apps = self.service.search(appName, numItems, None)

https://github.com/NoMore201/googleplay-api/blob/fc0cc3a902b90247386331e9aa0ccc47d6ed7847/gpapi/googleplay.py#L349

ERROR:tornado.application:Uncaught exception GET /api/search?search=firefox (10.10.7.2)
HTTPServerRequest(protocol='https', host='playmaker.local', method='GET', uri='/api/search?search=firefox', version='HTTP/1.1', remote_ip='10.10.7.2', headers={...})
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/tornado/web.py", line 1512, in _execute
    result = yield result
  File "/usr/local/lib/python3.8/site-packages/tornado/gen.py", line 1055, in run
    value = future.result()
  File "/usr/local/lib/python3.8/site-packages/tornado/concurrent.py", line 238, in result
    raise_exc_info(self._exc_info)
  File "<string>", line 4, in raise_exc_info
  File "/usr/local/lib/python3.8/site-packages/tornado/gen.py", line 1063, in run
    yielded = self.gen.throw(*exc_info)
  File "/usr/local/lib/python3.8/site-packages/playmaker/server.py", line 76, in get
    apps = yield self.search()
  File "/usr/local/lib/python3.8/site-packages/tornado/gen.py", line 1055, in run
    value = future.result()
  File "/usr/local/lib/python3.8/concurrent/futures/_base.py", line 432, in result
    return self.__get_result()
  File "/usr/local/lib/python3.8/concurrent/futures/_base.py", line 388, in __get_result
    raise self._exception
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.8/site-packages/playmaker/server.py", line 39, in search
    return service.search(keyword)
  File "/usr/local/lib/python3.8/site-packages/playmaker/service.py", line 266, in search
    apps = self.service.search(appName, numItems, None)
TypeError: search() takes 2 positional arguments but 4 were given
ERROR:tornado.access:500 GET /api/search?search=firefox (10.10.7.2) 33.84ms

Docker container exits after pull

I'm running a docker container with the following command
docker run -d --name playmaker \ -p 5000:5000 \ -v /srv/fdroid:/data/fdroid \ -e HTTPS_CERTFILE="/srv/https.crt" \ -e HTTPS_KEYFILE="/srv/https.key" \ -e LANG_LOCALE="en_UK" \ -e LANG_TIMEZONE="Europe/Berlin" \ -e DEVICE_CODE="oneplus3" \ nomore201/playmaker

but after succesfully pulling it isn't running so I try to start it again and docker start playmaker -i gives

error initializing fdroid repository CRITICAL: Android SDK path "/opt/android-sdk-linux" does not contain "platform-tools/"! CRITICAL: Unknown exception found! Traceback (most recent call last): File "/usr/bin/fdroid", line 147, in <module> main() File "/usr/bin/fdroid", line 124, in main mod.main() File "/usr/lib/python3/dist-packages/fdroidserver/init.py", line 125, in main os.mkdir('repo') PermissionError: [Errno 13] Permission denied: 'repo'

Repository Name/URL

Currently by default there are bad values for this, it would be nice if this was configurable with environment variables.

playmaker fetching outdated apk

Hi,

I started playmaker using -e LANG_LOCALE="de_DE" -e LANG_TIMEZONE="Europe/Berlin" options (latest playmaker dev version as of 28th of january).
Next, I logged in using my gmail account and downloaded firefox. The apk has the version 2015526481 inside playmaker, and is listed as 57.0.1 in F-Droid. However, the latest available version of firefox in the german play store is 58.0 (last updated january 23rd).

Is it possible to fix this and actually get the latest version of firefox (and other apps), instead of outdated ones?

Playmaker doesn't update etag; therefore Fdroid thinks no repo update available

Hi,
I had the problem of the fdroid app keeping the same "last updated" date for my playmaker repository (and also not providing new app versions).
I debugged this and found the reason.

These are the headers returned by the playmaker repo when requesting index-v1.jar before updating the repo:

date: Thu, 01 Feb 2018 13:40:32 GMT
server: TornadoServer/4.5.3
strict-transport-security: max-age=31536000
content-type: application/java-archive
accept-ranges: bytes
etag: "4087f73ea76e66962006245fb4aa4ecb"
last-modified: Thu, 01 Feb 2018 12:27:21 GMT
content-length: 5489

Now I updated the repo and got these headers returned:

date: Thu, 01 Feb 2018 13:40:50 GMT
server: TornadoServer/4.5.3
strict-transport-security: max-age=31536000
content-type: application/java-archive
accept-ranges: bytes
etag: "4087f73ea76e66962006245fb4aa4ecb"
last-modified: Thu, 01 Feb 2018 13:40:46 GMT
content-length: 5494

You can clearly see that the last-modified header is updated correctly, but the etag stays the same.

This is a huge issue, as fdroid uses the etag to determine whether a repository needs to be updated or not: https://gitlab.com/fdroid/fdroidclient/blob/master/app/src/main/java/org/fdroid/fdroid/net/HttpDownloader.java#L95

/fdroid returns 404

I set up playmaker locally to give it a try and everything worked fine; now I tried to set it up on a server where I deployed it via dokku, set up https via letsencrypt (the container runs without certificates though because it's proxied by nginx), created an app password etc.

I can login just fine, I can also search for and download apps; I persisted /data/fdroid to /var/lib/dokku/data/storage/playmaker, created the folder but didn't change any permissions. When trying to access the /fdroid url I get an error 404. When I check /var/lib/dokku/data/storage/playmaker the repo directory is empty. Here's an excerpt from the logs:

2018-07-09T09:40:17.325403198Z app[web.1]: Uploading device configuration
2018-07-09T09:40:17.781691078Z app[web.1]: Updating cache
2018-07-09T09:40:17.812961866Z app[web.1]: Cache correctly initialized
2018-07-09T09:40:57.945044371Z app[web.1]: Downloading com.whatsapp
2018-07-09T09:41:00.153335389Z app[web.1]: Adding com.whatsapp into cache..
2018-07-09T09:41:05.844516408Z app[web.1]: Downloading org.leo.android.dict
2018-07-09T09:41:07.302145999Z app[web.1]: Adding org.leo.android.dict into cache..
2018-07-09T09:46:59.639072638Z app[web.1]: Fdroid repo updated successfully
2018-07-09T09:48:28.614540160Z app[web.1]: WARNING:tornado.access:404 HEAD /index-v1.jar (172.17.0.1) 5.46ms
2018-07-09T09:48:28.812171950Z app[web.1]: WARNING:tornado.access:404 HEAD /index.jar?client_version=1.2.2 (172.17.0.1) 1.16ms
2018-07-09T10:00:22.598039836Z app[web.1]: Checking com.whatsapp
2018-07-09T10:00:22.608123931Z app[web.1]: 452400 == 452400 ?
2018-07-09T10:00:22.893802996Z app[web.1]: Checking org.leo.android.dict
2018-07-09T10:00:22.894003695Z app[web.1]: 54 == 54 ?
2018-07-09T10:00:44.793558768Z app[web.1]: Fdroid repo updated successfully
2018-07-09T10:01:04.798792596Z app[web.1]: Downloading com.tinder
2018-07-09T10:01:07.556840926Z app[web.1]: Adding com.tinder into cache..
2018-07-09T10:09:51.894171109Z app[web.1]: WARNING:tornado.access:404 HEAD /index-v1.jar (172.17.0.1) 4.23ms
2018-07-09T10:09:52.116336595Z app[web.1]: WARNING:tornado.access:404 HEAD /index.jar?client_version=1.2.2 (172.17.0.1) 1.20ms
2018-07-09T10:10:23.906804386Z app[web.1]: WARNING:tornado.access:404 HEAD /index-v1.jar (172.17.0.1) 4.36ms
2018-07-09T10:10:24.129604587Z app[web.1]: WARNING:tornado.access:404 HEAD /index.jar?client_version=1.2.2 (172.17.0.1) 1.22ms
2018-07-09T10:29:01.024630392Z app[web.1]: Fdroid repo updated successfully
2018-07-09T10:29:32.723741881Z app[web.1]: WARNING:tornado.access:404 GET /fdroid (172.17.0.1) 1.24ms

As you can see, there's quite a couple of 404s, especially after adding Tinder. The last one is me manually requesting /fdroid. Any idea what went wrong?

error while executing fdroidserver tool

I've been running v0.6.3 from the docker image for about a year now.

In the last few weeks something has changed such that updating fdroid repo via browser only reports that there was an error while executing fdroidserver tool.

Is there a way to run this from the CLI so I can see what errors are being generated?
Thanks.

App runs as root

What happens?

When I run ps -ely inside the container, I get this:

S UID PID PPID C PRI NI RSS SZ WCHAN TTY TIME CMD
S 0 1 0 0 80 0 748 1073 wait ? 00:00:00 sh
S 0 6 1 0 80 0 48940 236308 - ? 00:00:08 python3
S 0 40 0 0 80 0 3648 4989 wait ? 00:00:00 bash
R 0 49 40 0 80 0 1564 7486 - ? 00:00:00 ps

What should've happened?

I shouldn't see python3 running as root

How to reproduce?

Create the app's container as stated in the repo, run docker-compose exec playmeker /bin/bash and inside the console run ps -ely

Some meta?

Not much, I just think running a web server as root is not cool. Also, I don't know why sh is in PID 1, as you seem to be setting the ENTRYPOINT correctly in your dockerfile.

And, also again, I don't know why github is removing the spcaes in the "What happens?" part. I tried to format it as nice as I could.

Where should credentials.conf be placed in the docker container?

Hi, I'm using latest docker image nomore201/playmaker form docker hub. Where should credentials.conf file be placed inside the docker container? I have tried two locations so far:

/opt/playmaker/
/usr/local/lib/python3.6/site-packages/playmaker/

Unfortunately none of these seem to work and Playmaker asks for my google account credentials every time I open https://<playmaker_host>:5000/

Always Get Incorrect Credentials

Trying to login for the first time. I've put a credentials.conf in the /data/fdroid directory with the correct credentials. The Docker log shows LoginError: Server Says 'Unknown_ERR'

Trying to login through the login screen always gives Incorrect Credentials and the same error in the Docker log

I've switched Less Secure Apps to be allowed on my Google Account but still no joy. The username and password are definitely correct.

Am I doing something wrong or is this app now broken?

Ta!

Missing result on search

Searching de.schildbach.oeffi Result: App not listed
Searching oeffi Result: de.schildbach.oeffi is listed but Version = 0

On real device no problem to install. Perhaps wrong device or wrong country ?
Will try it later by api to hunt it down.

How to refresh cache

Hi,
When I put in repo a new apk and run fdroid update -c browser dont show the new apk but when restart docker image it do?
How to clean cache?
Thanks

Login is not persisted

What happens?

When I delete the apps docker container, and create it again, the apps asks for my login credentials.

What should have happened?

The container should persist the login in some form, as logging in again will register a new decive

How to reproduce?

Create a container as instructed in the wiki, go to the home page, login, delete the container, go to the home page, see the login prompt again.

Some meta

The main reason for this bug, is that when inspecting the source, I came across your very own gpapi, which states that:

An important note about login function:

def login(self, email=None, password=None, gsfId=None, authSubToken=None)

for first time logins, you should only provide email and password. The module will take care of initalizing the api,upload device information to the google account you supplied, and retrieving a Google Service Framework ID (which, from now on, will be the android ID of a device).

And, as far as I could see, the login in the app is done passing None as both gsfId and authSubToken, as is seen in this line

So, I'm hesitating about logging in again like this. Would you accept any pull requests to save those values somehow? Or maybe if they are sensitive, could you implement a way to view them in the web app so I can save them appropriately, and provide them somehow in the login? And sorry for asking for a feature in that second part, but I just don't know any javascript :/

Can't download new apps

When I try to download an app, which I have never downloaded, I get an error message saying like:
"com.instagram.android can't be downloaded"
However, I can redownload apps which I have removed but i cant get any new.

Here are the logs:
Downloading com.instagram.android
'App not purchased'
Failed to download com.instagram.android

I think problems started when i tried to install com.mapswithme.maps.pro

Support adaptive-icons

When viewing an app with an adaptive icon, fdroid tries to read /fdroid/icons-480/com.Slack.20009410.png.

But this is not a png, but rather an binary xml file.

$ cat com.Slack.20009410.png && echo "\n"
��4
adaptive-iconandroid

background

foreground**http://schemas.android.com/apk/res/android�
▒��������▒��������▒����\n                             �▒����$��������8������������
$ cat com.Slack.20009410.png| base64
AwAIAMABAAABABwAoAAAAAYAAAAAAAAAAAEAADQAAAAAAAAAAAAAAAsAAAAbAAAAJQAAADIAAAA/
AAAACAhkcmF3YWJsZQANDWFkYXB0aXZlLWljb24ABwdhbmRyb2lkAAoKYmFja2dyb3VuZAAKCmZv
cmVncm91bmQAKipodHRwOi8vc2NoZW1hcy5hbmRyb2lkLmNvbS9hcGsvcmVzL2FuZHJvaWQAgAEI
AAwAAACZAQEBAAEQABgAAAACAAAA/////wIAAAAFAAAAAgEQACQAAAACAAAA//////////8BAAAA
FAAUAAAAAAAAAAAAAgEQADgAAAADAAAA//////////8DAAAAFAAUAAEAAAAAAAAABQAAAAAAAAD/
////CAAAAQAADX8DARAAGAAAAAMAAAD//////////wMAAAACARAAOAAAAAQAAAD//////////wQA
AAAUABQAAQAAAAAAAAAFAAAAAAAAAP////8IAAABAgANfwMBEAAYAAAABAAAAP//////////BAAA
AAMBEAAYAAAAAgAAAP//////////AQAAAAEBEAAYAAAAAgAAAP////8CAAAABQAAAA==

Select other device properties?

I´d like to fetch app´s that are build especially for arm64 and my mali gpu...

Is it possible to select other device properties from a config file?

I only know that the googleplay-api uses as default a oneplus one (bacon) and i cant´t find the function in which i could define another device from within playmaker.

It would be great if we can define the device properties with an environment variable or i a config file...

Thanks in advance.

Incompatible apps

Some of the apps served from the repository are marked as incompatible and I can't install them. They should be able to install, they were when I was still using the play store directly. I suspect the issue is that my device isn't in listen in the device properties file so I couldn't use the correct device code (gohan, a bq aquaris X5 plus) and the wrong apks get put in grabbed from the play store.

I don't mind extracting these device properties myself but before I spend half a day figuring out how to do this I was hoping someone has some hints or a script that lets me do this more easily.

Docker: playmaker has to be initialised after every recreation

I use the docker image to host playmaker and every time i recreate the container (for example to use a newer image) playmaker has to be initialized again.
I looked in your docker file and it seems, this is because you copied playmaker.conf in buildphase so that it would be overmounted when the container is started.

possible fix: write the file /data/fdroid/playmaker.conf during startup/initialization phase of the server

Accept some setting to run in a path

What happens?

When running behind a proxy, (in my case, Apache adding SSL to the connection) the app doesn't honor the X suite of headers, and also doens't have any settings so one can run it in /playmaker for example.

What should happen?

The app could have the xheaders argument set to True when calling tornado.httpserver.HTTPServer and some way, maybe an env var, to set the app to "tune" the urls to other dict.

How to reproduce?

Basically, try to access the app behind any proxy using a path different from /. For example, this apache ProxyPass settings stops the app from loading any static files.

<Location "/playmaker">
ProxyPass "http://127.0.0.1:5000"
ProxyPassReverse "http://127.0.0.1:5000"
Require ip 192.168.1.0/24

Some meta

I have transmission, nextcloud, and other apps running in the same host, and it just feels wrong to have this in "/" when I could have it properly configured in it's onw path. Also, most of those services I use have by default a leading path, so maybe this app can have it as well? Would you accept a pull request for that or some other way (as an env var) to set that path? Or maybe both, a default that's used if no env is provided?

The thing I again just can help is the JS part, as I don't know any of that. But I guess if the path is hard-coded it shouldn't be too difficult to add.

Wrong Credentials

I feel silly having to make an issue for this. But I cannot for the life of me determine the cause.
I've tried different accounts, brand new ones, yet whatever I try, it says Wrong Credentials.

I've run the application via the docker method using the non https method.
None of the accounts testing with have 2FA.

Let me know if you need any additional information.
The url is also publicly accessible if you wish to try it yourself.

Fdroid repository initialization

First of all thank you for this awesome project, I used gplayweb in the past but it stopped working at some point and I manually fetched and installed the apk files of the various applications since then. This project is the perfect fit for my current Android setup.

I deployed playmaker on a server taking advantage of the pre-built image on dockerhub and all worked well out of the box, so I proceeded to replicate the same setup that I had with gplayweb in the previous installation.
In particular I use nginx to serve the fdroid repository in order to reach it for example from the fdroid client on my phone.

For doing this I use a combination of two containers, that I deploy with docker-compose, with the following configuration:

docker-compose.yml
andrea@kimsufi:~/docker/playmaker-hub$ cat docker-compose.yml 
version: '3'
services:
  playmaker:
    image: nomore201/playmaker
    restart: always
    expose:
      - "5000"
    volumes:
      - /home/docker/playmaker:/data/fdroid
    environment:
     ...
    network_mode: "bridge"    


  fdroid-nginx:
    image: nginx      
    restart: always
    expose:
      - "80"
    volumes:
      - /home/docker/playmaker/repo:/usr/share/nginx/html:ro
    environment:
      ...
    network_mode: "bridge"

For readability reasons I omitted some parts that are not significant for this discussion (the environment variables used for instructing the nginx-proxy container on which third-level domain expose the container).

With this setup I incurred in a problem: since we instruct the fdroid-nginx container to mount the /home/docker/playmaker/repo folder in a location that will be served by nginx, the docker daemon takes care of creating the folder in case it doesn't exists.
In this way the playmaker container when executing the startup routine doesn't initialize the fdroid repository since the repo folder is already present.
The check is done in the following place:

elif os.path.isdir('./repo'):

This causes the fdroid repository not being initialized even at the first startup.

Obviously this is not a problem of playmaker itself, in fact if we create as first thing the playmaker container and only after start the nginx container that expose the repository, all works correctly. Anyway I decided to report this since I think that the majority of the users could do a setup similar to the one I showed, incurring in the problem (I know for sure that @n1zzo uses a similar setup).

Maybe it would be nice to mention the fact that the initialization of the repository is not executed if the 'repo' folder is present, or check for multiple signs that the initialization has occurred (presence of the config.py or keystore.jks files in addition to the repo folder for example), or even use an helper function of fdroid to check this (I'm speculating here, I will check for this in the fdroid documentation).

Let me know which solution you find more appropriate, and I will gladly make a PR for that.

Playmaker as GitLab Pages

Hi, I was wondering if, Playmaker could be run within a GitLab Pages as a private project? Pages is based on Docker, so in theory it could work. Or not. I'm not an expert, but I would definitely love to have a Playmaker in such a way.
Something like inyourfacegoogle.gitlab.io/repo.

Running docker container on RPI3

If I run the command listed in the readme on RPI3 (after creating https files and adjusting locale), all I get is an empty /srv/fdroid folder and nothing coming up if I go to the pi's ip :5000 or /fdroid or :5000/fdroid , both with https and http prefix, nothing.

The pi is headless on the network so I have no way to check if somehow it is successfully running locally, but I doubt it as if I run docker port playmaker it lists no entries and as I say, the /srv/fdroid folder is empty and I can't seem to find any other playmaker files on there.

Any idea what might be going on or how I could troubleshoot this issue, look at logs or something?

Playmakers search function does not work correct.

If you search on googles website https://play.google.com/store/apps for the app "simple notes pro" or the German name "schlichte notizen pro" you find as first match this app: https://play.google.com/store/apps/details?id=com.simplemobiletools.notes.pro. This is right.

If you search the same in playmakers search function you get 15 search results and no matches for „com.simplemobiletools.notes.pro“. You are unable to import this app!

As a workaround it would be great if you could search directly for Ids.

use standard fdroid repo dir layout

This is great work! I have one small request that'll make this integrate better into the F-Droid ecosystem: please use the standard directory layout. It seems right now this puts the repo straight into fdroid/. Instead it should look like:

-fdroid
       |-config.py
       \-repo
             |-index.xml
             |-my.package_123.apk

Docker install not accessible from f-droid client.

I've installed the docker image and am running the following config:

docker run -d --name playmaker
-p 5000:5000
-v /srv/fdroid:/data/fdroid
-v /etc/letsencrypt/live/playmaker.example.com/cert.pem:/srv/cert.pem
-v /etc/letsencrypt/live/playmaker.example.com/privkey.pem:/srv/privkey.pem
-e HTTPS_CERTFILE="/srv/cert.pem"
-e HTTPS_KEYFILE="/srv/privkey.pem"
-e LANG_LOCALE="en_GB"
-e LANG_TIMEZONE="Europe/London"
nomore201/playmaker

I can access https://playmaker.example.com:5000/#!/ and have downloaded a dozen apps from the play store.

Updating the fdroid repo looks to be working OK in that I can see the apps and index files being updated.

The issue I'm seeing is that when I add the repo (URL https://playmaker.example.com:5000/fdroid) to an f-droid client it is being reported as unsigned (I thought unsigned repo's are no longer supported). And when doing a repo update the client reports error getting index file for the repo.

Does someone know what needs to be done to resolve these issues?

Thanks

L

Use logging module

I'll drop the standard bug report format because this is easy:

Instead of if debug then log, using the logging module would be more elegant.

The basic idea is that a different dict config could be loaded just once if debug is set, and logging would just discard any logs that are not at least the minimum level.

ValueError: certfile "/srv/playmaker.crt" does not exist

Generated crt and key file with:

sudo openssl req
-newkey rsa:2048 -nodes -keyout /srv/playmaker.key
-x509 -days 3650 -out /srv/playmaker.crt

Files were created at specified location and are not empty. Docker logs playmaker show:

ValueError: certfile "/srv/playmaker.crt" does not exist

When I do docker run without

-e HTTPS_CERTFILE="/srv/playmaker.crt" \
-e HTTPS_KEYFILE="/srv/playmaker.key" \

Everything works and I can access playmaker at http://localhost:5000/#!/login

Trying to deploy on RPI3

I'm trying to deploy playmaker on my rpi3 and the fdroid server can't initialize ("Error while executing fdroidserver tool"). Where can I find the log to search the problem?

permission issue

see also #42 (comment)

Since f3828fd the container doesn't start anymore.

After deleting the container and /srv/fdroid on every start I only get the following error:

➜  ~ docker logs playmaker
error initializing fdroid repository CRITICAL: Android SDK path "/opt/android-sdk-linux" does not contain "platform-tools/"!
CRITICAL: Unknown exception found!
Traceback (most recent call last):
  File "/usr/bin/fdroid", line 147, in <module>
    main()
  File "/usr/bin/fdroid", line 124, in main
    mod.main()
  File "/usr/lib/python3/dist-packages/fdroidserver/init.py", line 125, in main
    os.mkdir('repo')
PermissionError: [Errno 13] Permission denied: 'repo'

I think this has something to do that /srv/fdroid (outside of the container) is only readable by root,
and I think this line only runs on container creation and not when starting the container.

RUN chown -R pmuser:pmuser /data/fdroid && \

But I know too little about how docker works correctly to suggest a solution.

unstoppable relogin on search

searching for 'phongit.quickreboot' produce unstoppable relogins.

Session tokens expired, re-login needed
Master token: ....
authSubToken: ...
Session tokens expired, re-login needed

after ~10 relogin:

Session tokens expired, re-login needed
Wrong credentials: 'server says: ServerError'

and after some more relogin a captcha request.

feature: counter to limit relogin per time or stop after wrong credentials ?

Possible to make a public instance?

Would it be possible to host a a public server with Playmaker, where users can pick which apps should be provided? Apparently now only the admin can add new apps, and also trigger updates or remove apps.

But if we could allow unregistered users to add apps (but not delete them), Playmaker could serve as a general purpose repo for all apps on Google Play. It would be a nice alternative to Yalp Store.

Docker exits

I launch the Docker and it exits after a couple min with the following in the log.
Started I a server reboot.

Traceback (most recent call last):
File "/usr/local/lib/python3.7/concurrent/futures/process.py", line 232, in _process_worker
r = call_item.fn(*call_item.args, **call_item.kwargs)
File "/usr/local/lib/python3.7/site-packages/playmaker/service.py", line 35, in get_details_from_apk
details['versionCode'] = int(a.version_code)
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/local/bin/pm-server", line 60, in <module>
service.update_state()
File "/usr/local/lib/python3.7/site-packages/playmaker/service.py", line 215, in update_state
app = future.result()
File "/usr/local/lib/python3.7/concurrent/futures/_base.py", line 425, in result
return self.__get_result()
File "/usr/local/lib/python3.7/concurrent/futures/_base.py", line 384, in __get_result
raise self._exception
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'

Feature List

I'll leave here a list of features and enhancements to implement in playmaker, so it can be tracked and discussed easily in one place. Feel free to suggest or implement something!

Features

  • Update application button should automatically update app without user intervention (done in c1d5289)
  • Edit metadata for apps
  • Populate fdroid metadata subdir with information fetched from play store
  • Auto update applications and fdroid server
  • In login page, user should select device to fake
  • Add an endpoint to serve fdroid repo directly from playmaker (like https://<your_playmaker_url/fdroid) (done in 57686a1)

Enhancements

  • Improve search view
  • Better apk parsing algorithm during startup (done in 1273226)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.