Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up initialization code for server #426

Open
horner opened this issue Feb 10, 2024 · 1 comment
Open

Clean up initialization code for server #426

horner opened this issue Feb 10, 2024 · 1 comment
Labels
good first issue Good for newcomers

Comments

@horner
Copy link
Member

horner commented Feb 10, 2024

We should make /data not hard-coded. The code right now assumes that you're running in a docker container, unless you have a .env file. We should make the code fail if the work-dir is not available (or ask if you want to make it).

https://github.com/mieweb/wikiGDrive/blame/ede6dea55946cebc41ad26de1e4d94aaccd612b6/src/cli/wikigdrive-server.ts#L64

The older code always made a work dir in the cwd and it was painful to launch and then start the download if you accidentally were in the wrong directory.

@horner horner added the good first issue Good for newcomers label Feb 10, 2024
@horner horner mentioned this issue Feb 10, 2024
@horner
Copy link
Member Author

horner commented Feb 10, 2024

const workdir = argv['workdir'] || process.env.VOLUME_DATA || '/data';

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
Development

No branches or pull requests

1 participant