Docker: Panel doesn't start with spaces/special chars in variable values in .env #528

Closed
opened 2026-02-05 17:44:05 +03:00 by OVERLORD · 6 comments
Owner

Originally created by @InterXellar on GitHub (Dec 23, 2025).

Originally assigned to: @parkervcp on GitHub.

Current Behavior

When having a space or special character in a variable name (example APP_NAME or MAIL_FROM_NAME) in the .env file the docker container of panel doesn't start anymore, due to the way how the environment variables are loaded in the entrypoint.sh script.

Expected Behavior

The panel should start normally.

Steps to Reproduce

Have a space in an environment variable (for example APP_NAME) and start the panel, the panel will not start.

Panel Version

v1.0.0-beta30

Wings Version

nA

Games and/or Eggs Affected

No response

Docker Image

No response

Error Logs

/entrypoint.sh: export: line 6: -: bad variable name
external vars exist.

Is there an existing issue for this?

  • I have searched the existing issues before opening this issue.
  • I have provided all relevant details, including the specific game and Docker images I am using if this issue is related to running a server.
  • I have checked in the Discord server and believe this is a bug with the software, and not a configuration issue with my specific system.
Originally created by @InterXellar on GitHub (Dec 23, 2025). Originally assigned to: @parkervcp on GitHub. ### Current Behavior When having a space or special character in a variable name (example APP_NAME or MAIL_FROM_NAME) in the .env file the docker container of panel doesn't start anymore, due to the way how the environment variables are loaded in the entrypoint.sh script. ### Expected Behavior The panel should start normally. ### Steps to Reproduce Have a space in an environment variable (for example APP_NAME) and start the panel, the panel will not start. ### Panel Version v1.0.0-beta30 ### Wings Version nA ### Games and/or Eggs Affected _No response_ ### Docker Image _No response_ ### Error Logs ```bash /entrypoint.sh: export: line 6: -: bad variable name external vars exist. ``` ### Is there an existing issue for this? - [x] I have searched the existing issues before opening this issue. - [x] I have provided all relevant details, including the specific game and Docker images I am using if this issue is related to running a server. - [x] I have checked in the Discord server and believe this is a bug with the software, and not a configuration issue with my specific system.
Author
Owner

@coderabbitai[bot] commented on GitHub (Dec 23, 2025):

📝 CodeRabbit Plan Mode

Generate an implementation plan and prompts that you can use with your favorite coding agent.

  • Create Plan
Examples

🔗 Similar Issues

Possible Duplicates

Related Issues

👤 Suggested Assignees

🧪 Issue enrichment is currently in open beta.

You can configure auto-planning by selecting labels in the issue_enrichment configuration.

To disable automatic issue enrichment, add the following to your .coderabbit.yaml:

issue_enrichment:
  auto_enrich:
    enabled: false

💬 Have feedback or questions? Drop into our discord or schedule a call!

@coderabbitai[bot] commented on GitHub (Dec 23, 2025): <!-- This is an auto-generated issue plan by CodeRabbit --> ### 📝 CodeRabbit Plan Mode Generate an implementation plan and prompts that you can use with your favorite coding agent. - [ ] <!-- {"checkboxId": "8d4f2b9c-3e1a-4f7c-a9b2-d5e8f1c4a7b9"} --> Create Plan <details> <summary>Examples</summary> - [Example 1](https://github.com/coderabbitai/git-worktree-runner/issues/29#issuecomment-3589134556) - [Example 2](https://github.com/coderabbitai/git-worktree-runner/issues/12#issuecomment-3606665167) </details> --- <details> <summary><b>🔗 Similar Issues</b></summary> **Possible Duplicates** - https://github.com/pelican-dev/panel/issues/1561 **Related Issues** - https://github.com/pelican-dev/panel/issues/1903 - https://github.com/pelican-dev/panel/issues/1260 - https://github.com/pelican-dev/panel/issues/1622 </details> <details> <summary><b>👤 Suggested Assignees</b></summary> - [die-gute-snefi](https://github.com/die-gute-snefi) - [DTheIcyDragon](https://github.com/DTheIcyDragon) - [sebygreen](https://github.com/sebygreen) - [alwism](https://github.com/alwism) </details> --- <details> <summary> 🧪 Issue enrichment is currently in open beta.</summary> You can configure auto-planning by selecting labels in the issue_enrichment configuration. To disable automatic issue enrichment, add the following to your `.coderabbit.yaml`: ```yaml issue_enrichment: auto_enrich: enabled: false ``` </details> 💬 Have feedback or questions? Drop into our [discord](https://discord.gg/coderabbit) or [schedule a call](https://calendly.com/parth-coderabbit/issues-feedback)!
Author
Owner

@notAreYouScared commented on GitHub (Dec 23, 2025):

I think your env has a bad variable.... APP_URL is correct along with all the others with _

@notAreYouScared commented on GitHub (Dec 23, 2025): I think your env has a bad variable.... APP_URL is correct along with all the others with _
Author
Owner

@InterXellar commented on GitHub (Dec 23, 2025):

I had spaces in APP_NAME and a "-" in MAIL_FROM_NAME, removing any special characters fixed it for me... but anything after a space in a variable gets cut, for example APP_NAME="Pelican Panel" turns into just Pelican
the export $(grep -v '^#' .env | xargs) dislikes any special characters.
I changed it to . /var/www/html/.env which fixed it not accepting any special characters

@InterXellar commented on GitHub (Dec 23, 2025): I had spaces in APP_NAME and a "-" in MAIL_FROM_NAME, removing any special characters fixed it for me... but anything after a space in a variable gets cut, for example APP_NAME="Pelican Panel" turns into just Pelican the `export $(grep -v '^#' .env | xargs)` dislikes any special characters. I changed it to `. /var/www/html/.env` which fixed it not accepting any special characters
Author
Owner

@notAreYouScared commented on GitHub (Dec 23, 2025):

Ohhh, I thought you meant the variable name itself had a space... My bad.

@notAreYouScared commented on GitHub (Dec 23, 2025): Ohhh, I thought you meant the variable name itself had a space... My bad.
Author
Owner

@mristau commented on GitHub (Dec 23, 2025):

had the same in the discord there was a suggestion for this from Mainfrezzer

Image
@mristau commented on GitHub (Dec 23, 2025): had the same in the discord there was a suggestion for this from Mainfrezzer <img width="792" height="348" alt="Image" src="https://github.com/user-attachments/assets/3aed5be8-e7c4-4b1a-a298-2fc25ce2e7f5" />
Author
Owner

@parkervcp commented on GitHub (Jan 5, 2026):

You can try using #2063 and see if that works for you.

I too agreed that sourcing the env with . /var/www/html/.env works but there is an issue with it potentially running shell commands if someone updates config values in the panel.

@parkervcp commented on GitHub (Jan 5, 2026): You can try using #2063 and see if that works for you. I too agreed that sourcing the env with `. /var/www/html/.env` works but there is an issue with it potentially running shell commands if someone updates config values in the panel.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/panel-pelican-dev#528