Skip to content

Commit

Permalink
Install python to /usr/local
Browse files Browse the repository at this point in the history
  • Loading branch information
dwoz committed Nov 13, 2024
1 parent 9a49344 commit b3b7470
Show file tree
Hide file tree
Showing 14 changed files with 22 additions and 82 deletions.
8 changes: 6 additions & 2 deletions custom/testing/amazonlinux-2023.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,21 @@ SHELL ["/bin/bash", "-c"]

RUN <<EOF
set -e

if [ $(uname -m) = "x86_64" ]; then
export ARCH=x86_64
else
export ARCH=arm64
fi

yum update -y
yum install -y epel-release
yum install -y curl wget tar xz patchelf
yum install -y wget tar xz patchelf util-linux openssl openssl-pkcs11

wget https://packages.broadcom.com/artifactory/saltproject-generic/onedir/3007.1/salt-3007.1-onedir-linux-$ARCH.tar.xz
tar xf salt-3007.1-onedir-linux-$ARCH.tar.xz

./salt/salt-call --local --pillar-root=/golden-pillar-tree --file-root=/golden-state-tree state.apply provision

rm -rf salt
rm -rf salt-3007.1-onedir-linux-$ARCH.tar.xz
rm -rf golden-pillar-tree
Expand Down
35 changes: 0 additions & 35 deletions custom/testing/debian-13.Dockerfile

This file was deleted.

4 changes: 0 additions & 4 deletions custom/testing/golden-state-tree/os/amazon/init.sls
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
include:
- .config
- .pkgs

{%- if pillar.get('github_actions_runner', False) %}
- github-actions-runner
{%- endif %}
5 changes: 1 addition & 4 deletions custom/testing/golden-state-tree/os/amazon2023/init.sls
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
include:
- .config
- .pkgs

{%- if pillar.get('github_actions_runner', False) %}
- github-actions-runner
{%- endif %}
- python
4 changes: 2 additions & 2 deletions custom/testing/golden-state-tree/os/amazon2023/pkgs/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ include:
- pkgs.gpg
- pkgs.libcurl
- pkgs.libffi
- pkgs.libsodium-compile
{#- - pkgs.libsodium-compile #}
- pkgs.libxml
- pkgs.libxslt
- pkgs.make
Expand Down Expand Up @@ -37,5 +37,5 @@ include:

{#- OS Specific packages install #}
{%- if grains['osarch'] not in ('amd64', 'armhf', 'arm64') %}
- .docker
{#- - .docker #}
{%- endif %}
2 changes: 2 additions & 0 deletions custom/testing/golden-state-tree/os/debian/config/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ include:
- config.ulimits
- config.locale
- config.sssd
{#-
- config.timezone
- config.dhclient
- config.sshd_config
#}
5 changes: 1 addition & 4 deletions custom/testing/golden-state-tree/os/debian/init.sls
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
include:
- .config
- .pkgs

{%- if pillar.get('github_actions_runner', False) %}
- github-actions-runner
{%- endif %}
- python
4 changes: 0 additions & 4 deletions custom/testing/golden-state-tree/os/fedora/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,3 @@ include:
- .config
- .pkgs
- python

{%- if pillar.get('github_actions_runner', False) %}
- github-actions-runner
{%- endif %}
7 changes: 0 additions & 7 deletions custom/testing/golden-state-tree/os/photon/init.sls
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@



include:
- .config
- .pkgs
- python

{%- if pillar.get('github_actions_runner', False) %}
- github-actions-runner
{%- endif %}
2 changes: 2 additions & 0 deletions custom/testing/golden-state-tree/os/rocky/config/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ include:
- config.ulimits
- config.locale
- config.sssd
{#-
- config.timezone
- config.dhclient
- config.sshd_config
#}
2 changes: 1 addition & 1 deletion custom/testing/golden-state-tree/os/rocky/pkgs/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ include:
- pkgs.curl
- pkgs.dmidecode
- pkgs.dnsutils
- pkgs.docker
{#- - pkgs.docker #}
- pkgs.gcc
- pkgs.gpg
- pkgs.ipset
Expand Down
17 changes: 0 additions & 17 deletions custom/testing/golden-state-tree/python/amazon_dependencies.sls
Original file line number Diff line number Diff line change
@@ -1,17 +1,3 @@
# Install dnf config manager
install_config_command:
cmd.run:
- name: dnf install -y 'dnf-command(config-manager)'


# Use config manager to enable powertools repo. This is needed for libnsl2-devel
enable_powertools_repo:
cmd.run:
- name: dnf config-manager --set-enabled powertools
- require:
- install_config_command


python_dependencies:
pkg.latest:
- pkgs:
Expand All @@ -29,6 +15,3 @@ python_dependencies:
- gdbm-devel
- sqlite-devel
- xz-devel
- libnsl2-devel
- require:
- enable_powertools_repo
4 changes: 2 additions & 2 deletions custom/testing/golden-state-tree/python/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ include:
{%- elif grains['os'] == 'Fedora' %}
- .fedora_dependencies
{%- elif grains.get("oscodename") == 'Amazon Linux 2' %}
- .rocky_dependencies
- .amazon_dependencies
{%- elif grains.get("osfinger") == 'Amazon Linux-2023' %}
- .rocky_dependencies
- .amazon_dependencies
{%- elif grains['os'] == 'VMware Photon OS' %}
- .photon_dependencies
{%- elif grains['os'] == 'Debian' %}
Expand Down
5 changes: 5 additions & 0 deletions custom/testing/rockylinux-8.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,22 @@ SHELL ["/bin/bash", "-c"]

RUN <<EOF
set -e

if [ $(uname -m) = "x86_64" ]; then
export ARCH=x86_64
else
export ARCH=arm64
fi

yum update -y
yum install -y epel-release
yum install -y curl wget tar xz patchelf

wget https://packages.broadcom.com/artifactory/saltproject-generic/onedir/3007.1/salt-3007.1-onedir-linux-$ARCH.tar.xz
tar xf salt-3007.1-onedir-linux-$ARCH.tar.xz

./salt/salt-call --local --pillar-root=/golden-pillar-tree --file-root=/golden-state-tree state.apply provision

rm -rf salt
rm -rf salt-3007.1-onedir-linux-$ARCH.tar.xz
rm -rf golden-pillar-tree
Expand Down

0 comments on commit b3b7470

Please sign in to comment.