Created
January 31, 2017 17:55
-
-
Save gilhooleyd/03f47798eb63ef36d7f80575484fd117 to your computer and use it in GitHub Desktop.
Vagrant File for SWTPM Fedora 23
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure(2) do |config| | |
# disable automatic configuration updates from the original Vagrantbox | |
config.vm.box_check_update = false | |
# Every Vagrant development environment requires a box. You can search for | |
# boxes at https://atlas.hashicorp.com/search. | |
config.vm.box = "fedora/23-cloud-base" | |
config.ssh.forward_x11 = true | |
# Create a forwarded port mapping which allows access to a specific port | |
# within the machine from a port on the host machine. In the example below, | |
# accessing "localhost:8080" will access port 80 on the guest machine. | |
config.vm.network "forwarded_port", guest: 4000, host: 4001 | |
# Provider-specific configuration so you can fine-tune various | |
# backing providers for Vagrant. These expose provider-specific options. | |
# Example for VirtualBox: | |
# | |
# config.vm.provider "virtualbox" do |vb| | |
# # Display the VirtualBox GUI when booting the machine | |
# vb.gui = true | |
# | |
# # Customize the amount of memory on the VM: | |
# vb.memory = "1024" | |
# end | |
# Enable provisioning with a shell script | |
config.vm.provision "shell", inline: <<-SHELL | |
sudo yum -y install git | |
sudo yum -y install automake autoconf bash coreutils expect libtool sed libtpms libtpms-devel fuse fuse-devel glib2 glib2-devel gmp gmp-devel nss-devel net-tools selinux-policy-devel gnutls gnutls-devel libtasn1 libtasn1-tools libtasn1-devel rpm-build | |
sudo yum -y install openssl-devel tpm-tools kernel-modules-extra socat | |
sudo useradd tss | |
git clone https://github.com/stefanberger/libtpms | |
cd libtpms | |
./bootstrap.sh | |
./configure --prefix=/usr --with-openssl | |
make | |
sudo make install | |
cd ../ | |
git clone https://github.com/stefanberger/swtpm | |
cd swtpm | |
./bootstrap.sh | |
./configure --prefix=/usr --with-openssl | |
make | |
make check -j8 | |
sudo make install | |
SHELL | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment