From 14f2dde8a70660c5ed82827d904401d9efc7dd20 Mon Sep 17 00:00:00 2001 From: douglas-raillard-arm Date: Fri, 9 Apr 2021 15:35:15 +0100 Subject: [PATCH] WIP --- Vagrantfile | 10 ++++++---- tools/release.sh | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 4 deletions(-) create mode 100755 tools/release.sh diff --git a/Vagrantfile b/Vagrantfile index d9b22f9b4..b9b0d6bba 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -1,7 +1,6 @@ # -*- mode: ruby -*- # vi: set ft=ruby : - Vagrant.configure(2) do |config| config.vm.box = "ubuntu/focal64" @@ -14,7 +13,9 @@ Vagrant.configure(2) do |config| end # Forward ipython notebook's port to the host - config.vm.network "forwarded_port", guest: 8888, host: 8888 + if !ENV['VAGRANT_FORWARD_JUPYTER'] == '0' + config.vm.network "forwarded_port", guest: 8888, host: 8888 + end config.vm.provision "shell", inline: <<-SHELL set -e @@ -58,8 +59,9 @@ Vagrant.configure(2) do |config| do echo unset $LC >> /home/vagrant/.bashrc done - echo "export LISA_VENV_PATH=$LISA_VENV_PATH" >> /home/vagrant/.bashrc - echo 'source init_env' >> /home/vagrant/.bashrc + echo "export LISA_VENV_PATH=$LISA_VENV_PATH" >> /home/vagrant/activate-lisa + echo 'source init_env' >> /home/vagrant/activate-lisa + echo 'source /home/vagrant/activate-lisa' >> /home/vagrant/.bashrc # Trigger the creation of a venv and check that everything works well if ! su vagrant bash -c 'tools/tests.sh'; then diff --git a/tools/release.sh b/tools/release.sh new file mode 100755 index 000000000..44422e2ab --- /dev/null +++ b/tools/release.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# +# SPDX-License-Identifier: Apache-2.0 +# +# Copyright (C) 2021, ARM Limited and contributors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +TAG=master +LISA_HOME=./release + +export LISA_HOME=$(readlink -f "$LISA_HOME") + +git clone https://github.com/ARM-Software/lisa.git "$LISA_HOME" +git -C "$LISA_HOME" checkout "$TAG" + +vagrant box update +vagrant destroy -f + + +VAGRANT_FORWARD_JUPYTER=0 vagrant up && +vagrant ssh -c 'source start-lisa && pip freeze > release_requirements.txt && $LISA_HOME/tools/tests.sh' -- GitLab