• Resolved Dbee

    (@dbee78)


    I’m working on a wp-env docker instance of wordpress. I have a .wp-env.json file with my database connection strings that I don’t want to push to the gitlab repo.

    What’s the best way of feeding these strings in from the ubuntu bash shell so they don’t get exported to the gitlab repo … ?

    • This topic was modified 3 years, 10 months ago by Jan Dembowski.
Viewing 1 replies (of 1 total)
  • Thread Starter Dbee

    (@dbee78)

    Got it. You can feed them in through the bash command line …

    wp-env --config "WP_PASSWORD"="mypass" --config "WP_DATABASE"="mydb" --config "WP_USER"="myuser" --config "WP_HOST"="localhost" start
    

    That seems to do the trick. And just remove the values in .wp-env.json

Viewing 1 replies (of 1 total)
  • The topic ‘Creating env variables for db in wp-env in ubuntu …’ is closed to new replies.