latest commit with image publish
This commit is contained in:
parent
1e6391db2f
commit
a8b284d9b6
47
.gitea/workflows/docker-publish.yml
Normal file
47
.gitea/workflows/docker-publish.yml
Normal file
@ -0,0 +1,47 @@
|
||||
name: Build and Publish Docker Image
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
tags: ['*'] # triggers on any tag push
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-and-push:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to Docker Registry
|
||||
run: echo "${{ secrets.PASSWORD }}" | docker login ${{ secrets.REGISTRY }} -u "${{ secrets.USERNAME }}" --password-stdin
|
||||
|
||||
- name: Build and Push Docker Images
|
||||
run: |
|
||||
IMAGE_NAME="ktvmanager-backend"
|
||||
REGISTRY="${{ secrets.REGISTRY }}"
|
||||
USERNAME="${{ secrets.USERNAME }}"
|
||||
IMAGE_LATEST="$REGISTRY/$USERNAME/$IMAGE_NAME:latest"
|
||||
|
||||
# Always build and tag as latest
|
||||
echo "🔧 Building $IMAGE_LATEST"
|
||||
docker build -t $IMAGE_LATEST .dockerfile
|
||||
|
||||
echo "📤 Pushing $IMAGE_LATEST"
|
||||
docker push $IMAGE_LATEST
|
||||
|
||||
# If this is a tag push, tag the image accordingly
|
||||
if [[ "${GITHUB_REF}" == refs/tags/* ]]; then
|
||||
GIT_TAG="${GITHUB_REF#refs/tags/}"
|
||||
IMAGE_TAGGED="$REGISTRY/$USERNAME/$IMAGE_NAME:$GIT_TAG"
|
||||
|
||||
echo "🏷️ Also tagging as $IMAGE_TAGGED"
|
||||
docker tag $IMAGE_LATEST $IMAGE_TAGGED
|
||||
|
||||
echo "📤 Pushing $IMAGE_TAGGED"
|
||||
docker push $IMAGE_TAGGED
|
||||
fi
|
16
dockerfile
Executable file
16
dockerfile
Executable file
@ -0,0 +1,16 @@
|
||||
FROM node:20-alpine
|
||||
|
||||
LABEL version="1.0"
|
||||
LABEL description="DNS BACKEND"
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY ["package.json", "package-lock.json", "./"]
|
||||
RUN npm ci --force
|
||||
|
||||
COPY . .
|
||||
|
||||
EXPOSE 3001
|
||||
|
||||
CMD ["node", "bin/www"]
|
||||
|
37
lib/newAPKUrlGrab.js
Executable file
37
lib/newAPKUrlGrab.js
Executable file
@ -0,0 +1,37 @@
|
||||
const axios = require('axios')
|
||||
const tor_axios = require('tor-axios');
|
||||
const tor = tor_axios.torSetup({
|
||||
ip: process.env.TORSSRV,
|
||||
port: 9050,
|
||||
controlPort: 9051,
|
||||
controlPassword: process.env.TORSPWD,
|
||||
})
|
||||
|
||||
axios.defaults.timeout = 3000;
|
||||
tor.defaults.timeout = 3000
|
||||
|
||||
const inst = axios.create({
|
||||
httpAgent: tor.httpAgent(),
|
||||
httpsagent: tor.httpsAgent(),
|
||||
});
|
||||
|
||||
let axiosOptions = {
|
||||
headers: {
|
||||
'User-Agent': 'IPTV Smarters Pro'
|
||||
}
|
||||
}
|
||||
|
||||
async function newapkurlgrab() {
|
||||
// data = "http://hello.exodus-2.xyz:8080/player_api.php?username=&password=https://1visions.co.uk:443/player_api.php?username=&password=http://dontsharefucker.party:80/player_api.php?username=&password=https://thepanel.pro:8443/player_api.php?username=&password=http://maximumorg.xyz:80/player_api.php?username=&password=http://sulu.xyz:2086/player_api.php?username=&password=http://xtv.ooo:8080/player_api.php?username=&password=http://line.rs4ott.com/player_api.php?username=&password=http://line.ottcdn.net:80/player_api.php?username=&password=http://b1g.ooo:80/player_api.php?username=&password=https://chips-and-rise.fun:443/player_api.php?username=&password=http://net.azers.online:2082/player_api.php?username=&password="
|
||||
let ip = await inst.get('http://api.ipify.org')
|
||||
console.log(ip.data);
|
||||
let query = await inst.get('https://razzlertv.xyz/customers/scotslad/onepanel/proxy/player_api.php?username=&password= ')
|
||||
// console.log(query.data);
|
||||
let a = query.data.split('/player_api.php?username=&password=')
|
||||
console.log(a)
|
||||
return a
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
newapkurlgrab
|
||||
}
|
54
lib/rrapkpull.js
Executable file
54
lib/rrapkpull.js
Executable file
@ -0,0 +1,54 @@
|
||||
const axios = require('axios');
|
||||
const qs = require('qs');
|
||||
const tor_axios = require('tor-axios');
|
||||
const tor = tor_axios.torSetup({
|
||||
ip: process.env.TORSSRV,
|
||||
port: 9050,
|
||||
controlPort: 9051,
|
||||
controlPassword: process.env.TORSPWD,
|
||||
});
|
||||
|
||||
axios.defaults.timeout = 3000;
|
||||
tor.defaults.timeout = 3000;
|
||||
|
||||
const inst = axios.create({
|
||||
httpAgent: tor.httpAgent(),
|
||||
httpsagent: tor.httpsAgent(),
|
||||
});
|
||||
|
||||
async function geturlfromRR() {
|
||||
const data = qs.stringify({
|
||||
'm': 'gu',
|
||||
'k': 'Ka11484fbeedb2561981887ea65a38ac4',
|
||||
'sc': '4de2d76e955780af333cd97551ed16c6',
|
||||
'u': 'no_user',
|
||||
'pw': 'no_password',
|
||||
'r': '2096169',
|
||||
'av': '3.1.5',
|
||||
'dt': 'unknown'
|
||||
});
|
||||
|
||||
const config = {
|
||||
method: 'post',
|
||||
maxBodyLength: Infinity,
|
||||
url: 'https://apkukrebrands-smarters.xyz/vpn/roadrunnertv/api/?action=315',
|
||||
headers: {
|
||||
'user-agent': 'IPTV Smarters Pro',
|
||||
'content-type': 'application/x-www-form-urlencoded'
|
||||
},
|
||||
data: data
|
||||
};
|
||||
|
||||
try {
|
||||
const response = await inst.request(config);
|
||||
const url_list = response.data.multi.split(',');
|
||||
return url_list;
|
||||
} catch (error) {
|
||||
console.error('Error fetching URLs from geturlfromRR:', error);
|
||||
return []; // Return an empty array on error
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
geturlfromRR
|
||||
};
|
Loading…
x
Reference in New Issue
Block a user