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

Make tool installation more user-friendly #136

Merged
merged 1 commit into from Jul 1, 2019
Merged

Conversation

extsoft
Copy link
Contributor

@extsoft extsoft commented Jun 25, 2019

We still support 2 types of installations using install.bash:

  1. using remote git - a production installation which installs latest
    master branch by default.
  2. using local sources - an installation type which is provided for
    development purposes. It is a part of testing procedure also.
    By default, a tool is installed into ``${HOME}/.elegant-gitdirectory. Meanwhile, the installation path can be customized. Seeinstall.bash`
    for further details.

Uninstall process is removed from install.bash as it has to be
managed separately.

New project layout:
.
├── bin - production scripts only
├── completions - completions for different shells
├── docs - WEB site with documentation
├── libexec - auxiliary scripts needed for production scripts
└── tests - unit tests

Also, run-tests is working only from a docker environment as it may
install 'bad' code into /usr/local.

We still support 2 types of installations using `install.bash`:
1. using remote git - a production installation which installs latest
   master branch by default.
2. using local sources - an installation type which is provided for
   development purposes. It is a part of testing procedure also.
By default, a tool is installed into ``${HOME}/.elegant-git` directory.
Meanwhile, the installation path can be customized. See `install.bash`
for further details.

Uninstall process is removed from `install.bash` as it has to be
managed separately.

New project layout:
.
├── bin          - production scripts only
├── completions  - completions for different shells
├── docs         - WEB site with documentation
├── libexec      - auxiliary scripts needed for production scripts
└── tests        - unit tests

Also, `run-tests` is working only from a docker environment as it may
install 'bad' code into `/usr/local`.
@extsoft
Copy link
Contributor Author

extsoft commented Jun 25, 2019

@rultor please merge.

@rultor
Copy link

rultor commented Jun 25, 2019

@rultor please merge.

@extsoft OK, I'll try to merge now. You can check the progress of the merge here

@rultor
Copy link

rultor commented Jun 25, 2019

@rultor please merge.

@extsoft Oops, I failed. You can see the full log here (spent 2min)

+ '[' 0 -eq 1 ']'
+ echo 'load average is 5.97, low enough to run a new Docker container'
load average is 5.97, low enough to run a new Docker container
+ break
+ cd ..
+ '[' -n '' ']'
+ use_image=extsoft/elegant-git-ci:1
+ docker pull extsoft/elegant-git-ci:1
1: Pulling from extsoft/elegant-git-ci
Digest: sha256:43aba19447b0aed11da4efc80de70751ca407c41f2f58cc46f2c9449ba7c3719
Status: Image is up to date for extsoft/elegant-git-ci:1
+ docker ps --filter=status=exited
+ grep --quiet '\sbees-hive_elegant-git_136\s*$'
+ ls -al .
total 716
drwx--x--x  3 rultor rultor   4096 Jun 25 15:21 .
drwxrwxrwt 16 root   root   684032 Jun 25 15:21 ..
-rw-rw-r--  1 rultor rultor    444 Jun 25 15:21 end.sh
-rwxrwxr-x  1 rultor rultor    162 Jun 25 15:21 entry.sh
-rw-rw-r--  1 rultor rultor      6 Jun 25 15:21 pid
drwxrwxr-x  8 rultor rultor   4096 Jun 25 15:21 repo
-rwxrwxr-x  1 rultor rultor   5536 Jun 25 15:21 run.sh
-rw-rw-r--  1 rultor rultor    430 Jun 25 15:21 script.sh
-rw-rw-r--  1 rultor rultor   9020 Jun 25 15:21 stdout
++ pwd
++ pwd
+ docker run -t --rm -v /tmp/rultor-2zFY:/main --env=head=git@github.com:bees-hive/elegant-git.git --env=pull_id=136 --env=fork=git@github.com:bees-hive/elegant-git.git --env=fork_branch=update-install --env=head_branch=master '--env=pull_title=Make tool installation more user-friendly' --env=author=extsoft '--env=scripts=( '\''export '\''\'\'''\''head=git@github.com:bees-hive/elegant-git.git'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''pull_id=136'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''fork=git@github.com:bees-hive/elegant-git.git'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''fork_branch=update-install'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''head_branch=master'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''pull_title=Make tool installation more user-friendly'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''author=extsoft'\''\'\'''\'''\'' '\'';'\'' '\''./run-tests'\'' '\'';'\'' )' --hostname=docker --privileged --memory=6g --memory-swap=16g --oom-kill-disable --cidfile=/tmp/rultor-2zFY/cid -w=/main -v /var/run/docker.sock:/var/run/docker.sock --name=bees-hive_elegant-git_136 extsoft/elegant-git-ci:1 /main/entry.sh
WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap.
+ set -e
+ set -o pipefail
+ mkdir /home/r
+ cp -R ./cid ./end.sh ./entry.sh ./pid ./repo ./run.sh ./script.sh ./stdout /home/r
+ rm -rf repo
+ chmod a+x /home/r/script.sh
+ /home/r/script.sh
+ set -e
+ set -o pipefail
+ shopt -s expand_aliases
+ alias 'sudo=sudo -i'
+ export HOME=/home/r
+ HOME=/home/r
+ cd /home/r/repo
+ export head=git@github.com:bees-hive/elegant-git.git
+ head=git@github.com:bees-hive/elegant-git.git
+ export pull_id=136
+ pull_id=136
+ export fork=git@github.com:bees-hive/elegant-git.git
+ fork=git@github.com:bees-hive/elegant-git.git
+ export fork_branch=update-install
+ fork_branch=update-install
+ export head_branch=master
+ head_branch=master
+ export 'pull_title=Make tool installation more user-friendly'
+ pull_title='Make tool installation more user-friendly'
+ export author=extsoft
+ author=extsoft
+ ./run-tests
Testing is disabled!
container 18f9cccd786eadfcf534777cfaadf33bff68248314a0c90db8c2e71ef3c458ae is dead
Tue Jun 25 15:22:39 CEST 2019

@extsoft
Copy link
Contributor Author

extsoft commented Jun 25, 2019

@rultor please merge.

@rultor
Copy link

rultor commented Jun 25, 2019

@rultor please merge.

@extsoft OK, I'll try to merge now. You can check the progress of the merge here

@rultor
Copy link

rultor commented Jun 25, 2019

@rultor please merge.

@extsoft Oops, I failed. You can see the full log here (spent 2min)

+ '[' 0 -eq 1 ']'
+ echo 'load average is 5.34, low enough to run a new Docker container'
load average is 5.34, low enough to run a new Docker container
+ break
+ cd ..
+ '[' -n '' ']'
+ use_image=extsoft/elegant-git-ci:1
+ docker pull extsoft/elegant-git-ci:1
1: Pulling from extsoft/elegant-git-ci
Digest: sha256:43aba19447b0aed11da4efc80de70751ca407c41f2f58cc46f2c9449ba7c3719
Status: Image is up to date for extsoft/elegant-git-ci:1
+ docker ps --filter=status=exited
+ grep --quiet '\sbees-hive_elegant-git_136\s*$'
+ ls -al .
total 716
drwx--x--x  3 rultor rultor   4096 Jun 25 15:33 .
drwxrwxrwt 17 root   root   684032 Jun 25 15:33 ..
-rw-rw-r--  1 rultor rultor    444 Jun 25 15:33 end.sh
-rwxrwxr-x  1 rultor rultor    162 Jun 25 15:33 entry.sh
-rw-rw-r--  1 rultor rultor      6 Jun 25 15:33 pid
drwxrwxr-x  8 rultor rultor   4096 Jun 25 15:33 repo
-rwxrwxr-x  1 rultor rultor   5536 Jun 25 15:33 run.sh
-rw-rw-r--  1 rultor rultor    430 Jun 25 15:33 script.sh
-rw-rw-r--  1 rultor rultor   9020 Jun 25 15:33 stdout
++ pwd
++ pwd
+ docker run -t --rm -v /tmp/rultor-ytEu:/main --env=head=git@github.com:bees-hive/elegant-git.git --env=pull_id=136 --env=fork=git@github.com:bees-hive/elegant-git.git --env=fork_branch=update-install --env=head_branch=master '--env=pull_title=Make tool installation more user-friendly' --env=author=extsoft '--env=scripts=( '\''export '\''\'\'''\''head=git@github.com:bees-hive/elegant-git.git'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''pull_id=136'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''fork=git@github.com:bees-hive/elegant-git.git'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''fork_branch=update-install'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''head_branch=master'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''pull_title=Make tool installation more user-friendly'\''\'\'''\'''\'' '\'';'\'' '\''export '\''\'\'''\''author=extsoft'\''\'\'''\'''\'' '\'';'\'' '\''./run-tests'\'' '\'';'\'' )' --hostname=docker --privileged --memory=6g --memory-swap=16g --oom-kill-disable --cidfile=/tmp/rultor-ytEu/cid -w=/main -v /var/run/docker.sock:/var/run/docker.sock --name=bees-hive_elegant-git_136 extsoft/elegant-git-ci:1 /main/entry.sh
WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap.
+ set -e
+ set -o pipefail
+ mkdir /home/r
+ cp -R ./cid ./end.sh ./entry.sh ./pid ./repo ./run.sh ./script.sh ./stdout /home/r
+ rm -rf repo
+ chmod a+x /home/r/script.sh
+ /home/r/script.sh
+ set -e
+ set -o pipefail
+ shopt -s expand_aliases
+ alias 'sudo=sudo -i'
+ export HOME=/home/r
+ HOME=/home/r
+ cd /home/r/repo
+ export head=git@github.com:bees-hive/elegant-git.git
+ head=git@github.com:bees-hive/elegant-git.git
+ export pull_id=136
+ pull_id=136
+ export fork=git@github.com:bees-hive/elegant-git.git
+ fork=git@github.com:bees-hive/elegant-git.git
+ export fork_branch=update-install
+ fork_branch=update-install
+ export head_branch=master
+ head_branch=master
+ export 'pull_title=Make tool installation more user-friendly'
+ pull_title='Make tool installation more user-friendly'
+ export author=extsoft
+ author=extsoft
+ ./run-tests
Testing is disabled!
container 6526984e2329bcbe668d9f53cb04d3dc0b675c54095d5a157d122752109f04f3 is dead
Tue Jun 25 15:34:55 CEST 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants