Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
unlearn
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tuhe
unlearn
Commits
eca8f818
Commit
eca8f818
authored
2 years ago
by
tuhe
Browse files
Options
Downloads
Patches
Plain Diff
CICD
parent
98e24259
No related branches found
No related tags found
No related merge requests found
Pipeline
#8693
failed
2 years ago
Stage: deploy
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.gitlab-ci.yml
+23
-4
23 additions, 4 deletions
.gitlab-ci.yml
src/unlearn/tokenpage.py
+6
-7
6 additions, 7 deletions
src/unlearn/tokenpage.py
with
29 additions
and
11 deletions
.gitlab-ci.yml
+
23
−
4
View file @
eca8f818
image
:
ubuntu:latest
image
:
python:3.7
#
#.install_firefox_geckodriver: &install_firefox_geckodriver
before_script
:
-
apt-get update -y
-
TZ=America/Sao_Paulo
# Numeric inputs: 2 - 134.
-
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
-
echo $TZ > /etc/timezone
# Add the needed libraries.
-
apt update && apt -y upgrade
# - apt-get update -y
-
apt install -y python3-pip python3.10 python-is-python3
-
apt install -y xvfb libssl-dev openssl wget firefox
-
apt -y install curl wget
-
apt install -y xvfb libssl-dev openssl
# wget firefox
-
openssl req -new -x509 -keyout server.pem -out server.pem -days 365 -nodes -batch
# - sudo -H pip3 install bpython selenium
-
apt-get install gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils --assume-yes
-
wget -nv -O ~/FirefoxSetup.tar.bz2 "https://download.mozilla.org/?product=firefox-latest&os=linux64"
-
tar xjf ~/FirefoxSetup.tar.bz2 -C /opt/
-
ln -s /opt/firefox/firefox /usr/lib/firefox
-
export PATH=$PATH:/opt/firefox/
-
wget -nv -O ~/geckodriver.tar.gz "https://github.com/mozilla/geckodriver/releases/download/v0.28.0/geckodriver-v0.28.0-linux64.tar.gz"
-
tar -zxvf ~/geckodriver.tar.gz -C /opt/
-
export PATH=$PATH:/opt/
# - sudo -H pip3 install bpython selenium
# - apt-get update # && apt-get upgrade --assume-yes
# - apt-get install gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils --assume-yes
...
...
This diff is collapsed.
Click to expand it.
src/unlearn/tokenpage.py
+
6
−
7
View file @
eca8f818
...
...
@@ -5,13 +5,12 @@ if __name__ == "__main__":
with
open
(
os
.
path
.
dirname
(
__file__
)
+
"
/password.txt
"
,
'
r
'
)
as
f
:
password
=
f
.
read
()
print
(
"
The learn password is
"
,
password
)
from
splinter
import
Browser
print
(
"
Making browser
"
)
browser
=
Browser
(
'
firefox
'
)
print
(
"
Done
"
)
browser
.
visit
(
'
http://google.com
'
)
print
(
browser
.
html
)
# from splinter import Browser
# print("Making browser")
# browser = Browser('firefox')
# print("Done")
# browser.visit('http://google.com')
# print(browser.html)
if
not
os
.
path
.
isdir
(
pages
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment