Skip to content

Commit db15e20

Browse files
committed
Initial commit
0 parents  commit db15e20

File tree

13 files changed

+1555
-0
lines changed

13 files changed

+1555
-0
lines changed

.devcontainer/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
FROM ghcr.io/catthehacker/ubuntu:custom-20.04-20240208
2+
RUN apt-get update && apt-get install -y zlib1g-dev libelf-dev

.devcontainer/devcontainer.json

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
2+
// README at: https://github.com/devcontainers/templates/tree/main/src/rust
3+
{
4+
"name": "Rust",
5+
"build": {
6+
// Path is relative to the devcontainer.json file.
7+
"dockerfile": "Dockerfile"
8+
}
9+
10+
// Use 'mounts' to make the cargo cache persistent in a Docker Volume.
11+
// "mounts": [
12+
// {
13+
// "source": "devcontainer-cargo-cache-${devcontainerId}",
14+
// "target": "/usr/local/cargo",
15+
// "type": "volume"
16+
// }
17+
// ]
18+
19+
// Features to add to the dev container. More info: https://containers.dev/features.
20+
// "features": {},
21+
22+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
23+
// "forwardPorts": [],
24+
25+
// Use 'postCreateCommand' to run commands after the container is created.
26+
// "postCreateCommand": "rustc --version",
27+
28+
// Configure tool-specific properties.
29+
// "customizations": {},
30+
31+
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
32+
// "remoteUser": "root"
33+
}

.github/dependabot.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "devcontainers"
4+
directory: "/"
5+
schedule:
6+
interval: weekly
7+
- package-ecosystem: "cargo"
8+
directory: "/"
9+
schedule:
10+
interval: "weekly"
11+
ignore:
12+
# These are peer deps of Cargo and should not be automatically bumped
13+
- dependency-name: "semver"
14+
- dependency-name: "crates-io"
15+
rebase-strategy: "disabled"

.github/workflows/rust.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Rust
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
tags:
7+
- 'v*' # Trigger the workflow on push to tags like v1.0, v20.15.10
8+
pull_request:
9+
branches: [ "main" ]
10+
11+
env:
12+
CARGO_TERM_COLOR: always
13+
14+
jobs:
15+
build_and_test:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/[email protected]
19+
- name: Install dependencies
20+
run: |
21+
sudo apt-get update
22+
sudo apt-get install -y zlib1g-dev libelf-dev
23+
- name: Test
24+
run: cargo test --verbose
25+
- name: Build
26+
run: cargo build --release --verbose
27+
- name: Upload binary
28+
uses: actions/[email protected]
29+
with:
30+
name: bpftop
31+
path: target/release/bpftop

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
build/
2+
target/
3+
root/

0 commit comments

Comments
 (0)