Compare commits
2 Commits
9261ec341e
...
3f35c670ca
| Author | SHA1 | Date | |
|---|---|---|---|
| 3f35c670ca | |||
| a32bfd5108 |
@@ -0,0 +1,21 @@
|
|||||||
|
name: Build and Deploy
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: nix-ci
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Build docker
|
||||||
|
run: nix run nixpkgs#devenv shell build-docker
|
||||||
|
|
||||||
|
- name: Deploy docker
|
||||||
|
env:
|
||||||
|
REGISTRY_USERNAME: ${{ secrets.CONTAINER_REGISTRY_GITEA_USERNAME }}
|
||||||
|
REGISTRY_PASSWORD: ${{ secrets.CONTAINER_REGISTRY_GITEA_PASSWORD }}
|
||||||
|
run: nix run nixpkgs#devenv shell deploy-docker
|
||||||
+1
-61
@@ -16,62 +16,6 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-compat": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1767039857,
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"git-hooks": {
|
|
||||||
"inputs": {
|
|
||||||
"flake-compat": "flake-compat",
|
|
||||||
"gitignore": "gitignore",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1769939035,
|
|
||||||
"owner": "cachix",
|
|
||||||
"repo": "git-hooks.nix",
|
|
||||||
"rev": "a8ca480175326551d6c4121498316261cbb5b260",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "cachix",
|
|
||||||
"repo": "git-hooks.nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"gitignore": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"git-hooks",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1762808025,
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "gitignore.nix",
|
|
||||||
"rev": "cb5e3fdca1de58ccbc3ef53de65bd372b48f567c",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "gitignore.nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1770115704,
|
"lastModified": 1770115704,
|
||||||
@@ -90,11 +34,7 @@
|
|||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"devenv": "devenv",
|
"devenv": "devenv",
|
||||||
"git-hooks": "git-hooks",
|
"nixpkgs": "nixpkgs"
|
||||||
"nixpkgs": "nixpkgs",
|
|
||||||
"pre-commit-hooks": [
|
|
||||||
"git-hooks"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
+25
-5
@@ -1,5 +1,4 @@
|
|||||||
{ pkgs, ... }:
|
{pkgs, ...}: {
|
||||||
{
|
|
||||||
android = {
|
android = {
|
||||||
enable = true;
|
enable = true;
|
||||||
emulator.enable = false;
|
emulator.enable = false;
|
||||||
@@ -46,10 +45,31 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
scripts = {
|
scripts = {
|
||||||
deploy-docker.exec = ''
|
build-docker.exec = ''
|
||||||
|
dart run pdfrx:remove_wasm_modules --revert // Make sure WASM is put in output
|
||||||
|
|
||||||
flutter build web --release
|
flutter build web --release
|
||||||
docker build -t harbor.julian-mutter.de/sheetless/sheetless-frontend .
|
|
||||||
docker push harbor.julian-mutter.de/sheetless/sheetless-frontend
|
docker build -t gitlab.julian-mutter.de/julian/sheetless-frontend:latest .
|
||||||
|
'';
|
||||||
|
|
||||||
|
deploy-docker.exec = ''
|
||||||
|
if [ -n "''${REGISTRY_USERNAME:-}" ] && [ -n "''${REGISTRY_PASSWORD:-}" ]; then
|
||||||
|
docker login gitlab.julian-mutter.de --username "$REGISTRY_USERNAME" --password "$REGISTRY_PASSWORD"
|
||||||
|
fi
|
||||||
|
|
||||||
|
docker push gitlab.julian-mutter.de/julian/sheetless-frontend
|
||||||
|
'';
|
||||||
|
|
||||||
|
build-android.exec = ''
|
||||||
|
dart run pdfrx:remove_wasm_modules --revert // Make sure WASM is put in output
|
||||||
|
dart run pdfrx:remove_wasm_modules // NOT idempotent!
|
||||||
|
|
||||||
|
flutter build apk --release
|
||||||
|
'';
|
||||||
|
|
||||||
|
deploy-android.exec = ''
|
||||||
|
echo "TBD"
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user