mirror of
				https://github.com/nitnelave/lldap.git
				synced 2023-04-12 14:25:13 +00:00 
			
		
		
		
	some cleanup
This commit is contained in:
		
							parent
							
								
									050b6dea6d
								
							
						
					
					
						commit
						e76ade4f4a
					
				
							
								
								
									
										37
									
								
								.github/workflows/docker-build-static.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										37
									
								
								.github/workflows/docker-build-static.yml
									
									
									
									
										vendored
									
									
								
							@ -48,10 +48,13 @@ env:
 | 
				
			|||||||
# 1-bullseye, 1.61-bullseye, 1.61.0-bullseye, bullseye, 1, 1.61, 1.61.0, latest
 | 
					# 1-bullseye, 1.61-bullseye, 1.61.0-bullseye, bullseye, 1, 1.61, 1.61.0, latest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# cache
 | 
					# cache
 | 
				
			||||||
## .sccache
 | 
					 | 
				
			||||||
## cargo
 | 
					## cargo
 | 
				
			||||||
## target
 | 
					## target
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Github actions currently timeout when downloading musl-gcc
 | 
				
			||||||
 | 
					## Using lldap dev image based on rust:1.62-slim-bullseye and musl-gcc bundled
 | 
				
			||||||
 | 
					### Job aarch64 and amd64 build
 | 
				
			||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  build-ui:
 | 
					  build-ui:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
@ -60,7 +63,6 @@ jobs:
 | 
				
			|||||||
      env:
 | 
					      env:
 | 
				
			||||||
        CARGO_TERM_COLOR: always
 | 
					        CARGO_TERM_COLOR: always
 | 
				
			||||||
        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
					        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
				
			||||||
        #CARGO_HOME: ${GITHUB_WORKSPACE}/.cargo
 | 
					 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - name: install runtime
 | 
					      - name: install runtime
 | 
				
			||||||
        run: apt update && apt install -y gcc-x86-64-linux-gnu g++-x86-64-linux-gnu libc6-dev ca-certificates
 | 
					        run: apt update && apt install -y gcc-x86-64-linux-gnu g++-x86-64-linux-gnu libc6-dev ca-certificates
 | 
				
			||||||
@ -150,9 +152,9 @@ jobs:
 | 
				
			|||||||
  build-aarch64:
 | 
					  build-aarch64:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    container:
 | 
					    container:
 | 
				
			||||||
      image: rust:1.62
 | 
					      #image: rust:1.62
 | 
				
			||||||
 | 
					      image: martadinata666/debian:rust-dev
 | 
				
			||||||
      env:
 | 
					      env:
 | 
				
			||||||
        CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: aarch64-linux-gnu-gcc
 | 
					 | 
				
			||||||
        CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER: aarch64-linux-musl-gcc
 | 
					        CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER: aarch64-linux-musl-gcc
 | 
				
			||||||
        CARGO_TERM_COLOR: always
 | 
					        CARGO_TERM_COLOR: always
 | 
				
			||||||
        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
					        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
				
			||||||
@ -176,13 +178,11 @@ jobs:
 | 
				
			|||||||
          key: lldap-bin-aarch64-${{ hashFiles('**/Cargo.lock') }}
 | 
					          key: lldap-bin-aarch64-${{ hashFiles('**/Cargo.lock') }}
 | 
				
			||||||
          restore-keys: |
 | 
					          restore-keys: |
 | 
				
			||||||
           lldap-bin-aarch64-
 | 
					           lldap-bin-aarch64-
 | 
				
			||||||
      - name: fetch musl-gcc
 | 
					#      - name: fetch musl-gcc
 | 
				
			||||||
        run: |
 | 
					#        run: |
 | 
				
			||||||
             wget -c https://musl.cc/aarch64-linux-musl-cross.tgz 
 | 
					#             wget -c https://musl.cc/aarch64-linux-musl-cross.tgz 
 | 
				
			||||||
             tar zxf ./x86_64-linux-musl-cross.tgz -C /opt
 | 
					#             tar zxf ./x86_64-linux-musl-cross.tgz -C /opt
 | 
				
			||||||
             echo "/opt/aarch64-linux-musl-cross:/opt/aarch64-linux-musl-cross/bin" >> $GITHUB_PATH 
 | 
					#             echo "/opt/aarch64-linux-musl-cross:/opt/aarch64-linux-musl-cross/bin" >> $GITHUB_PATH 
 | 
				
			||||||
#      - name: build
 | 
					 | 
				
			||||||
#        run: ./build-arm64.sh
 | 
					 | 
				
			||||||
      - name: add musl aarch64 target
 | 
					      - name: add musl aarch64 target
 | 
				
			||||||
        run: rustup target add aarch64-unknown-linux-musl
 | 
					        run: rustup target add aarch64-unknown-linux-musl
 | 
				
			||||||
      - name: build lldap aarch4
 | 
					      - name: build lldap aarch4
 | 
				
			||||||
