diff --git a/.github/workflows/test-and-deploy.yml b/.github/workflows/test-and-deploy.yml index 014e7a8..90bd3f2 100644 --- a/.github/workflows/test-and-deploy.yml +++ b/.github/workflows/test-and-deploy.yml @@ -59,9 +59,9 @@ jobs: - name: Copy source files run: mkdir -p packager/debian/usr/bin; cp -r agent360 packager/debian/usr/bin/agent360 - name: Build debian package - run: dpkg-deb --build packager/debian agent360-${{ github.ref_name }}.deb + run: dpkg-deb --build packager/debian agent360-${{ GITHUB_SHA }}.deb - name: Install debian package - run: dpkg -i agent360-${{ github.ref_name }}.deb + run: dpkg -i agent360-${{ github.ref }}.deb - uses: actions/upload-artifact@v4 with: name: debian package diff --git a/packager/debian/DEBIAN/postinst b/packager/debian/DEBIAN/postinst index 172a13b..5a4aeed 100755 --- a/packager/debian/DEBIAN/postinst +++ b/packager/debian/DEBIAN/postinst @@ -1,23 +1,5 @@ #!/bin/sh -e -. /usr/share/debconf/confmodule - -TOKEN=/etc/agent360-token.ini - -db_get agent360/user -[ -n "$RET" ] && USERID="$RET" - - -if [ -n "$USERID" ]; then - agent360 hello $USERID /etc/agent360-token.ini -else - echo 'Generic "hello" is not implemented' -fi - -if which pycompile >/dev/null 2>&1; then - pycompile -p agent360 -fi - if [ "$(grep -c '^agent360:' /etc/passwd)" = "0" ]; then echo "Creating user and group agent360" addgroup --quiet --system agent360 && adduser --quiet --system --disabled-password --no-create-home --gecos "agent360 daemon" --group agent360