Skip to content

Commit

Permalink
cleanups, test in mission-portal please
Browse files Browse the repository at this point in the history
  • Loading branch information
craigcomstock committed Jul 19, 2023
1 parent 7be74b3 commit dc98296
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 21 deletions.
2 changes: 1 addition & 1 deletion ci/Dockerfile-cfengine-build-package
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FROM ubuntu:20.04
RUN apt-get update -y && apt-get install -y systemd wget sudo
ADD "${NTECH_ROOT}/buildscripts/ci/setup.sh" /
RUN /setup.sh
RUN /bin/bash -c '/setup.sh 2>&1 > setup.log'
CMD [ "/lib/systemd/systemd" ]
2 changes: 1 addition & 1 deletion ci/clean.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ name=cfengine-build-package
# TODO: a softer clean might get into the container and run ./buildscripts/build-scripts/clean-buildmachine
docker stop $name
docker rm $name
#docker rmi $name
docker rmi $name
2 changes: 1 addition & 1 deletion ci/docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ mkdir -p "${NTECH_ROOT}/cache"
docker cp "${NTECH_ROOT}/cache/." $name:/root/.cache

# in order for build-scripts/autogen to generate a revision file:
for i in core buildscripts buildscripts/deps-packaging enterprise nova
for i in core buildscripts buildscripts/deps-packaging enterprise nova masterfiles
do
docker exec -i $name bash -c "git config --global --add safe.directory /data/$i"
done
Expand Down
19 changes: 4 additions & 15 deletions ci/setup-projects.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
#!/usr/bin/env bash

echo "where and what version of node/npm do we have?"
echo "=== tool versions (npm, node, composer) ==="
which npm
npm --version
which node
node --version
which composer
composer --version

set -ex
(
Expand All @@ -16,8 +18,6 @@ fi
)

# install composer and friends
sudo apt-get -qq -y install curl php7.4-cli php7.4-curl php7.4-zip php7.4-mbstring php7.4-xml php7.4-gd composer

(
if test -f "mission-portal/composer.json"; then
cd mission-portal
Expand All @@ -43,25 +43,14 @@ fi

(
if test -f "mission-portal/ldap/composer.json"; then
sudo apt-get -qq -y install php7.4-ldap
cd mission-portal/ldap
# install PHP dependencies from composer
composer install
fi
)

# packages needed for autogen
sudo apt-get -qy install git autoconf automake m4 make bison flex \
binutils libtool gcc g++ libc-dev libpam0g-dev python2 python3 psmisc \
libtokyocabinet-dev libssl-dev libpcre3-dev default-jre-headless

# packages needed for autogen are installed in setup.sh
NO_CONFIGURE=1 PROJECT=nova ./buildscripts/build-scripts/autogen

# packages needed for building
sudo apt-get -qy install bison flex binutils build-essential fakeroot ntp \
dpkg-dev libpam0g-dev python2 python3 debhelper pkg-config psmisc nfs-common \
dpkg-dev debhelper g++ libncurses5 pkg-config build-essential libpam0g-dev fakeroot rsync gcc make sudo wget

# remove unwanted dependencies
sudo apt-get -qy purge libltdl-dev libltdl7 #libtool

17 changes: 14 additions & 3 deletions ci/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ sudo rm -f /bin/rpm
# Install dependencies
sudo apt-get update -y

# install apt-utils so that debconf can configure installed packages
sudo apt-get install apt-utils

# git is needed for build-scripts/autogen to determine revision for such things as deps-packaging
sudo apt-get install -qy git

Expand All @@ -21,14 +24,22 @@ wget https://bootstrap.pypa.io/pip/2.7/get-pip.py -O get-pip.py
sudo python2 get-pip.py
sudo pip install psycopg2-binary

# Remove libltdl
sudo apt-get -qy purge 'libltdl*'
# install composer and friends
sudo apt-get -qq -y install curl php7.4-cli php7.4-curl php7.4-zip php7.4-mbstring php7.4-xml php7.4-gd composer php7.4-ldap
# packages needed for autogen
sudo apt-get -qy install git autoconf automake m4 make bison flex \
binutils libtool gcc g++ libc-dev libpam0g-dev python2 python3 psmisc

# packages needed for buildscripts
sudo apt-get -qy install libncurses5 rsync
# packages needed for building
sudo apt-get -qy install bison flex binutils build-essential fakeroot ntp \
dpkg-dev libpam0g-dev python2 python3 debhelper pkg-config psmisc nfs-common

# remove unwanted packages
sudo apt-get -qq purge apache* "postgresql*" redis*

# packages needed for installing Mission portal dependencies

# remove any nodejs or node- packages currently in place
sudo apt-get remove -y 'nodejs*' 'node-*'
# replace with exact version we want
Expand Down

0 comments on commit dc98296

Please sign in to comment.