-
Notifications
You must be signed in to change notification settings - Fork 29
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
WIP: Hrfilter #87
base: develop
Are you sure you want to change the base?
WIP: Hrfilter #87
Conversation
- supports ubuntu 17+ & disabling of nginx ppa
* config variable was not named correctly * sidekiq.yml config file was not created on systemd variant
Uff.... @arBmind I think I give up for now. Already burned a couple of hours. Maybe someone with more init/docker/systemd knowledge can create a container that works with started network services. Having to run systemd service inside Docker seems to be not ...easy.... What I've tried:
e.g. current playbook just apt: redis start redis, but then: If google looks like that, that means I should take a break :D |
@zealot128 did you take a look @strfry changes in pr #77 ? - I guess he ran into the same issues and solved it. |
Thx for the tip; Just tried that with exact same run_opts / image, but Ubuntu 18.04:
Using the given Ubuntu 16.04 Dockerfile and the run_opts, I get this failure from the first ansible task that uses Service Module, or if I attach via docker exec and using service/systemctl:
Full test script for reference (Unchanged Ubuntu 16.04 Dockerfile) distribution='ubuntu'
version='16.04'
init="/sbin/init"
site="hrfilter"
run_opts="--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro --volume=/sys/fs/cgroup/systemd:/sys/fs/cgroup/systemd:rw"
docker build --rm=true --file=tests/Dockerfile.${distribution}-${version} \
--tag=${distribution}-${version}:ansible tests
container_id=$(mktemp)
echo "Starting container..."
docker run --detach --ulimit nofile=1024 \
--volume=${PWD}:/etc/ansible/roles/dresden-weekly.Rails:ro ${run_opts} \
${distribution}-${version}:ansible ${init} > ${container_id}
echo "Running tests
you can enter the container like this:
docker exec -it $(cat ${container_id}) bash
"
docker exec -e ANSIBLE_FORCE_COLOR=1 "$(cat ${container_id})" env TERM=xterm \
ansible-playbook /etc/ansible/roles/dresden-weekly.Rails/tests/${site}/playbook.yml Playbook will e.g. crash on PostgreSQL or any other thing with native ansible "service" (like apt: redis-server; service: name=redis-server state=started) |
I got it somewhat working:
See: https://travis-ci.org/arBmind/ansible-rails/builds/528273312
I already added a script to prevent the Travis 10 minute timeout. But this wont help to debug where Ansible got stuck and requires a manual cancel if we don't want to be banned by Travis :) |
Great work! that brings me further... I've noticed that I've also maybe ran in circles. For brevity, I only tried to install redis and run it with the default service module. After trying your docker file & run_opts, redis still failed, but the reason seems to be ipv6 related redis/redis#5055 Now, after removing ipv6 binding the script will run further. Let's check... :) |
regarding compile time: # from within container
$ rvm install 2.6.0
Searching for binary rubies, this might take some time.
Found remote file https://rvm_io.global.ssl.fastly.net/binaries/ubuntu/18.04/x86_64/ruby-2.6.0.tar.bz2
Libraries missing for ruby-2.6.0: /home/deploy/.rvm/rubies/ruby-2.6.0/lib/ruby/2.6.0/x86_64-linux/openssl.so:. Refer to your system manual for installing libraries
Mounting remote ruby failed with status 10, trying to compile. Thus, will compile from source. With openssl problems, maybe uses rvm pkg get openssl and compiles openssl from source, too... no wonder \o/ Tried various variations of different ubuntu libs, but none worked. seems to be some issues in RVM, too rvm/rvm#4616 |
a lot of things....
Test addons:
Role fixes to support hrfilter role natively:
Added HRfilter site test:
Let's see what the test results brings back