xref: /aosp_15_r20/kernel/tests/net/test/rootfs/bullseye.sh (revision 2f2c4c7ab4226c71756b9c31670392fdd6887c4f)
1*2f2c4c7aSAndroid Build Coastguard Worker#!/bin/bash
2*2f2c4c7aSAndroid Build Coastguard Worker#
3*2f2c4c7aSAndroid Build Coastguard Worker# Copyright (C) 2018 The Android Open Source Project
4*2f2c4c7aSAndroid Build Coastguard Worker#
5*2f2c4c7aSAndroid Build Coastguard Worker# Licensed under the Apache License, Version 2.0 (the "License");
6*2f2c4c7aSAndroid Build Coastguard Worker# you may not use this file except in compliance with the License.
7*2f2c4c7aSAndroid Build Coastguard Worker# You may obtain a copy of the License at
8*2f2c4c7aSAndroid Build Coastguard Worker#
9*2f2c4c7aSAndroid Build Coastguard Worker#      http://www.apache.org/licenses/LICENSE-2.0
10*2f2c4c7aSAndroid Build Coastguard Worker#
11*2f2c4c7aSAndroid Build Coastguard Worker# Unless required by applicable law or agreed to in writing, software
12*2f2c4c7aSAndroid Build Coastguard Worker# distributed under the License is distributed on an "AS IS" BASIS,
13*2f2c4c7aSAndroid Build Coastguard Worker# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14*2f2c4c7aSAndroid Build Coastguard Worker# See the License for the specific language governing permissions and
15*2f2c4c7aSAndroid Build Coastguard Worker# limitations under the License.
16*2f2c4c7aSAndroid Build Coastguard Worker#
17*2f2c4c7aSAndroid Build Coastguard Worker
18*2f2c4c7aSAndroid Build Coastguard Workerset -e
19*2f2c4c7aSAndroid Build Coastguard Workerset -u
20*2f2c4c7aSAndroid Build Coastguard Worker
21*2f2c4c7aSAndroid Build Coastguard WorkerSCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)
22*2f2c4c7aSAndroid Build Coastguard Worker
23*2f2c4c7aSAndroid Build Coastguard Worker. $SCRIPT_DIR/bullseye-common.sh
24*2f2c4c7aSAndroid Build Coastguard Worker
25*2f2c4c7aSAndroid Build Coastguard Workersetup_static_networking
26*2f2c4c7aSAndroid Build Coastguard Worker
27*2f2c4c7aSAndroid Build Coastguard Workerupdate_apt_sources bullseye ""
28*2f2c4c7aSAndroid Build Coastguard Worker
29*2f2c4c7aSAndroid Build Coastguard Worker# Disable the root password
30*2f2c4c7aSAndroid Build Coastguard Workerpasswd -d root
31*2f2c4c7aSAndroid Build Coastguard Worker
32*2f2c4c7aSAndroid Build Coastguard Workerget_installed_packages >/root/originally-installed
33*2f2c4c7aSAndroid Build Coastguard Workersetup_and_build_iptables
34*2f2c4c7aSAndroid Build Coastguard Workerget_installed_packages >/root/installed
35*2f2c4c7aSAndroid Build Coastguard Workerremove_installed_packages /root/originally-installed /root/installed
36*2f2c4c7aSAndroid Build Coastguard Workerinstall_and_cleanup_iptables
37*2f2c4c7aSAndroid Build Coastguard Worker
38*2f2c4c7aSAndroid Build Coastguard Workercreate_systemd_getty_symlinks ttyS0
39*2f2c4c7aSAndroid Build Coastguard Worker
40*2f2c4c7aSAndroid Build Coastguard Workerbullseye_cleanup
41