lancachenet / lancache-dns

DNS Docker service for a lancache.
https://hub.docker.com/r/lancachenet/lancache-dns/
MIT License
282 stars 74 forks source link

Variables in place for cache_domains.json and services downloaded from uklans/cache_domains #71

Closed some-username-here1 closed 5 years ago

some-username-here1 commented 5 years ago

As the title says. And what once was a modification for myself so I could test a branch for some-username-here1/cache-domains/minecraft, I thought it'd be a good idea to turn the static download location and echo into a variable that allows you to redirect to your own fork or branch for testing!

EDIT: I'll be testing this soon

some-username-here1 commented 5 years ago

I have created a container for myself with ENV GITHUB_USERNAME set to some-username-here1 and ENV GITHUB_BRANCH to minecraft, as both an example and something I was going to test on, but it's still using the default repository. How do I implement the new ENVs to it so it can be implemented into the bootstrap and used to override the default repository?

VibroAxe commented 5 years ago

You are overriding the env variable in the script, you need to use a default assignment instead like USE_GENERIC_CACHE="${USE_GENERIC_CACHE:-false}"

So for your GITLAB_USERNAME env var you would set GITLAB_USERNAME="${GITLAB_USERNAME:-uklans}"

For good measure you should also add the ENV var to the docker file

some-username-here1 commented 5 years ago

It works! but I'm getting an error with my fork's branch for the minecraft service, being:

==> /var/log/named/general.log <==

21-Feb-2019 05:07:41.190 dns_rdata_fromtext: /etc/bind/cache/minecraft.db:2: near 'ns1': bad name (check-names)

21-Feb-2019 05:07:41.205 all zones loaded

21-Feb-2019 05:07:41.205 running

==> /var/log/named/default.log <==

21-Feb-2019 05:07:41.190 managed-keys-zone: loaded serial 0

21-Feb-2019 05:07:41.190 zone 404:\032Not\032Found/IN: loading from master file /etc/bind/cache/minecraft.db failed: bad name (check-names)

21-Feb-2019 05:07:41.190 zone 404:\032Not\032Found/IN: not loaded due to errors.

So I'm unable to test my cache with the old minecraft launcher

(also really sorry about deleting my old fork that was linked in this PR, still new to how this works)

some-username-here1 commented 5 years ago

I got my fork of cache-domans (branch: minecraft) working!

here's a log for proof: access.log

Is it alright to pull? given the changes I made that you'll review

VibroAxe commented 5 years ago

Closed by #85