snipe-it icon indicating copy to clipboard operation
snipe-it copied to clipboard

snipe won't read my .env file

Open mntsupport opened this issue 7 years ago • 10 comments

I have read [checked the Common Issues page, and I tried to enable debug but as the system isn't reading my.env file it didn't work.

Describe the bug When I copied the .env.example file to .env and made changes within, the system doesn't recognize any of the changes.

To Reproduce Steps to reproduce the behavior:

  1. Go to snipe-it root
  2. Copy .env.example to .env
  3. Edit .env with preferences and save file
  4. restarted apache and ran the php artisan config:clear command
  5. rebooted the whole machine
  6. none of the changes were implemented

Expected behavior When editing the .env file and restarting the required services, the changes should go into effect.

Server (please complete the following information):

  • Snipe-IT Version: v4.7.7 build 4160 (gb8f7cd81e)
  • OS: Ubuntu 16.04
  • Web Server: Apache2
  • PHP Version: 7.1.32-1+ubuntu16.04.1+deb.sury.org+1

mntsupport avatar Oct 23 '19 18:10 mntsupport

Try running php artisan config:clear and php artisan config:cache

https://snipe-it.readme.io/docs/clearing-the-config-cache

Snipe-IT will try to cache your `.env` file variables for re-use to speed things up a bit, if you run the `php artisan config:cache` command. That's awesome, but if you forgot that you cached your config settings, make a change to your `.env`, and don't see the changes reflected, that can be really ...

Diniver avatar Oct 24 '19 09:10 Diniver

I have run those commands and just ran them again and it still won't change according to my .env. Any other suggestions?

mntsupport avatar Oct 24 '19 17:10 mntsupport

image

this is the specific area I am expecting to update.

mntsupport avatar Oct 24 '19 18:10 mntsupport

Just curious if anyone is still looking at this?

mntsupport avatar Oct 30 '19 00:10 mntsupport

Hi mntsupport,

The field that updates this value is MAIL_REPLYTO_ADDR= (Your email you wish the test to go to)

Can you confirm that this email or section is filled out?

CoventryIT avatar Oct 31 '19 19:10 CoventryIT

I can confirm I have that section filled out. The problem seems to be that the system won't read my .env file. For example I've tried to enable the debug mode by editing the .env file and it still doesn't work. Do I need to place the file in a different location than the env.example file? Sorry, I'm just lost on this...

mntsupport avatar Oct 31 '19 23:10 mntsupport

Check the file permissions of your .env file Try to clear the bootstrap cache manually. Go to <intall dir ->bootstrap->cache and delete everything in it.

Then run composer dump-autoload Then clear configuration cache php artisan cache:clear php artisan config:cache

nerdsome avatar Dec 16 '19 13:12 nerdsome

Hi!

I have resolved this a month ago. Thak you. Dillan Picray Systems Administrator

E: [email protected] (mailto:[email protected]) P: (763) 228-4553 (tel:(763)%20228-4553)

On Dec 16 2019, at 7:59 am, Samuel Maloba [email protected] wrote:

Check the file permissions of your .env file Try to clear the bootstrap cache manually. Go to <intall dir ->bootstrap->cache and delete everything in it.

Then run composer dump-autoload Then clear configuration cache php artisan cache:clear php artisan config:cache

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub (https://github.com/snipe/snipe-it/issues/7534?email_source=notifications&email_token=ANSL47W56MFPB3UFX44WCL3QY6CS3A5CNFSM4JEGCDEKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEG6ZLIY#issuecomment-566072739), or unsubscribe (https://github.com/notifications/unsubscribe-auth/ANSL47SYN3AYXKYILJIXGWLQY6CS3ANCNFSM4JEGCDEA).

mntsupport avatar Dec 16 '19 14:12 mntsupport

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail. This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

stale[bot] avatar Feb 14 '20 14:02 stale[bot]

This issue has been automatically closed because it has not had recent activity. If you believe this is still an issue, please confirm that this issue is still happening in the most recent version of Snipe-IT and reply to this thread to re-open it.

stale[bot] avatar Feb 21 '20 15:02 stale[bot]