Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

errorCode: INVALID_VERSION when trying to accept the GitHub bot invitation #458

Open
choque88 opened this issue Apr 22, 2023 · 3 comments
Open

Comments

@choque88
Copy link

choque88 commented Apr 22, 2023

So I'm running the latest release of staticman via docker-compose and provided the env variables GITHUB_TOKEN and RSA_PRIVATE_KEY.

Now when I try to accept the invitation under https://<MY_STATICMAN_URL>/v3/connect/<MY_GITHUB_USER>/<MY_GITHUB_PAGES_REPO> like it's written here in step 3, I get the following response:

{
    "success": false,
    "errorCode": "INVALID_VERSION"
}

Any help is appreciated.

Here's the docker-compose.yml I'm using (GITHUB_TOKEN and RSA_PRIVATE_KEY are dummy values)

version: "3"
services:
  staticman:
    build: .
    restart: unless-stopped
    environment:
      PUID: 1000
      GUID: 1000
      TZ: Europe/Berlin
      NODE_ENV: production
      PORT: 3000
      GITHUB_TOKEN: ghp_AuVcXAwAu12ILH3fz5Ls1kyHkCXDQo9e1LW5
      RSA_PRIVATE_KEY: |
        -----BEGIN RSA PRIVATE KEY-----
        MIIJJwIBAAKCAgEAuO1MIkNiXOXrvYP3vj4G0Tb8+jH64nJFaEZxmf3hxfgjXpe3
        SdGKx8RVnnyuBqcUQaBMX2CWcAZb4KPNi7Xz4nBKXRybLohnno5V8cPjV/tM/oTb
        pxaXNvqC8ksGVtwg8QtmdVjg3bJWHYcyc2EpIBLUZULy7i9mXDogrMaENoPQWGUN
        QDK5AoIBAGJkof+y6ZM10vOhIGZzFCwV/xIUxADXd+KdgNv+Kxd3jh4oAsKHVchO
        rsufVXj83wP72Vlsj/e75WturFPmjSa4yhZdJVJW9fanFVY6w0xyTZsayajJEKo3
        mvCB6P0B/QzCBHfDrGmKn8KfRYF+Ny1IGqG+4wkbs/8Ab5Mg/wqbyv+xf4wif8dK
        ZaoDzh0PRXRptbg8kqNzhvlFJJg6q5NDCpRQEDpVcmu+d0q1yea3tCLkQ33bV7dL
        TFpcMCw+2vLnWe5ox8ljiq63f6KnWybWilPO46/5zsqXcxQUIInKCuCp6w3kKpdK
        AOn8odbmrH9L3/e3tBAFF+FUeztIQRkCggEAViUf4+NGbvnuMl73kEelt5WrxODT
        jH5Vp95wME11z879S1ngCZSpTxvqvgkcZ9ZwHNqf0j/udmEF6wXkyQ4QzEbKKpZI
        8c982+Sbc49NRuM+XngKaKW81vwPreE3NOGF9uXfPXRX8Ox1LanTkZIUA0lBegWG
        WZ+Z5ubJjLpkY4uaBisZD/+erE3oSILGUAh4Y3s+CAiLPRxlcIyIK7a+f6vFmutI
        wWMJxeozVo0jJPQgAbg9wcHWxnzq0IWD0Gprzfbg24EDYa6XQzC+CuPwREueQMMr
        s8pBBul5h9uiBk9M/7woLj54VSEU0d0/2Y+i9FWa3OGlFHCBcpTwp03XRg==
        -----END RSA PRIVATE KEY-----
    networks:
      - proxy
    volumes:
      - /etc/localtime:/etc/localtime:ro
    labels:
      - com.centurylinklabs.watchtower.enable=false
      - traefik.enable=true
      - traefik.http.routers.staticman-secure.entrypoints=websecure
      - traefik.http.routers.staticman-secure.rule=Host(`mystaticmandomain.com`)
      - traefik.http.routers.staticman-secure.middlewares=default@file
      - traefik.http.routers.staticman-secure.service=staticman
      - traefik.http.services.staticman.loadbalancer.server.port=3000

networks:
  proxy:
    external: true
@hoangmnsd
Copy link

I am getting the same problem? Did you find the cause?

@choque88
Copy link
Author

Sadly no. And I stopped trying to implement it since the project is apparently dead. Right now I'm looking at Mastodon powered comments or Github issues powered comments

@panchtatvam
Copy link

The POST url should be of the form

'/v:version/entry/:service/:username/:repository/:branch/:property',

for version 3 to be active. You need to add the property at the end. This is the key used in staticman.yml file in your repo. Like in the sample staticman.yml file the property is comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants