summaryrefslogtreecommitdiff
path: root/hack/get_ci_vm.sh
Commit message (Collapse)AuthorAge
* implement reverse reader for log readsBrent Baude2020-02-20
| | | | | | | | in cases where the log file exceeds the available memory of a system, we had a bug that triggered an oom because the entire logfile was being read when the tail parameter was given. this reads in chunks and is more or less memory safe. fixes: #5131 Signed-off-by: Brent Baude <bbaude@redhat.com>
* codespell: spelling correctionsDmitry Smirnov2019-11-13
| | | | Signed-off-by: Dmitry Smirnov <onlyjob@member.fsf.org>
* Adjust get_ci_vm.sh for substitutionChris Evich2019-08-12
| | | | Signed-off-by: Chris Evich <cevich@redhat.com>
* Cirrus: Add support for testing F30Chris Evich2019-06-14
| | | | | | | | | | | | | | | | Remove disused `build_cache_images` task, and update relevant dockerfiles for F30. Fix problem of cloud-init failing to expand root-device on boot (/var/lib/cloud/instance left in improper state). Fix problem of cloud-init racing with google-network-daemon.service on boot (looking for cloudconfig metadata too early). Causing root-device to _sometimes_ fail to expand. Fix problem of hack/get_ci_vm.sh argument passing. Signed-off-by: Chris Evich <cevich@redhat.com>
* hack: support setting local region/zoneChris Evich2019-05-29
| | | | Signed-off-by: Chris Evich <cevich@redhat.com>
* hack: ignore from all VCS files when tarballingChris Evich2019-05-22
| | | | Signed-off-by: Chris Evich <cevich@redhat.com>
* hack: shrink xfer tarball sizeChris Evich2019-05-22
| | | | Signed-off-by: Chris Evich <cevich@redhat.com>
* hack: Display IP address of VM from scriptChris Evich2019-05-22
| | | | | | Useful for accessing it from other terminals. Signed-off-by: Chris Evich <cevich@redhat.com>
* Cirrus: fixups based on review feedbackChris Evich2019-05-21
| | | | | | Also remove disused distros (RHEL/CentOS/FAH) and fix get_ci_vm script Signed-off-by: Chris Evich <cevich@redhat.com>
* Merge pull request #2433 from cevich/hack_around_homeOpenShift Merge Robot2019-03-27
|\ | | | | [ci skip] get_ci_vm.sh: Fix conflicting homedir files
| * get_ci_vm.sh: Fix conflicting homedir filesChris Evich2019-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the script would bind mount the user's home directory into the container in order to execute gcloud commands. This was done to preserve the `.config/gcloud` directory and new ssh keys in `.ssh`. However, it's possible the user has modified `.bash*` or `.ssh/config` files which do not play nicely with gcloud and/or the container. Fix this by mounting the existing temporary directory on the host, as the user's home directory. Then bind mount in a dedicated `gcloud/ssh` sub-directory, and the libpod repo directory on top. Pre-create the necessary mount-points as the user, so later removal does not require root on the host. The gcloud tool takes minutes to setup/manage its ssh-keys, so preserving that work between runs is a necessary optimization. Similarly, saving the `.gcloud` directory prevents repeatedly going through the lengthy client-auth process. Overall, these changes make the container environment much more selective with the host-side data it has access to use/modify. Preventing unrelated details from getting in the way, and preserving only the bare-minimum of details on the host, between runs. Signed-off-by: Chris Evich <cevich@redhat.com>
* | Cirrus: Various fixes for rootless testingChris Evich2019-03-19
| | | | | | | | | | | | | | | | | | * Randomize the user's UID and GID * Simplify `setup_environment.sh` * Support new "-r" option for `hack/get_ci_vm.sh` setting up rootless * Connect as $ROOTLESS_USER when using "-r" with `hack/get_ci_vm.sh` Signed-off-by: Chris Evich <cevich@redhat.com>
* | Enable rootless integration testsbaude2019-03-19
|/ | | | Signed-off-by: baude <bbaude@redhat.com>
* get_ci_vm : allow running without sudoEd Santiago2019-02-13
| | | | | | | | | | | | | | | | | | | | | | | | | | More complicated than one would think. The first problem is that, on certain (but not all) Fedora systems, podman cannot mount volumes read-only (issue #2312). This is baffling, and since it's not easily reproducible it's likely that the dev team will not spend much effort on it. Workaround: instead of bind- mounting /tmp read-only, bind-mount a *tempdir* (subdirectory) read-write. This is actually cleaner in some ways but it leads to complications with the paths we use and with cleanup. Next, allow overriding the default image and allow asking for no sudo: export GCLOUD_IMAGE=quay.io/edsantiago/gcloud_centos:latest export GCLOUD_SUDO= (yes, that's an equal-sign and EOL. Just an empty string). The third part, unfortunately, requires a custom image because the as_dollar_user.sh script (the one that runs gcloud in a container) is hardwired in a cevich image and needs tweaks in order to detect rootless and avoid sudo. Signed-off-by: Ed Santiago <santiago@redhat.com>
* Cirrus: Consolidate VM image names in once placeChris Evich2019-01-17
| | | | | | | | | | | | | | Previously it was not possible to specify keys from the ``env`` section in the various GCE sections. Now that features is added, consolidate all the cache image definitions into a single place, reducing maintenance burden. This also results in the names passing through into the VMs. This is useful, e.g. for future tracking of image usage statistics. Update get_ci_vm script hints for new image name definition format Signed-off-by: Chris Evich <cevich@redhat.com>
* [skip ci] Hack: Fix get_ci_vm.sh w/ gcloud ssh/scpChris Evich2019-01-14
| | | | | | | | | | | | | | | Previously, using the ssh command directly required obtaining the external IP of the VM and was then subject to the local configuration. If the local configuration and/or ssh keys are incorrect, these commands would fail, preventing automatic setup of the VM. Fix this by using the gcloud ssh and scp wrappers. Unfortunately rsync couldn't be made to work in this situation, so use a tarball to transfer the local repository to the VM. Lastly, execute `setup_environment.sh` script, then drop the caller into a bash shell sitting in the remote `$GOSRC` directory. Signed-off-by: Chris Evich <cevich@redhat.com>
* Add script to create CI VMs for debuggingChris Evich2018-12-14
Frequently debugging of CI-related problems requires going hands-on within the environment. However, reproducing the environment by hand is very tedious and error prone. This script permits authorized users to produce VM's based on any available cache-image, and automatically remove them upon logout. Also: Bump up VM disk sizes to 200GB due to performance reasons Signed-off-by: Chris Evich <cevich@redhat.com>