changed env for DB to be more DB agnostic
This commit is contained in:
parent
4232e41d6b
commit
83ba0f6464
@ -40,8 +40,8 @@ E621_API_KEY=
|
|||||||
E621_USERNAME=
|
E621_USERNAME=
|
||||||
DB_TYPE=neo4j
|
DB_TYPE=neo4j
|
||||||
DB_URL=
|
DB_URL=
|
||||||
NEO4J_PASSWORD=
|
DB_PASSWORD=
|
||||||
NEO4J_USERNAME=
|
DB_USERNAME=
|
||||||
```
|
```
|
||||||
|
|
||||||
## Running the Program
|
## Running the Program
|
||||||
@ -71,8 +71,8 @@ The program can also be run using Docker. To use Docker, follow these steps:
|
|||||||
E621_USERNAME=
|
E621_USERNAME=
|
||||||
DB_TYPE=neo4j
|
DB_TYPE=neo4j
|
||||||
DB_URL=
|
DB_URL=
|
||||||
NEO4J_PASSWORD=
|
DB_PASSWORD=
|
||||||
NEO4J_USERNAME=
|
DB_USERNAME=
|
||||||
````
|
````
|
||||||
|
|
||||||
2. Build the Docker image:
|
2. Build the Docker image:
|
||||||
|
@ -6,12 +6,12 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type Config struct {
|
type Config struct {
|
||||||
E621APIKey string `env:"E621_API_KEY,required"`
|
E621APIKey string `env:"E621_API_KEY,required"`
|
||||||
E621Username string `env:"E621_USERNAME,required"`
|
E621Username string `env:"E621_USERNAME,required"`
|
||||||
DBType string `env:"DB_TYPE,required"`
|
DBType string `env:"DB_TYPE,required"`
|
||||||
DBEndpoint string `env:"DB_URL,required"`
|
DBEndpoint string `env:"DB_URL,required"`
|
||||||
Neo4jUsername string `env:"NEO4J_USERNAME,required"`
|
DBUsername string `env:"DB_USERNAME,required"`
|
||||||
Neo4jPassword string `env:"NEO4J_PASSWORD,required"`
|
DBPassword string `env:"DB_PASSWORD,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// LoadConfig loads the configuration from environment variables
|
// LoadConfig loads the configuration from environment variables
|
||||||
|
Reference in New Issue
Block a user