InvoiceShelf / docker

InvoiceShelf Docker Image public repository
https://hub.docker.com/r/invoiceshelf/invoiceshelf
17 stars 5 forks source link

Installation problem: Domain verification failed. Please enter valid domain name. #21

Closed usersina closed 1 month ago

usersina commented 1 month ago

I want to install InvoiceShelf using the docker method. I want to have it running on http://localhost:8888.

However, I have this error:

image

Here's more information about the request that failed:

Request Headers ``` GET /api/v1/auth/check HTTP/1.1 Accept: */* Accept-Encoding: gzip, deflate, br, zstd Accept-Language: en-US,en;q=0.9,fr-FR;q=0.8,fr;q=0.7 Connection: keep-alive Cookie: BBLANG=en_US; XSRF-TOKEN=eyJpdiI6IkZaejZnd3c4Z0JSM05KMVBqWndQWHc9PSIsInZhbHVlIjoiTjhHdVliYVBLSFJydHVteTd0cWtQWUlqMmUvSityU1ZudENwYVZBMUFMdS92U3NoMkZMRkwvbUNXSkhNaG1NaW1ScHRlZVN2MFJjemJuRlNSRExKQXRNeWpmcWV2d0lLTS83NzdKbUpJTWRaTU5KREV4bWxQMHZpY0RaN3F0SkUiLCJtYWMiOiJmZjNjNDM5MDM5ZGE2ZmE4N2IxY2E3YzM3YTg3ZjkxMDA4NWU4ZTMwMTlmNjdmMWVjYTRmNWZhMmZmMjM5NzI5IiwidGFnIjoiIn0%3D; laravel_session=eyJpdiI6InQ4ZFVTL01ObzRqRXpIOWl5enV0SVE9PSIsInZhbHVlIjoiZmVBaU1WWXR0U2lTaWQxRkI4bm5LeklZYnlOQ2pqTGpOR0xOZkZWYzFhTFhDWjRGdU5DaitYTUx0K1ZHMk1kRzMvczJoT1F6NGk3anlRbk0zK3FyQ2tYdmpjSEJod3d4VXQvOWZOMDJtNldoMWRBMW04R2lmMU1najJiYVFXY1YiLCJtYWMiOiIxZTQ5ZDI2Njg4ZDgwMDVlM2YzMWYzNmIxZmRlMDhlMmYwMzk1MDBhYzg4YTU0OGFiMGI4MDc3NDFiOGY2MWFiIiwidGFnIjoiIn0%3D Host: localhost:8888 Referer: https://rdbzn5g96jx.typeform.com/to/ Sec-Fetch-Dest: empty Sec-Fetch-Mode: cors Sec-Fetch-Site: same-origin User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 X-Requested-With: XMLHttpRequest X-XSRF-TOKEN: eyJpdiI6IkZaejZnd3c4Z0JSM05KMVBqWndQWHc9PSIsInZhbHVlIjoiTjhHdVliYVBLSFJydHVteTd0cWtQWUlqMmUvSityU1ZudENwYVZBMUFMdS92U3NoMkZMRkwvbUNXSkhNaG1NaW1ScHRlZVN2MFJjemJuRlNSRExKQXRNeWpmcWV2d0lLTS83NzdKbUpJTWRaTU5KREV4bWxQMHZpY0RaN3F0SkUiLCJtYWMiOiJmZjNjNDM5MDM5ZGE2ZmE4N2IxY2E3YzM3YTg3ZjkxMDA4NWU4ZTMwMTlmNjdmMWVjYTRmNWZhMmZmMjM5NzI5IiwidGFnIjoiIn0= company: 1 sec-ch-ua: "Google Chrome";v="129", "Not=A?Brand";v="8", "Chromium";v="129" sec-ch-ua-mobile: ?0 sec-ch-ua-platform: "Linux" ```
Response Headers + Body ``` HTTP/1.1 401 Unauthorized Server: nginx/1.22.1 Content-Type: application/json Transfer-Encoding: chunked Connection: keep-alive Cache-Control: no-cache, private Date: Sat, 28 Sep 2024 09:33:19 GMT X-RateLimit-Limit: 180 X-RateLimit-Remaining: 178 Access-Control-Allow-Origin: * ``` ``` {"message":"Unauthenticated."} ```

Here's my compose file:

services:
  invoiceshelf_db:
    container_name: invoiceshelf_db
    image: postgres:15
    ports:
      - 5432:5432
    volumes:
      - postgres:/var/lib/postgresql/data
    environment:
      - POSTGRES_PASSWORD=somepass
      - POSTGRES_USER=invoiceshelf
      - POSTGRES_DB=invoiceshelf
    networks:
      - invoiceshelf
    restart: unless-stopped

  invoiceshelf:
    image: invoiceshelf/invoiceshelf:2.0.0
    container_name: invoiceshelf
    ports:
      - 8888:80
    volumes:
      - invoiceshelf_data:/data
      - invoiceshelf_conf:/conf
    networks:
      - invoiceshelf
    environment:
      - PHP_TZ=UTC
      - TIMEZONE=UTC
      - APP_NAME=Laravel
      - APP_ENV=local
      - APP_DEBUG=true
      - APP_URL=http://localhost:8888
      - DB_CONNECTION=pgsql
      - DB_HOST=invoiceshelf_db
      - DB_PORT=5432
      - DB_DATABASE=invoiceshelf
      - DB_USERNAME=invoiceshelf
      - DB_PASSWORD=somepass
      - CACHE_STORE=file
      - SESSION_DRIVER=file
      - SESSION_LIFETIME=120
      - SESSION_ENCRYPT=false
      - SESSION_PATH=/
      - SESSION_DOMAIN=localhost:8888
      - SANCTUM_STATEFUL_DOMAINS=localhost:8888
      - STARTUP_DELAY=
      #- MAIL_DRIVER=smtp
      #- MAIL_HOST=smtp.mailtrap.io
      #- MAIL_PORT=2525
      #- MAIL_USERNAME=null
      #- MAIL_PASSWORD=null
      #- MAIL_PASSWORD_FILE=<filename>
      #- MAIL_ENCRYPTION=null
    restart: unless-stopped
    depends_on:
      - invoiceshelf_db

networks:
  invoiceshelf:
    driver: bridge

volumes:
  postgres:
    driver: local

  invoiceshelf_data:
    driver: local

  invoiceshelf_conf:
    driver: local
nodlek-ctrl commented 1 month ago

same error here with a manual install.

approde commented 1 month ago

I have the same Error with the manuell install @rihards-simanovics

nodlek-ctrl commented 1 month ago

Mine was solved by clearing cookies, i believe they may have been held from a previous install or something odd like that.

On Thu, Oct 10, 2024, 10:42 PM App Developer @.***> wrote:

I have the same Error @rihards-simanovics https://github.com/rihards-simanovics

— Reply to this email directly, view it on GitHub https://github.com/InvoiceShelf/docker/issues/21#issuecomment-2404985304, or unsubscribe https://github.com/notifications/unsubscribe-auth/AXCUYGHLVKPQHWFJCTGU7ELZ2ZY4LAVCNFSM6AAAAABPAPEOK2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBUHE4DKMZQGQ . You are receiving this because you commented.Message ID: @.***>

approde commented 1 month ago

Mine was solved by clearing cookies, i believe they may have been held from a previous install or something odd like that.

@nodlek-ctrl How do I do that?

rihards-simanovics commented 1 month ago

Hey thanks @approde I'm just a tad busy this week due to lectures in Uni but will have a look on Weekends.

mchev commented 1 month ago

Mine was solved by clearing cookies, i believe they may have been held from a previous install or something odd like that.

@nodlek-ctrl How do I do that?

From google :

rihards-simanovics commented 1 month ago

@nodlek-ctrl, @approde that sounds correct, if the app was accessed using this URL before, and then re-installed the browser would have collected old cookies and other site data which messes with security.

To remove those, in chromium you need to open the inspect element and Application tab click on clear site data. Here is an example from github.com but this will be the same on other sites

image

or alternatively just use the Incognito/InPrivate mode for the installation and then return to normal mode. Though you may still need to clear cookies as then you'll get CSRF token mismatch.

rihards-simanovics commented 1 month ago

Mine was solved by clearing cookies, i believe they may have been held from a previous install or something odd like that.

@nodlek-ctrl How do I do that?

From google :

  • Chrome: Select Menu > Settings > Site Settings > Cookies and site data > See All Cookies and Site Data. Find the site and click trash.
  • Firefox: Go to the site for which you want to clear cookies, click the padlock next to the URL, and select Clear Cookies and Site Data.
  • Safari: Go to Safari > Preferences > Privacy > Manage Website Data. Choose the website and select Remove.

hey @mchev thanks, yes this is another more user-friendly way to do it.

approde commented 1 month ago

Thanks, I solved the Problem :)

rihards-simanovics commented 1 month ago

closing as solved.