Unable to install packages using Docker on Mac - docker

This morning I've started playing with Docker, so installed boot2docker on my Mac.
All seemed to be going well, following the Working with Docker Images documentation until I tried to create a Dockerfile to install the ruby gems.
I spent a long time banging my head against the wall as to why it couldn't connect to install the gems... then I eventually worked it out, so adding this here in case anyone else has this problem in future, as there wasn't anything on Google about it.

Turns out that, because my internet bombed out during the apt-get update command, it didn't complete the update, however running it again, docker was using the cached (incomplete) data, and so if didn't work.
The fix... Run the docker build without the cache using the command...
docker build -no-cache --tag="<vendor>/<build>:<tag>" .

Related

Failed to run node after installation

I have attempted to install an aurora node by following the guide below:
partner-relayer-deploy
However, I am having issues. If someone could point me in the right direction that would be appreciated.
This is the first time I have used docker so perhaps I am missing something basic. However, googling and some docker youtube tutorials have not help me solve it myself.
Below is a step by step of what I have done:
Running setup.sh in gitbash shows errors but continues to install.
connection errors but continues to install
When installation is complete (75GB downloaded) I did not have docker opened so it errored as it couldn't find the daemon
Opened docker. Docker shows apps restarting
Closes setup.sh and ran again. got errors.
Additional app shown in docker
closed gitbash. Renamed 'docker-compose.yaml-mainnet' to 'docker-compose.yaml' and moved from '.contrib' folder to 'partner-relayer-deploy' folder so I could run 'docker-compose up'. Ran 'docker-compose up' got errors.
Prior to posting I have done a fresh install but am still getting the same result.
---------update-----------
I found the below issue which has prompted me to ensure my docker images are up to date
https://github.com/aurora-is-near/partner-relayer-deploy/issues/20
endpoint updated but the others were fine.
https://hub.docker.com/r/nearaurora/endpoint/tags
https://hub.docker.com/r/nearaurora/nearcore/tags
https://hub.docker.com/r/nearaurora/database/tags
I am still getting the same issue when I run setup.sh
And get the following error when I run docker-compose up

Docker for windows doesn't work. What could I do with it?

Yeah, I know, there are some questions similar to that, but none of them helped me. My docker for windows has once stopped working. Now I can't even uninstall it, because in the applications it doesn't appear, I cannot install it, the installation stucks always on the same process, I tried to delete all the files and then install again, tried to stop all the proccesses related to docker, I tried everything. I cannot even uninstall, cannot reinstall, cannot run... cannot do anything with it... help!
I finally solved that. I deleted manually all the directories related to docker (ProgramFiles, ProgramData, [user root directory], Appdata/Roaming etc.) and this way the installer finally finished. There was another problem, that WSL2 engine tried to start, but couldn't. WSL was enabled, the engine starting process was running for ca. 1 hour... but nothing happend and couldn't even change the engine. So I reinstalled once again, and didn't install the WSL frame. It started automatically with Hyper-V and now it works fine.

Influx CLI driving me really crazy, cannot open the CLI

i am installing the influxdb_2.0.9 on my ubuntu, i followed the instructions here:
https://docs.influxdata.com/influxdb/v2.0/install/?t=Linux
I download it, setup it, i start the influxd daemon, i can connect via browser on localhost:8086, i think i can work with it, its functioning, i am gonna use the python API anyway, but this really drives me crazy...
I can't get to CLI. When i copy it to /usr/local/bin, or anywhere, or when i run it right in the directory via ./influx, it just returns a HELP message, like if i would type ./influx -h
Funny thing is when i download influxdb-client and run its influx binary, it starts the CLI, but its meant on version 1.6.4 and it does not seem to connect ideally on localhost running influxd 2.0.9, mbe i could somehow config it, but it seems to be bad idea anyway.
I purged everything, tried to reinstall everything, even manually deleted all empty directories, anything named influx on my 20.04 Ubuntu is gone and when i try to just follow the instructions online, everything seems to work except the CLI which i really **** need.
Just FYI, if i try to isntall via sudo apt-get install influxdb, influxdb-client -> it works perfectly, but it is older version 1.6.4
I tried installing the deb package via dpkg as well, but no difference... Im running 20.04 Ubuntu. There is the option of running older influxdb(1.6.x), but that I really dont want to do.
Anyone had the same problem? Could not find the solution in last hour online so im trying here to find help. This really drives me crazy though... Thanks for your time. Q.
Thank you guys for your time.
Well, i seem to realize, that the old CLI is gone and not implemented as it used to be, in the new version. In 2.0.0 it was started by
influx repl
But now i found a msg
I have no idea why they decided to deprecate this, not posting that much info about it..
I will try to finish this post by myself, leave it here, maybe someone in the future will find this useful.
Now I will try to 'build the REPL from source', wish me luck lol.
--EDIT
found a clone, closing the thread.
https://github.com/influxdata/influxdb/issues/19986

Hash Sum mismatch error, and others, while Installing Docker on Ubuntu 18.04 VM (VirtualBox)

Preface that I'm running these commands on a VirtualBox VM, Ubuntu Server 18.04. Unfortunately I can't get the bidirectional clipboard to work so I have to post all the output as links. Super sorry about that.
I've been trying to install Docker on an Ubuntu 18.04 VM on VirtualBox running on a Windows 10 Home, Version 10.0.19041 host. I've been encountering issues at every turn.
First, I tried to install with apt-get after following the instructions on the Docker Ubuntu install tutorial, to no avail. I get an error with "Hash Sum mismatch" shown pretty frequently. I also tried running the convenience script (i.e. curl -fsSL https://get.docker.com -o get-docker.sh followed by sudo sh get-docker.sh) on a completely fresh machine, and got the same errors.
After I was unable to install with apt-get, I tried downloading the packages and installing manually. When trying to curl the packages with
sudo curl -k -O -L https://download.docker.com/linux/ubuntu/dists/bionic/pool/stable/amd64/docker-ce_18.09.9~3-0~ubuntu-bionic_amd64.deb
and the same curl for docker-ce-cli and containerd.io debs I'm able to complete the downloads just fine. Then, when I run
sudo dpkg -i ./docker-ce_18.09.9~3-0~ubuntu-bionic_amd64.deb
to install the packages, I get these dpkg Errors, claiming that the deb is corrupted. I get the same errors no matter which deb I specify.
I suppose at the end of the day, Docker isn't strictly necessary for the project I'm working on, but it's very frustrating that I'm at such a loss. I'd be very grateful if anyone can give me some guidance. Please feel free to comment if you need any more system info.
p.s. I've seen a couple theories but don't know how to address them.
Possibly, an issue with WSL2 and the Virtual Machine Platform on Windows. Discussed in this thread, but it didn't seem like anyone found a solution.
An issue related to apt-cache and /var/lib/apt/lists/*, which I've already cleaned cleared multiple times.
I've also run apt-get update more times than I can count.
Update here. In the end I was unable to install Docker on my VirtualBox VM. The thing that worked for me was booting up an Ubuntu 18.04 VM in VMware. With all the same specifications, I was able to install Docker and get my application running. If anyone comes back to this question and finds a fix for this on VirtualBox, please post it and I'll mark it as the answer!
The GCrypt so library has a real issue computing hashes when running VirtualBox or other VM software under Windows 10. I made a video about this.
https://youtu.be/inU8pQLXIkE
Here is the solution:
mkdir /etc/gcrypt
touch /etc/gcrypt/hwf.deny
cd /etc/gcrypt
sudo vi hwf.deny
(edit this file to read "all" without quotes on line 1
Save.
This will solve the issue.

How to install docker-engine using docker binary without internet connection

I have downloaded docker binary version 1.8.2 and copied that to my backup server (centos server) which doesn't have internet connectivity. I have marked this as executable and started the docker daemon as mentioned in [https://docs.docker.com/engine/installation/binaries/][1]. But it doesn't seem to get installed as a docker service. For all the commands, I have to execute as sudo ./docker-1.8.2 {command}. Is there a way to install docker-engine as a service? Currently sudo docker version shows command not found. I'm a newbie to docker setup. Please advise.
Why not download the rpm package (there are also centos 6 packages), copy to USB stick and then to your server and simply install it with rpm command and that's it. That way you'd get the same installation as if you were to run yum.
Of course you may have some dependencies missing, but you could download all of these as well.
Firstly, if you're downloading bare binaries on an enterprise linux, you're probably doing things in a very bad way. Immediately, you're breaking updates and consistency, and leaving your system in a risky, messy state.
Try using yumdownloader --resolve to get the docker installable and anything it needs.
A better option may be to mirror the installation artifacts, and grab it from the local mirror, but that's beyond the scope if you don't do this already.

Resources