@ -203,7 +203,8 @@ jobs:
 | 
				
			|||||||
  build-amd64:
 | 
					  build-amd64:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    container:
 | 
					    container:
 | 
				
			||||||
      image: rust:1.62
 | 
					#      image: rust:1.62
 | 
				
			||||||
 | 
					      image: martadinata666/debian:rust-dev
 | 
				
			||||||
      env:
 | 
					      env:
 | 
				
			||||||
        CARGO_TERM_COLOR: always
 | 
					        CARGO_TERM_COLOR: always
 | 
				
			||||||
        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
					        RUSTFLAGS: -Ctarget-feature=+crt-static
 | 
				
			||||||
@ -225,13 +226,11 @@ jobs:
 | 
				
			|||||||
            lldap-bin-amd64-
 | 
					            lldap-bin-amd64-
 | 
				
			||||||
      - name: install musl
 | 
					      - name: install musl
 | 
				
			||||||
        run: apt update && apt install -y musl-tools tar wget
 | 
					        run: apt update && apt install -y musl-tools tar wget
 | 
				
			||||||
      - name: fetch musl-gcc
 | 
					#      - name: fetch musl-gcc
 | 
				
			||||||
        run: |
 | 
					#        run: |
 | 
				
			||||||
             wget -c https://musl.cc/x86_64-linux-musl-cross.tgz 
 | 
					#             wget -c https://musl.cc/x86_64-linux-musl-cross.tgz 
 | 
				
			||||||
             tar zxf ./x86_64-linux-musl-cross.tgz -C /opt
 | 
					#             tar zxf ./x86_64-linux-musl-cross.tgz -C /opt
 | 
				
			||||||
             echo "/opt/x86_64-linux-musl-cross:/opt/x86_64-linux-musl-cross/bin" >> $GITHUB_PATH
 | 
					#             echo "/opt/x86_64-linux-musl-cross:/opt/x86_64-linux-musl-cross/bin" >> $GITHUB_PATH
 | 
				
			||||||
#      - name: fetch musl gcc and build
 | 
					 | 
				
			||||||
#        run: ./build-amd64.sh
 | 
					 | 
				
			||||||
      - name: add x86_64 target
 | 
					      - name: add x86_64 target
 | 
				
			||||||
        run: rustup target add x86_64-unknown-linux-musl
 | 
					        run: rustup target add x86_64-unknown-linux-musl
 | 
				
			||||||
      - name: build x86_64 lldap
 | 
					      - name: build x86_64 lldap
 | 
				
			||||||
 | 
				
			|||||||
@ -1,10 +0,0 @@
 | 
				
			|||||||
#!/bin/bash
 | 
					 | 
				
			||||||
wget -c https://musl.cc/x86_64-linux-musl-cross.tgz
 | 
					 | 
				
			||||||
tar zxf ./x86_64-linux-musl-cross.tgz -C /opt
 | 
					 | 
				
			||||||
rm ./x86_64-linux-musl-cross.tgz
 | 
					 | 
				
			||||||
export RUST_BACKTRACE=1
 | 
					 | 
				
			||||||
export CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_LINKER=x86_64-linux-musl-gcc
 | 
					 | 
				
			||||||
export RUSTFLAGS="-Ctarget-feature=+crt-static"
 | 
					 | 
				
			||||||
export PATH="/opt/x86_64-linux-musl-cross/:/opt/x86_64-linux-musl-cross/bin/:$PATH"
 | 
					 | 
				
			||||||
rustup target add x86_64-unknown-linux-musl
 | 
					 | 
				
			||||||
cargo build --target=x86_64-unknown-linux-musl --release -p lldap -p migration-tool
 | 
					 | 
				
			||||||
@ -1,11 +0,0 @@
 | 
				
			|||||||
#!/bin/bash
 | 
					 | 
				
			||||||
wget -c https://musl.cc/aarch64-linux-musl-cross.tgz
 | 
					 | 
				
			||||||
tar zxf ./aarch64-linux-musl-cross.tgz -C /opt
 | 
					 | 
				
			||||||
rm ./aarch64-linux-musl-cross.tgz
 | 
					 | 
				
			||||||
export RUST_BACKTRACE=1
 | 
					 | 
				
			||||||
export CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc
 | 
					 | 
				
			||||||
export CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER=aarch64-linux-musl-gcc
 | 
					 | 
				
			||||||
export RUSTFLAGS="-Ctarget-feature=+crt-static"
 | 
					 | 
				
			||||||
export PATH="/opt/aarch64-linux-musl-cross/:/opt/aarch64-linux-musl-cross/bin/:$PATH"
 | 
					 | 
				
			||||||
rustup target add aarch64-unknown-linux-musl
 | 
					 | 
				
			||||||
cargo build --target=aarch64-unknown-linux-musl --release -p lldap -p migration-tool
 | 
					 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user