-
Notifications
You must be signed in to change notification settings - Fork 0
2. Setup
Start by cloning git clone https://github.com/denesdata/gem.git this repository into a folder of your choice.
Then, before you can docker-compose up, you will need to jump through a few hoops.
- BTW, first thing is to install docker-compose, if you haven't already:
apt install docker-compose - Next, go into
sudo, asdockeris a bit picky with non-superusers:sudo bash
Then, after pulling everything, you should end up with a docker-compose.yml and a traefik.toml file, as well as a jupyter folder, with a Dockerfile in it.
The next thing you want to do is to set up your passwords.
- First, go into the jupyter/Dockerfile and change
YOUR_PASSWORD_HEREwith your chosen password to access Jupyter. Next, in the terminal type:export INFLUXDB_ADMIN_PASSWORD=YOUR_PASSWORD_HEREand changeYOUR_PASSWORD_HEREwith your chosen password for the InfluxDB admin user.Next, in the terminal type:export INFLUXDB_USER_PASSWORD=YOUR_PASSWORD_HEREand changeYOUR_PASSWORD_HEREwith your chosen password for InfluxDB editor user.- Next, in the terminal type:
export DOCKER_INFLUXDB_INIT_PASSWORD=YOUR_PASSWORD_HEREand changeYOUR_PASSWORD_HEREwith your chosen password for InfluxDB editor user. You will need to be on the same user account for this step to work, as the one from where you intend todocker-compose upat the end. I.e., if you aresudo nowyou will have to use therootaccount todocker-compose up. - Finally, we need to set up the Traefik monitor. You may want to read this tutorial before you start.
- Weβll use the
htpasswdutility to create this encrypted password. - First, install the utility, which is included in the
apache2-utilspackage:sudo apt-get install apache2-utils - Then generate the password with
htpasswdcommand:htpasswd -nb admin YOUR_PASSWORD_HERE. SubstituteYOUR_PASSWORD_HEREwith the password youβd like to use for the Traefik admin user. - The output from the program will look like this:
admin:$apr1$uca84Hq$mbjdMZBAG.KWn7vfN/SNK/. We will use this output in the Traefik configuration file to set up HTTP Basic Authentication for the Traefik health check and monitoring dashboard. Copy the entire output line so you can paste it later.
Now we're ready to configure Traefik to route our services correctly. Create a dummy certificate file and set its correct permissions.
touch acme.jsonchmod 600 acme.json- Next up, edit the
traefik.tomlfile and change every path containingmyserv.erto your server's domain. - Then, in the
userssection replace<YOUR_HASH_HERE>with your Traefik password hash generated withhtpasswdat the previous step.
Finally, you will need to configure the correct addresses for your services for Traefik in the docker-compose.yml file.
- Edit the
docker-compose.ymlfile and change every path containingmyserv.erto your server's domain. - Do not change any ports, unless you also do it in
traefik.toml. - Set up any custom environment variables, such as Grafana plugins or InfluxDB databases.
π If you did everything correctly, then following command should lift you off:
docker-compose up- If you get a network not found error, try
docker network create web - You might want to use
docker-compose up -d --buildinstead to run in detached mode (in the background), and force an image build (although it will build on first run anyway). - On migration and upgrades you might want to start with a clean Docker environment. For this stop and remove all containers (
docker-compose downin the root directory of your project) and remove all unused images (docker image prune -a- be careful to understand what this means.) - After that, run
docker-compose up -dagain and you should see all your data nicely preserved, but not the styling. For this run the styling script again covered at the end of this section.
π Continue by starting the 3. Run.
π·π΄πΉππ Global Entrepreneurship Monitor Romania https://econ.ubbcluj.ro/entrepreneurship