Github Actions
This commit is contained in:
parent
219364af97
commit
7b3565a067
|
@ -0,0 +1,38 @@
|
||||||
|
---
|
||||||
|
|
||||||
|
name: LXC Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
packer:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
name: packer
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
# validate templates
|
||||||
|
- name: Validate Container
|
||||||
|
run: packer validate piston.pkr.hcl
|
||||||
|
working-directory: container
|
||||||
|
|
||||||
|
# build container
|
||||||
|
- name: Build Artifact
|
||||||
|
run: packer build -var 'make_threads=32' piston.pkr.hcl
|
||||||
|
working-directory: container
|
||||||
|
|
||||||
|
- name: Rename config
|
||||||
|
run: mv lxc-config config
|
||||||
|
working-directory: container
|
||||||
|
|
||||||
|
# Upload container
|
||||||
|
- uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: lxc-container
|
||||||
|
path: |
|
||||||
|
container/output-piston-bionic/config
|
||||||
|
container/output-piston-bionic/rootfs.tar.gz
|
18
readme.md
18
readme.md
|
@ -141,15 +141,23 @@ cd piston/lxc
|
||||||
|
|
||||||
#### Installation (simple)
|
#### Installation (simple)
|
||||||
|
|
||||||
- `cd container && ./install.sh`
|
- `mkdir -p /var/lib/lxc/piston`
|
||||||
|
- `cd /var/lib/lxc/piston`
|
||||||
|
- `wget [latest container url] -o container.zip`
|
||||||
|
- `unzip container.zip`
|
||||||
|
- `tar xzf rootfs.tar.gz`
|
||||||
|
- `rm rootfs.tar.gz container.zip`
|
||||||
|
- Good to go!
|
||||||
|
|
||||||
|
|
||||||
|
#### Installation (advanced)
|
||||||
|
|
||||||
|
- `cd ../container && ./install.sh`
|
||||||
- Wait, it may take up to an hour.
|
- Wait, it may take up to an hour.
|
||||||
- `cd ../lxc && ./start && cd ..`
|
- `cd ../lxc && ./start && cd ..`
|
||||||
- Good to go!
|
- Good to go!
|
||||||
|
|
||||||
#### Installation (advanced)
|
Alternatively, see `var/install.txt` for how to build the container manually
|
||||||
|
|
||||||
- See `var/install.txt` for how to create a new LXC container and install all of the required
|
|
||||||
software.
|
|
||||||
|
|
||||||
#### CLI Usage
|
#### CLI Usage
|
||||||
- `cli/execute [language] [file path] [args]`
|
- `cli/execute [language] [file path] [args]`
|
||||||
|
|
Loading…
Reference in New Issue