Coder Social home page Coder Social logo

wallneradam / docker-flatcar-toolbox-ubuntu Goto Github PK

View Code? Open in Web Editor NEW
9.0 2.0 4.0 22 KB

Ubuntu (server) Linux based toolbox for Flatcar Container Linux

License: GNU General Public License v3.0

Shell 11.41% Dockerfile 88.59%
docker coreos coreos-toolbox ubuntu systemd-nspawn tmux container toolbox flatc

docker-flatcar-toolbox-ubuntu's People

Contributors

wallneradam avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

docker-flatcar-toolbox-ubuntu's Issues

toolbox fails with "Failed to parse --bind(-ro)= argument : Invalid argument"

Master branch (the only branch at this date)

  1. Startup an AWS instance with: CoreOS-stable-1185.5.0 (ami-b5e5e3a2)
  2. Log into the core account
  3. Create/copy .tooboxrc with contents from this project
  4. Run toolbox

Once the container has downloaded (and in subsequent invocations) you will receive the error:

Failed to parse --bind(-ro)= argument : Invalid argument

Cannot reattach

Hey, cool script you got here. Found this repo after trying some things on my own; installed tmux inside a brand new ubuntu toolbox, detached, and was not able to get back in. machinectl list shows nothing as well. (I also tried apt install -y systemd dbus as per this issue).

I thought perhaps your use of toolbox tmux and toolbox tmux attach -t 0 might work (as oppsed to launched tmux from inside a toolbox shell as I was first doing), but I still cannot reattach:

Failed to allocate scope: Unit toolbox-ubuntu.scope already exists.

Also, I do not know how to use nsenter to "get back in" to the container. I am wondering if the machinectl issues are CoreOS specific.

Any ideas? Are you still using this without issue, on latest stable? (atm, 1745.7.0)

FWIW, I have found an alternate solution which is to use statically built binaries (or AppImage's), and the following container linux config works:

storage:
  files:
    - path: /opt/bin/neofetch
      filesystem: root
      mode: 0555
      contents:
        remote:
          url: https://github.com/dylanaraps/neofetch/releases/download/5.0.0/neofetch
          verification:
            hash:
              function: sha512
              sum: d17d1b541b5f55d6614e3cee07205a23059245343a1b8fdc76d4ecc9c6ba900445aa39d4a6be29f8771225b51e3c292c2d94cb03f17fa84278e4046fd8009ad8
    - path: /opt/installers/nvim.sh
      filesystem: root
      mode: 0544
      contents:
        inline: |
          #!/bin/bash

          cmd=$(command -v nvim)
          [ ! -z "$cmd" ] && echo "nvim already installed at $cmd" | systemd-cat && exit 0

          BASE_URL=https://github.com/neovim/neovim/releases/download
          VERSION=0.3.0

          wget --quiet $BASE_URL/v$VERSION/nvim.appimage
          chmod +x nvim.appimage
          # No FUSE, so need --appimage-extract
          ./nvim.appimage --appimage-extract > /dev/null 2>&1
          rm nvim.appimage
          mv squashfs-root /opt/nvim
          chmod 755 -R /opt/nvim
          ln -s /opt/nvim/usr/bin/nvim /opt/bin/nvim
      # TODO these minos installers can be generalized
    - path: /opt/installers/tmux.sh
      filesystem: root
      mode: 0544
      contents:
        inline: |
          #!/bin/bash

          cmd=$(command -v tmux)
          [ ! -z "$cmd" ] && echo "tmux already installed at $cmd" && exit 0

          PACKAGE=tmux-1.9a.tar.xz

          wget --quiet http://s.minos.io/archive/morpheus/x86_64/$PACKAGE
          tar -C /opt -xf $PACKAGE
          rm $PACKAGE
    - path: /opt/installers/htop.sh
      filesystem: root
      mode: 0544
      contents:
        inline: |
          #!/bin/bash

          cmd=$(command -v htop)
          [ ! -z "$cmd" ] && echo "htop already installed at $cmd" && exit 0

          PACKAGE=htop-1.0.3.tar.xz

          wget --quiet http://s.minos.io/archive/morpheus/x86_64/$PACKAGE
          tar -C /opt -xf $PACKAGE
          rm $PACKAGE

systemd:
  units:
    - name: install-scripts.service
      enabled: true
      contents: |
        [Unit]
        Description=idempotent scripts to install statically linked programs

        [Service]
        Type=oneshot
        ExecStart=/opt/installers/tmux.sh
        ExecStart=/opt/installers/nvim.sh
        ExecStart=/opt/installers/htop.sh

        [Install]
        WantedBy=multi-user.target

Which, just for fun :D, looks like:

screenshot from 2018-07-03 18-55-18

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.