Created
          May 9, 2022 16:52 
        
      - 
      
- 
        Save carlwgeorge/c85b8105cb57ea37db363ffc5ccd0c2c to your computer and use it in GitHub Desktop. 
    buildah script to create pandoc cli container
  
        
  
    
      This file contains hidden or 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
    
  
  
    
  | #!/usr/bin/bash | |
| set -eu | |
| buildah unshare << EOF | |
| set -eu | |
| ctr=\$(buildah from scratch) | |
| mnt=\$(buildah mount \$ctr) | |
| dnf \ | |
| --releasever 35 \ | |
| --disablerepo '*' \ | |
| --enablerepo fedora,updates \ | |
| --installroot \$mnt \ | |
| --setopt 'tsflags=nodocs' \ | |
| --setopt 'install_weak_deps=false' \ | |
| --assumeyes \ | |
| install coreutils-single glibc-minimal-langpack pandoc | |
| dnf --installroot \$mnt clean all | |
| rm -rf \$mnt/var/cache/dnf | |
| buildah config --entrypoint '["/usr/bin/pandoc"]' \$ctr | |
| buildah unmount \$ctr | |
| buildah commit \$ctr localhost/pandoc | |
| buildah rm \$ctr | |
| EOF | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment