Skip to content
Snippets Groups Projects
Commit a3fa17fb authored by Emmanuel Bruno's avatar Emmanuel Bruno
Browse files

fixes typos.

parent f0f297c2
Branches
No related tags found
No related merge requests found
...@@ -26,14 +26,14 @@ export CI_WRAPPER_HOME=${HOME}/.ci-wrappers ...@@ -26,14 +26,14 @@ export CI_WRAPPER_HOME=${HOME}/.ci-wrappers
## Usage ## Usage
- `install-ci-software` <br/> - `ci-install-software` <br/>
Installs GitHub CLI, Docker client, docker compose plugin, vagrant and terraform in $CI_WRAPPERS_HOME Installs GitHub CLI, Docker client, docker compose plugin, vagrant and terraform in $CI_WRAPPERS_HOME
- `new-java-project testci fr.univtln.bruno.tests` <br/> - `new-java-project testci fr.univtln.bruno.tests` <br/>
Creates a new maven projects ready for C.I. Creates a new maven projects ready for C.I.
- `docker-mvn` <br/> - `docker-mvn` <br/>
Wraps maven in a container (docker needed see beelow).<br/> Wraps maven in a container (docker needed see beelow).<br/>
For example to build a C.I. project: `docker-mvn clean verify` For example to build a C.I. project: `docker-mvn clean verify`
- `github-runner-repo` or `github-runner-org` <br/> - `ci-github-runner-repo` or `ci-github-runner-org` <br/>
Creates and register a new GitHub runner in a docker container for the current repository Creates and register a new GitHub runner in a docker container for the current repository
or the organisation (account). or the organisation (account).
- A docker engine with http proxy support in VM : - A docker engine with http proxy support in VM :
......
...@@ -17,7 +17,7 @@ var_expand() { ...@@ -17,7 +17,7 @@ var_expand() {
} }
ci-wrappers-usage() { ci-wrappers-usage() {
printf 'install-ci-software\n\t installs a docker client and compose plugin, Github CLI, vagrant and terraform in %s/bin\n'"${CI_WRAPPERS_HOME}" printf 'ci-install-software\n\t installs a docker client and compose plugin, Github CLI, vagrant and terraform in %s/bin\n'"${CI_WRAPPERS_HOME}"
printf "new-java-project [projectname] [groupid]\n\t create a new java+maven project ready for CI\n" printf "new-java-project [projectname] [groupid]\n\t create a new java+maven project ready for CI\n"
echo "docker-wrapper" echo "docker-wrapper"
echo "docker-wrapper-build" echo "docker-wrapper-build"
...@@ -27,7 +27,7 @@ ci-wrappers-usage() { ...@@ -27,7 +27,7 @@ ci-wrappers-usage() {
echo "docker-sonar-analysis" echo "docker-sonar-analysis"
} }
install-ci-software() { ci-install-software() {
_init _init
if [ -n "$ZSH_VERSION" ]; then emulate -L ksh; fi if [ -n "$ZSH_VERSION" ]; then emulate -L ksh; fi
...@@ -292,11 +292,11 @@ _generate_and_install_new_deploy_key() ( ...@@ -292,11 +292,11 @@ _generate_and_install_new_deploy_key() (
) )
# create a github hosted runner in a container for the current repo # create a github hosted runner in a container for the current repo
github-runner-repo() ( ci-github-runner-repo() (
_check_variables GITHUBORG _check_variables GITHUBORG
local workdir local workdir
workdir=$(mktemp --directory "/tmp/ghrunner-${GITHUBORG}_${PWD##*/}_XXXXXX") workdir=$(mktemp --directory "/tmp/ghrunner-${GITHUBORG}_${PWD##*/}_XXXXXX")
docker run -d --rm --restart always --name ghrunner_$(echo "$workdir" | cut -d '-' -f 2) \ docker run -d --rm --restart unless-stopped --name ghrunner_$(echo "$workdir" | cut -d '-' -f 2) \
-e RUNNER_NAME_PREFIX="${GITHUBORG}-${PWD##*/}-runner" \ -e RUNNER_NAME_PREFIX="${GITHUBORG}-${PWD##*/}-runner" \
-e ACCESS_TOKEN="${GITHUBTOKEN}" \ -e ACCESS_TOKEN="${GITHUBTOKEN}" \
-e RUNNER_SCOPE="repo" \ -e RUNNER_SCOPE="repo" \
...@@ -308,11 +308,11 @@ github-runner-repo() ( ...@@ -308,11 +308,11 @@ github-runner-repo() (
) )
# create a github hosted runner in a container for the org in $GITHUBORG # create a github hosted runner in a container for the org in $GITHUBORG
github-runner-org() ( ci-github-runner-org() (
_check_variables GITHUBORG _check_variables GITHUBORG
local workdir local workdir
workdir=$(mktemp --directory "/tmp/ghrunner-${GITHUBORG}_XXXXXX") workdir=$(mktemp --directory "/tmp/ghrunner-${GITHUBORG}_XXXXXX")
docker run -d --rm --restart always --name ghrunner_$(echo "$workdir" | cut -d '-' -f 2) \ docker run -d --rm --restart unless-stopped --name ghrunner_$(echo "$workdir" | cut -d '-' -f 2) \
-e RUNNER_NAME_PREFIX="${GITHUBORG}-${PWD##*/}-runner" \ -e RUNNER_NAME_PREFIX="${GITHUBORG}-${PWD##*/}-runner" \
-e ACCESS_TOKEN="${GITHUBTOKEN}" \ -e ACCESS_TOKEN="${GITHUBTOKEN}" \
-e RUNNER_SCOPE="org" \ -e RUNNER_SCOPE="org" \
...@@ -324,7 +324,7 @@ github-runner-org() ( ...@@ -324,7 +324,7 @@ github-runner-org() (
myoung34/github-runner:latest myoung34/github-runner:latest
) )
github-runner-remove-all() ( ci-github-runner-remove-all() (
docker rm $(docker ps -a|grep myoung34/github-runner|cut -f 1 -d ' ') docker rm $(docker ps -a|grep myoung34/github-runner|cut -f 1 -d ' ')
) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment