Possible to have both internal ip url and external url access? #3681
Closed
ajohnson30
started this conversation in
General
Replies: 1 comment 2 replies
-
|
Sorry for the delayed response, I have been very focused on cooking some new functionalities + other stuff happening in life... Are you serving your install via Docker compose ? services:
lychee_db:
container_name: lychee_db
image: mariadb:10
security_opt:
- no-new-privileges:true
env_file:
- path: ./.env
required: false
environment:
- MYSQL_ROOT_PASSWORD=${DB_ROOT_PASSWORD:-rootpassword}
- MYSQL_DATABASE=${DB_DATABASE:-lychee}
- MYSQL_USER=${DB_USERNAME:-lychee}
- MYSQL_PASSWORD=${DB_PASSWORD}
expose:
- 3306
volumes:
- mysql:/var/lib/mysql
networks:
- lychee
restart: unless-stopped
lychee:
image: lycheeorg/lychee
container_name: lychee
security_opt:
- no-new-privileges:true
ports:
- 91:80
volumes:
- ./lychee/conf:/conf
- ./lychee/uploads:/uploads
- ./lychee/sym:/sym
- ./lychee/logs:/logs
- ./lychee/tmp:/lychee-tmp
networks:
- lychee
environment:
- PUID=${PUID:-1000}
- PGID=${PGID:-1000}
# PHP timezone e.g. PHP_TZ=America/New_York
- PHP_TZ=${TIMEZONE:-UTC}
- TIMEZONE=${TIMEZONE:-UTC}
- APP_URL=https://example.com
- DB_CONNECTION=mysql
- DB_HOST=lychee_db
- DB_PORT=${DB_PORT:-3306}
- DB_DATABASE=${DB_DATABASE:-lychee}
- DB_USERNAME=${DB_USERNAME:-lychee}
- DB_PASSWORD=${DB_PASSWORD}
- TRUSTED_PROXIES=*
- SKIP_PERMISSIONS_CHECKS=${SKIP_PERMISSIONS_CHECKS:-false}
- STARTUP_DELAY=5
restart: unless-stopped
depends_on:
- lychee_db
lychee-local:
image: lycheeorg/lychee
container_name: lychee
security_opt:
- no-new-privileges:true
ports:
- 90:80
volumes:
- ./lychee/conf-local:/conf
- ./lychee/uploads:/uploads
- ./lychee/sym:/sym
- ./lychee/logs:/logs
- ./lychee/tmp:/lychee-tmp
networks:
- lychee
environment:
- PUID=${PUID:-1000}
- PGID=${PGID:-1000}
# PHP timezone e.g. PHP_TZ=America/New_York
- PHP_TZ=${TIMEZONE:-UTC}
- TIMEZONE=${TIMEZONE:-UTC}
- APP_URL=https://10.22.22.123:90
- DB_CONNECTION=mysql
- DB_HOST=lychee_db
- DB_PORT=${DB_PORT:-3306}
- DB_DATABASE=${DB_DATABASE:-lychee}
- DB_USERNAME=${DB_USERNAME:-lychee}
- DB_PASSWORD=${DB_PASSWORD}
- TRUSTED_PROXIES=*
- SKIP_PERMISSIONS_CHECKS=${SKIP_PERMISSIONS_CHECKS:-false}
- STARTUP_DELAY=5
restart: unless-stopped
depends_on:
- lychee_db
networks:
lychee:
volumes:
mysql:
name: lychee_prod_mysql
driver: localNotice the difference of enviroment for APP_URL and that |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
So I think this worked in V4, and since I now upgraded to the current V6.9.x it does not. My current work-around is to have copies of the .env file with APP_URL, ASSET_URL, etc, set properly to allow for:
copy for internal use - entries: (these ip are fake)
APP_URL=http://10.22.22.123:90
APP_FORCE_HTTPS=false
#APP_DIR=
#ASSET_URL=
note: I have an entry that sets "ASSET_URL=http://10.22.22.123:90" - seems to work either way
copy for external use - entries:(again, fake)
APP_URL=https://www.dynamichost.com/photos
APP_FORCE_HTTPS=false
APP_DIR=photos
ASSET_URL=https://www.dynamichost.com/photos
The external site is accessed via a "primary" web site at https://www.dynamichost.com, that is behind nginx, so when the subdomain https://www.dynamichost.com/photos is accessed, it forwards to the lychee server. I would like to be able to access the lychee server directly/internally from http://10.22.22.123:90 during file uploads/administration so it's not bouncing through my internet connection/router.
I dont administer it that often (I go on vacation once or twice a year and upload those pics for family use only, thats about it) but that's what I'm shooting for.
Thanks for your time and patience.
Beta Was this translation helpful? Give feedback.
All reactions